Switch poe updates - #605
Conversation
|
Can you please squash and force-push your commit history? Having so many commits in the PR makes it hard to review (because the web-pages lists them all out). |
|
What's the proper way to avoid this and fix the history currently? Those are all coming from just branching and updating from upstream as per previous discussions of the git work flow. The history is less important in my opinion however than the file differences that can be reviewed, which is only 3 files and it's very minimal. |
|
The root problem is that "git merge" (or pull, which does a merge)
preserves a lot of history and context which over time causes cruft
buildup. So, you either need to periodically create a new branch from
master, rebase (alternate to merge), or reset. The easiest is reset -- I
just did it for one of my branches -- see below. None of these commands
change any files on disk (except maybe for the initial git merge from
master), they just play with the git history.
peringknife@peringknife-glaptop3:~/daq$ *git merge master*
Already up to date.
peringknife@peringknife-glaptop3:~/daq$ *git reset master*
Unstaged changes after reset:
M bin/setup_dev
...
M testing/test_aux.sh
peringknife@peringknife-glaptop3:~/daq$ *git add .*
peringknife@peringknife-glaptop3:~/daq$ *git commit -m "Provisioning
tweaks"*
[provisioner a05906f] Provisioning tweaks
14 files changed, 96 insertions(+), 15 deletions(-)
peringknife@peringknife-glaptop3:~/daq$ *git push*
To github.com:grafnu/daq.git
! [rejected] provisioner -> provisioner (non-fast-forward)
error: failed to push some refs to 'github.com:grafnu/daq.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
peringknife@peringknife-glaptop3:~/daq$ *git push --force*
Enumerating objects: 59, done.
Counting objects: 100% (59/59), done.
Delta compression using up to 8 threads
Compressing objects: 100% (29/29), done.
Writing objects: 100% (30/30), 3.93 KiB | 447.00 KiB/s, done.
Total 30 (delta 26), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (26/26), completed with 26 local objects.
To github.com:grafnu/daq.git
+ 1167935...a05906f provisioner -> provisioner (forced update)
…On Fri, Aug 28, 2020 at 7:59 AM jhughesbiot ***@***.***> wrote:
What's the proper way to avoid this and fix the history currently? Those
are all coming from just branching and updating from upstream as per
previous discussions of the git work flow.
The history is less important in my opinion however than the file
differences that can be reviewed, which is only 3 files and it's very
minimal.
—
You are receiving this because your review was requested.
Reply to this email directly, view it on GitHub
<#605 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIEPD3ZVWB6EMTUBJUFUADSC7A3ZANCNFSM4QGNURYQ>
.
|
|
Attempted with no effect to commit history. |
Codecov Report
@@ Coverage Diff @@
## master #605 +/- ##
==========================================
- Coverage 80.96% 80.37% -0.60%
==========================================
Files 22 22
Lines 3720 3720
==========================================
- Hits 3012 2990 -22
- Misses 708 730 +22
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
|
Please capture the exact sequence of commands and output that you're doing.
Also might throw in a "git log -n 1" occasionally to see what the HEAD is
at each point.
…On Fri, Aug 28, 2020 at 8:59 AM jhughesbiot ***@***.***> wrote:
Attempted with no effect to commit history.
—
You are receiving this because your review was requested.
Reply to this email directly, view it on GitHub
<#605 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIEPD7XJOYILC2XVOZ65LDSC7H7DANCNFSM4QGNURYQ>
.
|
|
|
Your origin/master and master are out of sync with upstream master. I'm not
sure what your origin is pointing at but that will cause confusion. I
generally keep my master branch completely in sync with upstream master, so
no local changes. Note your master commit is a "merge commit" and is the
same as your feature branch. The sequence to reset your master to follow
upstream faucet is something like:
peringknife@peringknife-glaptop3:~/daq$ *git remote -v | fgrep faucet*
faucet git@github.com:faucetsdn/daq.git (fetch)
faucet git@github.com:faucetsdn/daq.git (push)
peringknife@peringknife-glaptop3:~/daq$ *git checkout master*
Already on 'master'
Your branch is up to date with 'origin/master'.
peringknife@peringknife-glaptop3:~/daq$ *git fetch faucet*
peringknife@peringknife-glaptop3:~/daq$ *git reset --hard faucet/master *
HEAD is now at 55c879f Update dependency gradle to v6.6.1 (#617)
and then you should end up with something like:
~/daq$ *git log -n 1*
commit 55c879f (HEAD -> master,
origin/release_testing, origin/master, origin/HEAD, faucet/release_testing,
faucet/master, release_testing)
Author: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue Aug 25 16:24:44 2020 -0700
Update dependency gradle to v6.6.1 (#617)
…On Fri, Aug 28, 2020 at 9:37 AM jhughesbiot ***@***.***> wrote:
git merge master
Already up to date.
git log -n 1
commit 78512bd (HEAD -> switch-poe-updates, origin/switch-poe-updates)
Merge: ddb0ad4 b4ad528
Author: jhughesbiot ***@***.***>
Date: Fri Aug 28 08:57:30 2020 -0700
Merge branch 'switch-poe-updates' of https://github.com/jhughesbiot/daq into switch-poe-updates
git reset master
Unstaged changes after reset:
M docs/device_report.md
M subset/switches/src/main/java/switchtest/SwitchTest.java
M subset/switches/test_switch
git log -n 1
commit b196439 (HEAD -> switch-poe-updates, origin/master, origin/HEAD, master)
Merge: 53acd58 861eccd
Author: jhughesbiot ***@***.***>
Date: Fri Aug 28 08:54:01 2020 -0700
Merge branch 'master' of https://github.com/jhughesbiot/daq
git add .
git log -n 1
commit b196439 (HEAD -> switch-poe-updates, origin/master, origin/HEAD, master)
Merge: 53acd58 861eccd
Author: jhughesbiot ***@***.***>
Date: Fri Aug 28 08:54:01 2020 -0700
Merge branch 'master' of https://github.com/jhughesbiot/daq
git commit -m 'history cleanup attempt'
[switch-poe-updates 3b7f2d4] history cleanup attempt
3 files changed, 1 insertion(+), 50 deletions(-)
git log -n 1
commit 3b7f2d4 (HEAD -> switch-poe-updates)
Author: jhughesbiot ***@***.***>
Date: Fri Aug 28 09:30:39 2020 -0700
history cleanup attempt
git push
To https://github.com/jhughesbiot/daq
! [rejected] switch-poe-updates -> switch-poe-updates (non-fast-forward)
error: failed to push some refs to 'https://github.com/jhughesbiot/daq'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
git push --force
Username for 'https://github.com': jhughesbiot
Password for ***@***.***':
Enumerating objects: 23, done.
Counting objects: 100% (23/23), done.
Delta compression using up to 8 threads
Compressing objects: 100% (9/9), done.
Writing objects: 100% (12/12), 876 bytes | 125.00 KiB/s, done.
Total 12 (delta 7), reused 0 (delta 0)
remote: Resolving deltas: 100% (7/7), completed with 7 local objects.
To https://github.com/jhughesbiot/daq
+ 78512bd...3b7f2d4 switch-poe-updates -> switch-poe-updates (forced update)
—
You are receiving this because your review was requested.
Reply to this email directly, view it on GitHub
<#605 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIEPD6EXLT3Q2L4II5MYATSC7MNVANCNFSM4QGNURYQ>
.
|
|
It was already in sync but looks like resetting the master before merging was the key. Cleaned up now |
grafnu
left a comment
There was a problem hiding this comment.
Thanks for working through the git issue. It's one of those things that just slowly builds up over time so good to be able to clear out the slate from time to time!
| |skip|connection.port_speed|Other|Other|No local IP has been set, check system config| | ||
| |pass|manual.test.name|Security|Recommended|Manual test - for testing| | ||
| |skip|poe.negotiation|Other|Other|No local IP has been set, check system config| | ||
| |skip|poe.power|Other|Other|No local IP has been set, check system config| |
There was a problem hiding this comment.
The test name should be poe.switch.power
|
@jhughesbiot, I've reviewed and have the following comments:
|
|
@noursaidi |
|
@noursaidi @pisuke |
|
@jhughesbiot @spectre-storm @noursaidi @henry54809 @pbatta I've just checked the module with a range of configurations and devices and there are a few things to be fixed before the test code can be merged.
After fixing 1, 2 and 4 we can merge the PR. Point 3 should be addressed in a separate PR. |
|
@pisuke
|
|
Thanks @jhughesbiot, I'll get this merged then. |
No description provided.