git drover does not work and the error messages are not helpful |
|||
Issue descriptiongit drover does not work for me. It has never worked for me. I tried following the steps linked from http://sites/chrome-pmo/tasks/merging-a-change-to-a-branch [FYI: Some of the links do not work anymore after the migration to PolyGerrit.] Part 1: Using the verbose option, I tracked it down to this: $ cd /tmp/drover_2987_kCCtYD $ git rev-list --parents HEAD ... c9c1cfcd812112c7cfacbbbe2a2dacbd117b1f48 be264faf0286a508b23e181d3cb25723f2eff2bf be264faf0286a508b23e181d3cb25723f2eff2bf 7831a89af115138ba54b3e9b64f5aa040a566853 7831a89af115138ba54b3e9b64f5aa040a566853 5c829506cb3fa53276b6a720a438a28111987bab error: Could not read 58cb65370efa360e924ca222af05c3bef09e168c fatal: Failed to traverse parents of commit 5c829506cb3fa53276b6a720a438a28111987bab Interestingly, when I run the same command in my usual Chromium checkout, it runs successfully: $ cd <PATH TO CHROMIUM CHECKOUT> $ git rev-list --parents HEAD be264faf0286a508b23e181d3cb25723f2eff2bf 7831a89af115138ba54b3e9b64f5aa040a566853 7831a89af115138ba54b3e9b64f5aa040a566853 5c829506cb3fa53276b6a720a438a28111987bab 5c829506cb3fa53276b6a720a438a28111987bab I worked around this problem by commenting 2 lines in upload.py temporarily: $ git diff 1 diff --git a/third_party/upload.py b/third_party/upload.py 2 index 94935bf..b38ccde 100755 3 --- a/third_party/upload.py 4 +++ b/third_party/upload.py 5 @@ -883,8 +883,8 @@ def RunShellWithReturnCode(command, universal_newlines=True, env=os.environ): 6 def RunShell(command, silent_ok=False, universal_newlines=True, 7 env=os.environ): 8 data, retcode = RunShellWithReturnCode(command, universal_newlines, env) 9 - if retcode: 10 - ErrorExit("Got error status from %s:\n%s" % (command, data)) 11 + #if retcode: 12 + # ErrorExit("Got error status from %s:\n%s" % (command, data)) 13 if not silent_ok and not data: 14 ErrorExit("No output from %s" % command) Part 2: After commenting, I ran into another problem later: "git cl land --bypass-hooks" fails $ git cl land --bypass-hooks -v Using 50% similarity for rename/copy detection. Override with --similarity. Description: [M57] GetThreatSeverity should handle the case of CheckResourceUrl. Added the case statement and a unit test that forces a full hash match which causes this method to get executed. BUG= 689672 Review-Url: https://codereview.chromium.org/2680163002 Cr-Commit-Position: refs/heads/master@{#448885} (cherry picked from commit 4e2788493f4bef375b52e78e5a9ee38f2d92b191) Review-Url: https://codereview.chromium.org/2679173006 . components/safe_browsing_db/v4_local_database_manager.cc | 1 + components/safe_browsing_db/v4_local_database_manager_unittest.cc | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++-------------- 2 files changed, 58 insertions(+), 15 deletions(-) [I2017-02-09 13:51:29,313 635 140083593176896 git_cl.py] validator config enabled ['refs/heads/master', 'refs/branch-heads/*'] disabled [] refglobs for (this ref: refs/branch-heads/2987) Counting objects: 6, done. Delta compression using up to 48 threads. Compressing objects: 100% (6/6), done. Writing objects: 100% (6/6), 1.30 KiB | 0 bytes/s, done. Total 6 (delta 5), reused 0 (delta 0) remote: Resolving deltas: 100% (5/5) remote: Processing changes: refs: 1, done error: failed to push some refs to 'https://chromium.googlesource.com/chromium/src.git' Failed to push. If this persists, please file a bug.
,
Feb 9 2017
git drover -v --branch 2987 --cherry-pick 4e2788493f4bef375b52e78e5a9ee38f2d92b191
,
Feb 9 2017
After doing git fetch origin && git checkout origin/master && gclient sync --with_branch_heads, I ran, and got this output: ============== [scottmg:~/work/cr/src ((ff39aeb77a4a...))]$ git drover -v --branch 2987 --cherry-pick 4e2788493f4bef375b52e78e5a9ee38f2d92b191 DEBUG:root:Running git --help (cwd '/Users/scottmg/work/cr/src') DEBUG:root:Running git status (cwd '/Users/scottmg/work/cr/src') DEBUG:root:Running git fetch origin (cwd '/Users/scottmg/work/cr/src') DEBUG:root:Running git rev-parse refs/remotes/branch-heads/2987^{commit} (cwd '/Users/scottmg/work/cr/src') DEBUG:root:Running git rev-parse 4e2788493f4bef375b52e78e5a9ee38f2d92b191^{commit} (cwd '/Users/scottmg/work/cr/src') DEBUG:root:Running git show -s 4e2788493f4bef375b52e78e5a9ee38f2d92b191 (cwd '/Users/scottmg/work/cr/src') Going to cherry-pick """ commit 4e2788493f4bef375b52e78e5a9ee38f2d92b191 Author: vakh <vakh@chromium.org> Date: Tue Feb 7 19:11:54 2017 -0800 GetThreatSeverity should handle the case of CheckResourceUrl. Added the case statement and a unit test that forces a full hash match which causes this method to get executed. BUG= 689672 Review-Url: https://codereview.chromium.org/2680163002 Cr-Commit-Position: refs/heads/master@{#448885} """ to 2987. Continue (y/n)? y DEBUG:root:Running git rev-parse --git-dir (cwd '/Users/scottmg/work/cr/src') DEBUG:root:Creating checkout in /var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc DEBUG:root:Running git config core.sparsecheckout true (cwd '/var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc') DEBUG:root:Running git checkout -b drover_2987_9LooDc refs/remotes/branch-heads/2987 (cwd '/var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc') Previous HEAD position was ff39aeb77a4a... Simplify the registration of the Chrome Recovery component. Switched to a new branch 'drover_2987_9LooDc' DEBUG:root:Running git cherry-pick -x 4e2788493f4bef375b52e78e5a9ee38f2d92b191 (cwd '/var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc') error: could not apply 4e2788493f4b... GetThreatSeverity should handle the case of CheckResourceUrl. hint: after resolving the conflicts, mark the corrected paths hint: with 'git add <paths>' or 'git rm <paths>' hint: and commit the result with 'git commit' DEBUG:root:Running git status --porcelain (cwd '/var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc') DEBUG:root:Running git update-index --skip-worktree --stdin (cwd '/var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc') Error: Patch failed to apply. A workdir for this cherry-pick has been created in /var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc To continue, resolve the conflicts there and run git drover --continue /var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc To abort this cherry-pick run git drover --abort /var/folders/zd/_28wlgxs7nnbt3yjcj28615r004b6t/T/drover_2987_9LooDc ============== After resolving and doing the --continue step, things went fine. Can you post your output or see where it diverges?
,
Feb 9 2017
(uploaded cl is https://codereview.chromium.org/2687043003 fwiw.. i might have resolved conflicts incorrectly, not sure.)
,
Feb 9 2017
$ git drover -v --branch 2987 --cherry-pick 4e2788493f4bef375b52e78e5a9ee38f2d92b191 DEBUG:root:Running git --help (cwd '/usr/local/google/home/vakh/work/chrome/src') DEBUG:root:Running git status (cwd '/usr/local/google/home/vakh/work/chrome/src') DEBUG:root:Running git fetch origin (cwd '/usr/local/google/home/vakh/work/chrome/src') remote: Counting objects: 645, done remote: Finding sources: 100% (255/255) remote: Total 255 (delta 200), reused 250 (delta 200) Receiving objects: 100% (255/255), 148.51 KiB | 0 bytes/s, done. Resolving deltas: 100% (200/200), completed with 144 local objects. From https://chromium.googlesource.com/chromium/src b8fdf9d86bcb..8adf20ae3d05 master -> origin/master c57981891594..b2bd86444285 refs/branch-heads/2924 -> branch-heads/2924 157d48c67f05..0aeb5cf9de7f refs/branch-heads/2987 -> branch-heads/2987 DEBUG:root:Running git rev-parse refs/remotes/branch-heads/2987^{commit} (cwd '/usr/local/google/home/vakh/work/chrome/src') DEBUG:root:Running git rev-parse 4e2788493f4bef375b52e78e5a9ee38f2d92b191^{commit} (cwd '/usr/local/google/home/vakh/work/chrome/src') DEBUG:root:Running git show -s 4e2788493f4bef375b52e78e5a9ee38f2d92b191 (cwd '/usr/local/google/home/vakh/work/chrome/src') Going to cherry-pick """ commit 4e2788493f4bef375b52e78e5a9ee38f2d92b191 Author: vakh <vakh@chromium.org> Date: Tue Feb 7 19:11:54 2017 -0800 GetThreatSeverity should handle the case of CheckResourceUrl. Added the case statement and a unit test that forces a full hash match which causes this method to get executed. BUG= 689672 Review-Url: https://codereview.chromium.org/2680163002 Cr-Commit-Position: refs/heads/master@{#448885} """ to 2987. Continue (y/n)? y DEBUG:root:Running git rev-parse --git-dir (cwd '/usr/local/google/home/vakh/work/chrome/src') DEBUG:root:Creating checkout in /tmp/drover_2987_Ba5wWm DEBUG:root:Running git config core.sparsecheckout true (cwd '/tmp/drover_2987_Ba5wWm') DEBUG:root:Running git checkout -b drover_2987_Ba5wWm refs/remotes/branch-heads/2987 (cwd '/tmp/drover_2987_Ba5wWm') Switched to a new branch 'drover_2987_Ba5wWm' DEBUG:root:Running git cherry-pick -x 4e2788493f4bef375b52e78e5a9ee38f2d92b191 (cwd '/tmp/drover_2987_Ba5wWm') error: could not apply 4e2788493f4b... GetThreatSeverity should handle the case of CheckResourceUrl. hint: after resolving the conflicts, mark the corrected paths hint: with 'git add <paths>' or 'git rm <paths>' hint: and commit the result with 'git commit' DEBUG:root:Running git status --porcelain (cwd '/tmp/drover_2987_Ba5wWm') DEBUG:root:Running git update-index --skip-worktree --stdin (cwd '/tmp/drover_2987_Ba5wWm') Error: Patch failed to apply. A workdir for this cherry-pick has been created in /tmp/drover_2987_Ba5wWm To continue, resolve the conflicts there and run git drover --continue /tmp/drover_2987_Ba5wWm To abort this cherry-pick run git drover --abort /tmp/drover_2987_Ba5wWm **** Resolve conflicts **** $ git drover -v --continue /tmp/drover_2987_Ba5wWm DEBUG:root:Running git commit --no-edit (cwd '/tmp/drover_2987_Ba5wWm') DEBUG:root:Running git reset --hard (cwd '/tmp/drover_2987_Ba5wWm') DEBUG:root:Running git cl upload (cwd '/tmp/drover_2987_Ba5wWm') Using 50% similarity for rename/copy detection. Override with --similarity. Running presubmit upload checks ... Presubmit checks passed. components/safe_browsing_db/v4_local_database_manager.cc | 1 + components/safe_browsing_db/v4_local_database_manager_unittest.cc | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++-------------- 2 files changed, 58 insertions(+), 15 deletions(-) Upload server: https://codereview.chromium.org (change with -s/--server) Issue created. URL: https://codereview.chromium.org/2688013002 (patchset: 1) Uploading base file for components/safe_browsing_db/v4_local_database_manager_unittest.cc Uploading base file for components/safe_browsing_db/v4_local_database_manager.cc About to land on 2987. Continue (y/n)? y DEBUG:root:Running git cl land --bypass-hooks (cwd '/tmp/drover_2987_Ba5wWm') Using 50% similarity for rename/copy detection. Override with --similarity. Description: GetThreatSeverity should handle the case of CheckResourceUrl. Added the case statement and a unit test that forces a full hash match which causes this method to get executed. BUG= 689672 Review-Url: https://codereview.chromium.org/2680163002 Cr-Commit-Position: refs/heads/master@{#448885} (cherry picked from commit 4e2788493f4bef375b52e78e5a9ee38f2d92b191) Review-Url: https://codereview.chromium.org/2688013002 . components/safe_browsing_db/v4_local_database_manager.cc | 1 + components/safe_browsing_db/v4_local_database_manager_unittest.cc | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++-------------- 2 files changed, 58 insertions(+), 15 deletions(-) Counting objects: 6, done. Delta compression using up to 48 threads. Compressing objects: 100% (6/6), done. Writing objects: 100% (6/6), 1.29 KiB | 0 bytes/s, done. Total 6 (delta 5), reused 0 (delta 0) remote: Resolving deltas: 100% (5/5) remote: Processing changes: refs: 1, done error: failed to push some refs to 'https://chromium.googlesource.com/chromium/src.git' Failed to push. If this persists, please file a bug. Error: Command 'cl land --bypass-hooks' failed: Command '['git', 'cl', 'land', '--bypass-hooks']' returned non-zero exit status 1
,
Feb 9 2017
In my effort to land the CL manually (mimicking drover) I also saw this: $ git cl land --bypass-hooks -v Using 50% similarity for rename/copy detection. Override with --similarity. Description: [M57] GetThreatSeverity should handle the case of CheckResourceUrl. Added the case statement and a unit test that forces a full hash match which causes this method to get executed. BUG= 689672 Review-Url: https://codereview.chromium.org/2680163002 Cr-Commit-Position: refs/heads/master@{#448885} (cherry picked from commit 4e2788493f4bef375b52e78e5a9ee38f2d92b191) Review-Url: https://codereview.chromium.org/2679173006 . components/safe_browsing_db/v4_local_database_manager.cc | 1 + components/safe_browsing_db/v4_local_database_manager_unittest.cc | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++-------------- 2 files changed, 58 insertions(+), 15 deletions(-) [I2017-02-09 13:50:11,445 144970 139797727012672 git_cl.py] validator config enabled ['refs/heads/master', 'refs/branch-heads/*'] disabled [ ] refglobs for (this ref: refs/branch-heads/2987) error: failed to push some refs to 'https://chromium.googlesource.com/chromium/src.git' hint: Updates were rejected because the remote contains work that you do hint: not have locally. This is usually caused by another repository pushing hint: to the same ref. You may want to first integrate the remote changes hint: (e.g., 'git pull ...') before pushing again. hint: See the 'Note about fast-forwards' in 'git push --help' for details. Failed to push. If this persists, please file a bug. $ git branches -vv branch-heads/2987 0aeb5cf9de7f drover_2987_1i2Mbg * 3bbff286488e [ ahead 1 ] https://codereview.chromium.org/2679173006 (unsent) So I did: $ git pull remote: Counting objects: 259885, done remote: Finding sources: 100% (55/55) remote: Total 55 (delta 27), reused 55 (delta 27) Unpacking objects: 100% (55/55), done. From https://chromium.googlesource.com/chromium/src 0aeb5cf9de7f..1bd61c2508b7 refs/branch-heads/2987 -> branch-heads/2987 bfb00e35e0d1..5d27021cb89f master -> origin/master Merge made by the 'recursive' strategy. chrome/browser/media/encrypted_media_browsertest.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) But the problem persists: $ git cl land --bypass-hooks -v Using 50% similarity for rename/copy detection. Override with --similarity. Description: [M57] GetThreatSeverity should handle the case of CheckResourceUrl. Added the case statement and a unit test that forces a full hash match which causes this method to get executed. BUG= 689672 Review-Url: https://codereview.chromium.org/2680163002 Cr-Commit-Position: refs/heads/master@{#448885} (cherry picked from commit 4e2788493f4bef375b52e78e5a9ee38f2d92b191) Review-Url: https://codereview.chromium.org/2679173006 . components/safe_browsing_db/v4_local_database_manager.cc | 1 + components/safe_browsing_db/v4_local_database_manager_unittest.cc | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++-------------- 2 files changed, 58 insertions(+), 15 deletions(-) [I2017-02-09 13:51:29,313 635 140083593176896 git_cl.py] validator config enabled ['refs/heads/master', 'refs/branch-heads/*'] disabled [] r efglobs for (this ref: refs/branch-heads/2987) Counting objects: 6, done. Delta compression using up to 48 threads. Compressing objects: 100% (6/6), done. Writing objects: 100% (6/6), 1.30 KiB | 0 bytes/s, done. Total 6 (delta 5), reused 0 (delta 0) remote: Resolving deltas: 100% (5/5) remote: Processing changes: refs: 1, done error: failed to push some refs to 'https://chromium.googlesource.com/chromium/src.git'
,
Feb 9 2017
OK, I think that's post-git drover then. xhwang just posted on chromium-dev about git cl land failing in that way too "[chromium-dev] "git cl land" errors". It could just be that it's hard to get in between the CQ landing things now?
,
Feb 13 2017
,
Dec 20
|
|||
►
Sign in to add a comment |
|||
Comment 1 by scottmg@chromium.org
, Feb 9 2017