reviewboard: don't add review id during normal commits (bug 1413628); r?glob draft
authorGregory Szorc <gps@mozilla.com>
Thu, 02 Nov 2017 10:16:21 -0700
changeset 11782 2d983d11f429f13bd78eedab1df91ed5cead68ce
parent 11781 d877a7a1e44d07464cefc284848fab67ac4fa61d
child 11783 6249ecf9a76218415159c29f2293bea6f1aa3337
push id1816
push usergszorc@mozilla.com
push dateThu, 02 Nov 2017 19:46:54 +0000
reviewersglob
bugs1413628
reviewboard: don't add review id during normal commits (bug 1413628); r?glob The extension adds a MozReview-Commit-ID line to commit messages so each changeset created on the client is tracked. We currently add this line during local `hg commit` operations and on push/submit, as needed. Mercurial 4.4 changes some APIs around and introduces more cases where commits can be created. This introduces more places where we would need to monkeypatch functions to modify the commit message. Ideally we wouldn't care. However, the test harness needs to run on multiple Mercurial versions. And getting consistent output on multiple Mercurial versions will be a lot of work. Since the shelf life of the MozReview extension is limited since the service is going away, we take one of the easier roads out of this problem by removing the code that adds the review id during local commit. This means we'll defer to rewriting commit messages until submit time. This has the following effects: * It semantically changes the meaning of the embedded time in the review id from "commit time" to "review submit time." * Guarantees overhead on 1st review submission, as changesets will always need to be rewritten. * Backouts and other temporary commits don't have review ids * 1st reviews with dirty working directory will not be allowed in all cases instead of just the cases where submitted changesets didn't have a review identifier. MozReview-Commit-ID: 79uPLViwD0K
hgext/reviewboard/client.py
hgext/reviewboard/tests/test-bugzilla.t
hgext/reviewboard/tests/test-commit-message-as-file.t
hgext/reviewboard/tests/test-commit-message-file-old-structure.t
hgext/reviewboard/tests/test-commitid.t
hgext/reviewboard/tests/test-commits-added.t
hgext/reviewboard/tests/test-commits-deleted-no-obsolescence.t
hgext/reviewboard/tests/test-commits-deleted-obsolescence.t
hgext/reviewboard/tests/test-folding-obsolescence.t
hgext/reviewboard/tests/test-multiple-precursors.t
hgext/reviewboard/tests/test-obsolescence.t
hgext/reviewboard/tests/test-push.t
hgext/reviewboard/tests/test-review-commit-rewrite.t
hgext/reviewboard/tests/test-review-request-approval.t
hgext/reviewboard/tests/test-review-request-closed-discarded.t
hgext/reviewboard/tests/test-review-request-closed-submitted.t
hgext/reviewboard/tests/test-reviewer-unicode.t
hgext/reviewboard/tests/test-specify-reviewers.t
hgext/reviewboard/tests/test-unicode.t
--- a/hgext/reviewboard/client.py
+++ b/hgext/reviewboard/client.py
@@ -1036,35 +1036,16 @@ def reposetup(ui, repo):
     if not repo.local():
         return
 
     class reviewboardrepo(repo.__class__):
         @localrepo.repofilecache('reviews')
         def reviews(self):
             return reviewstore(self)
 
-        def commit(self, *args, **kwargs):
-            """Override commit to generate a unique commit identifier.
-
-            The commit identifier is used to track a logical commits across
-            history rewrites, including grafting. This is used as an index
-            of sorts in the review tool.
-            """
-            msg = ''
-            if args:
-                msg = args[0]
-            elif kwargs and 'text' in kwargs:
-                msg = kwargs['text']
-                del kwargs['text']
-
-            if self.reviews.remoteurl and msg:
-                msg, changed = addcommitid(msg, repo=self)
-
-            return super(reviewboardrepo, self).commit(msg, *args[1:], **kwargs)
-
     repo.__class__ = reviewboardrepo
     repo.noreviewboardpush = False
     repo.reviewid = None
 
     def prepushoutgoinghook(*args):
         # Mercurial 3.8 switched from local, remote, outgoing to a pushop arg
         if len(args) == 1:
             local = args[0].repo
--- a/hgext/reviewboard/tests/test-bugzilla.t
+++ b/hgext/reviewboard/tests/test-bugzilla.t
@@ -232,25 +232,27 @@ can happen if a reviewer is manually add
     summary: bug1
 
 Ensure r? in the commit description sets a review flag when pushing
 
   $ echo foo2 > foo
   $ hg commit -m 'Bug 2 - Foo 1 r?reviewer'
   $ hg push --config reviewboard.autopublish=true -c .
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/12f973a4cce5-aff74ce2-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 1 changesets for review
   
-  changeset:  2:b1aa746bcb39
+  changeset:  2:f9979978463c
   summary:    Bug 2 - Foo 1 r?reviewer
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/4 (draft)
   
   review id:  bz://2/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/3 (draft)
   (published review request 3)
 
   $ bugzilla dump-bug 2
--- a/hgext/reviewboard/tests/test-commit-message-as-file.t
+++ b/hgext/reviewboard/tests/test-commit-message-as-file.t
@@ -91,17 +91,17 @@ data, filename should remain the same.
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 0 changes to 1 files (+1 heads)
   remote: recorded push in pushlog
   submitting 1 changesets for review
   
-  changeset:  1:ecfec372b48c
+  changeset:  1:b649587d0bcc
   summary:    Bug 1 - Foo 2 - amended
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/2 (draft)
   
   review id:  bz://1/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/1 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   
@@ -115,24 +115,24 @@ data, filename should remain the same.
   bugs:
   - '1'
   commit: null
   submitter: default+5
   summary: Bug 1 - Foo 2 - amended
   description:
   - Bug 1 - Foo 2 - amended
   - ''
-  - 'MozReview-Commit-ID: APOgLo'
+  - 'MozReview-Commit-ID: 5ijR9k'
   target_people: []
   extra_data:
     calculated_trophies: true
   commit_extra_data:
     p2rb: true
     p2rb.author: test
-    p2rb.commit_id: ecfec372b48ce7b49eccf655e422acb4283283e0
+    p2rb.commit_id: b649587d0bcc3c194fe76d91bf1329a1f7590e28
     p2rb.commit_message_filediff_ids: '{"1": 2, "2": 5}'
     p2rb.commit_message_filename: commit-message-df673
     p2rb.first_public_ancestor: df67364c205763de5ad1d2c33fa78f87f6618289
     p2rb.identifier: bz://1/mynick
     p2rb.is_squashed: false
   diffs:
   - id: 3
     revision: 1
--- a/hgext/reviewboard/tests/test-commit-message-file-old-structure.t
+++ b/hgext/reviewboard/tests/test-commit-message-file-old-structure.t
@@ -106,17 +106,17 @@ Ammending commit should not create a com
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files (+1 heads)
   remote: recorded push in pushlog
   submitting 1 changesets for review
   
-  changeset:  1:9d4207e39e13
+  changeset:  1:1677aa2f30f2
   summary:    Bug 1 - Foo 2
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/2 (draft)
   
   review id:  bz://1/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/1 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   
@@ -130,24 +130,24 @@ Ammending commit should not create a com
   bugs:
   - '1'
   commit: null
   submitter: default+5
   summary: Bug 1 - Foo 2
   description:
   - Bug 1 - Foo 2
   - ''
-  - 'MozReview-Commit-ID: APOgLo'
+  - 'MozReview-Commit-ID: 5ijR9k'
   target_people: []
   extra_data:
     calculated_trophies: true
   commit_extra_data:
     p2rb: true
     p2rb.author: test
-    p2rb.commit_id: 9d4207e39e136eb5965ae29c2014e6334861b4db
+    p2rb.commit_id: 1677aa2f30f2071c46bd008be11b401675803676
     p2rb.first_public_ancestor: df67364c205763de5ad1d2c33fa78f87f6618289
     p2rb.identifier: bz://1/mynick
     p2rb.is_squashed: false
   diffs:
   - id: 3
     revision: 1
     base_commit_id: df67364c205763de5ad1d2c33fa78f87f6618289
     name: diff
@@ -178,29 +178,31 @@ Ammending commit should not create a com
 
 Entirely new review request within the same parent also has no commit message
 FileDiff.
   $ echo bar > bar.txt
   $ hg commit -A -m 'Bug 1 - Bar'
   adding bar.txt
   $ hg push -y
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/70dc6201428b-74f41091-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 2 changesets for review
   
-  changeset:  1:9d4207e39e13
+  changeset:  1:1677aa2f30f2
   summary:    Bug 1 - Foo 2
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/2
   
-  changeset:  2:fda2e193ec23
+  changeset:  2:dc2971575b0d
   summary:    Bug 1 - Bar
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/3 (draft)
   
   review id:  bz://1/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/1 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   
@@ -214,31 +216,31 @@ FileDiff.
   bugs:
   - '1'
   commit: null
   submitter: default+5
   summary: Bug 1 - Bar
   description:
   - Bug 1 - Bar
   - ''
-  - 'MozReview-Commit-ID: F63vXs'
+  - 'MozReview-Commit-ID: APOgLo'
   target_people: []
   extra_data:
     calculated_trophies: true
   commit_extra_data:
     p2rb: true
     p2rb.author: test
-    p2rb.commit_id: fda2e193ec23a353558ab5b384277e8e9c21fe83
+    p2rb.commit_id: dc2971575b0de9214b29406e986ff8a666f7d396
     p2rb.first_public_ancestor: df67364c205763de5ad1d2c33fa78f87f6618289
     p2rb.identifier: bz://1/mynick
     p2rb.is_squashed: false
   diffs:
   - id: 7
     revision: 1
-    base_commit_id: 9d4207e39e136eb5965ae29c2014e6334861b4db
+    base_commit_id: 1677aa2f30f2071c46bd008be11b401675803676
     name: diff
     extra: {}
     patch:
     - diff --git a/bar.txt b/bar.txt
     - new file mode 100644
     - '--- /dev/null'
     - +++ b/bar.txt
     - '@@ -0,0 +1,1 @@'
--- a/hgext/reviewboard/tests/test-commitid.t
+++ b/hgext/reviewboard/tests/test-commitid.t
@@ -9,40 +9,38 @@
   > EOF
 
   $ hg init repo1
   $ cd repo1
 
   $ touch foo
   $ hg -q commit -A -m initial
 
-Commit IDs are only added for repos known to be associated with
-MozReview. Install a dummy review URL to fake it out.
-
-  $ cat >> .hg/reviews << EOF
-  > u https://dummy1/
-  > r https://dummy2/
+  $ echo c1 > foo
+  $ hg commit -l - <<EOF
+  > commit 1
+  > 
+  > MozReview-Commit-ID: 124Bxg
   > EOF
 
-Commit ID should be present after review URL is defined.
-
-  $ echo c1 > foo
-  $ hg commit -m 'commit 1'
-
   $ hg log -T '{rev}:{node|short} {desc}\n'
   1:306d1563179b commit 1
   
   MozReview-Commit-ID: 124Bxg
   0:96ee1d7354c4 initial
 
 Verify commit IDs survive rebasing
 
   $ hg -q up -r 0
   $ touch bar
-  $ hg -q commit -A -m 'head 2'
+  $ hg -q commit -A -l - <<EOF
+  > head 2
+  > 
+  > MozReview-Commit-ID: 5ijR9k
+  > EOF
 
   $ hg rebase -s 1 -d 2
   rebasing 1:306d1563179b "commit 1"
   saved backup bundle to $TESTTMP/repo1/.hg/strip-backup/*.hg (glob)
 
   $ hg log -G -T '{rev}:{node|short} {desc}\n'
   o  2:ae4a1eb0e7a0 commit 1
   |
@@ -52,23 +50,35 @@ Verify commit IDs survive rebasing
   |  MozReview-Commit-ID: 5ijR9k
   o  0:96ee1d7354c4 initial
   
 
 Histedit should preserve commit ids when changesets are updated
 
   $ hg -q up -r 0
   $ echo 1 > bar
-  $ hg commit -A -m histedit1
+  $ hg commit -A -l - <<EOF
+  > histedit1
+  > 
+  > MozReview-Commit-ID: APOgLo
+  > EOF
   adding bar
   created new head
   $ echo 2 > bar
-  $ hg commit -m histedit2
+  $ hg commit -l - <<EOF
+  > histedit2
+  > 
+  > MozReview-Commit-ID: F63vXs
+  > EOF
   $ echo 3 > baz
-  $ hg commit -A -m histedit3
+  $ hg commit -A -l - <<EOF
+  > histedit3
+  > 
+  > MozReview-Commit-ID: JmjAjw
+  > EOF
   adding baz
 
   $ hg log -G -T '{rev}:{node|short} {desc}\n' -r '::.'
   @  5:0aa5a5b9a166 histedit3
   |
   |  MozReview-Commit-ID: JmjAjw
   o  4:bb89e4592815 histedit2
   |
@@ -112,25 +122,31 @@ Graft will preserve commit id.
   |
   |  MozReview-Commit-ID: JmjAjw
   o  0:96ee1d7354c4 initial
   
 "topic: foo" commit messages result in empty line
 
   $ hg -q up -r 0
   $ echo empty > foo
-  $ hg -q commit -m 'foo: empty'
+  $ hg -q commit -l - <<EOF
+  > foo: empty
+  > 
+  > MozReview-Commit-ID: OTOPw0
+  > EOF
 
 "key: value *" on a line doesn't get interpretted as metadata
 
   $ echo metadata > foo
   $ hg commit -l - << EOF
   > topic: foo
   > 
   > foo: bar baz
+  > 
+  > MozReview-Commit-ID: TA3f84
   > EOF
   $ hg log -G -T '{rev}:{node|short} {desc}\n' -r '::.'
   @  8:0d95b59bce48 topic: foo
   |
   |  foo: bar baz
   |
   |  MozReview-Commit-ID: TA3f84
   o  7:acd457e707fc foo: empty
--- a/hgext/reviewboard/tests/test-commits-added.t
+++ b/hgext/reviewboard/tests/test-commits-added.t
@@ -49,16 +49,18 @@
   (visit review url to publish these review requests so others can see them)
 
 Adding commits to old reviews should create new reviews
 
   $ echo 'foo3' > foo
   $ hg commit -m 'Bug 1 - Foo 3'
   $ hg push --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/ecd598733446-e31a960e-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 3 changesets for review
   
@@ -142,16 +144,18 @@ The parent review request should be upda
 Ensure we are able to deal with rids that are strings by forcing the commit
 rids to be strings and then pushing a new commit.
 
   $ rbmanage convert-draft-rids-to-str 1
   $ echo 'foo4' > foo
   $ hg commit -m 'Bug 1 - Foo 4'
   $ hg push --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/201fa84c0f22-9173ea58-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 4 changesets for review
   
--- a/hgext/reviewboard/tests/test-commits-deleted-no-obsolescence.t
+++ b/hgext/reviewboard/tests/test-commits-deleted-no-obsolescence.t
@@ -705,16 +705,18 @@ TODO this is sub-optimal. We should cons
 recycling behavior when commit IDs are present.
 
   $ hg -q up eeb6d49dcb09
 
   $ echo foo6 > foo6
   $ hg -q commit -A -m 'Bug 1 - Foo 6'
   $ hg --config reviewboard.autopublish=false push
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/abb8d26c0311-418bd058-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files (+1 heads)
   remote: recorded push in pushlog
   submitting 2 changesets for review
   
--- a/hgext/reviewboard/tests/test-commits-deleted-obsolescence.t
+++ b/hgext/reviewboard/tests/test-commits-deleted-obsolescence.t
@@ -784,29 +784,30 @@ Deleting a commit and adding a commit wi
 because the new commit is logically different
 
   $ hg -q up eeb6d49dcb09
 
   $ echo foo6 > foo6
   $ hg -q commit -A -m 'Bug 1 - Foo 6'
   $ hg --config reviewboard.autopublish=false push
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files (+1 heads)
   remote: recorded push in pushlog
   submitting 2 changesets for review
   
   changeset:  10:eeb6d49dcb09
   summary:    Bug 1 - Foo 2
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/3
   
-  changeset:  14:3b99865d1bab
+  changeset:  15:3b99865d1bab
   summary:    Bug 1 - Foo 6
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/7 (draft)
   
   review id:  bz://1/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/1 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
--- a/hgext/reviewboard/tests/test-folding-obsolescence.t
+++ b/hgext/reviewboard/tests/test-folding-obsolescence.t
@@ -64,44 +64,45 @@
   $ hg commit -A -m 'Bug 1 - Foo 4'
   adding foo4
   $ echo 'foo5' > foo5
   $ hg commit -A -m 'Bug 1 - Foo 5'
   adding foo5
 
   $ cat > commands << EOF
   > pick 0b3e14fe3ff1 Foo 1
-  > fold 713878e22d95 Foo 3
+  > fold b6ef165d96cf Foo 3
   > pick bce658a3f6d6 Foo 2
-  > fold 4d0f846364eb Foo 4
-  > pick 4e50148c492d Foo 5
+  > fold 803c58c4e82d Foo 4
+  > pick 08ef3d87dc2e Foo 5
   > EOF
   $ hg histedit 0b3e14fe3ff1 --commands commands | grep -v 'files updated'
   [1]
 
   $ rbmanage publish 1
   $ hg push --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
-  remote: added 3 changesets with 3 changes to ? files (+1 heads) (glob)
+  remote: added 3 changesets with 3 changes to 5 files (+1 heads)
   remote: recorded push in pushlog
   submitting 3 changesets for review
   
-  changeset:  9:0a7aec47f105
+  changeset:  9:6e03977d9469
   summary:    Bug 1 - Foo 1
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/2 (draft)
   
-  changeset:  12:88139569a7a8
+  changeset:  12:8a9d02dd9f4b
   summary:    Bug 1 - Foo 2
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/3 (draft)
   
-  changeset:  13:6e19c778ea00
+  changeset:  14:7345f147ad06
   summary:    Bug 1 - Foo 5
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/4 (draft)
   
   review id:  bz://1/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/1 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
--- a/hgext/reviewboard/tests/test-multiple-precursors.t
+++ b/hgext/reviewboard/tests/test-multiple-precursors.t
@@ -60,29 +60,30 @@ Splitting the changeset results in multi
   $ hg commit -A -m 'Bug 1 - Foo 3'
   adding foo3
   $ hg debugobsolete -d '0 0' 0b3e14fe3ff19019110705e72dcf563c0ef551f6 8cfe623ffa827c2382e41f8cd479005984c94e76 02a9514408b763f7534d4f250046b513799ffe4c
   obsoleted 1 changesets (?)
 
   $ rbmanage publish 1
   $ hg push --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 2 changesets)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 2 changesets with 2 changes to 2 files (+1 heads)
   remote: recorded push in pushlog
   submitting 2 changesets for review
   
-  changeset:  3:8cfe623ffa82
+  changeset:  5:8cfe623ffa82
   summary:    Bug 1 - Foo 2
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/2 (draft)
   
-  changeset:  4:02a9514408b7
+  changeset:  6:02a9514408b7
   summary:    Bug 1 - Foo 3
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/3 (draft)
   
   review id:  bz://1/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/1 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
--- a/hgext/reviewboard/tests/test-obsolescence.t
+++ b/hgext/reviewboard/tests/test-obsolescence.t
@@ -52,29 +52,30 @@ Now create a new head and push a rebase
   $ hg commit -A -m 'bar'
   adding bar
   created new head
   $ hg -q rebase -s 2 -d .
   $ hg up tip
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg push --reviewid 1 --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 2 changesets with 1 changes to 2 files (+1 heads)
   remote: recorded push in pushlog
   submitting 2 changesets for review
   
-  changeset:  3:696cdea118f5
+  changeset:  5:696cdea118f5
   summary:    bar
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/3 (draft)
   
-  changeset:  4:d699fd7a906a
+  changeset:  6:d699fd7a906a
   summary:    foo2
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/2 (draft)
   
   review id:  bz://1/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/1 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
--- a/hgext/reviewboard/tests/test-push.t
+++ b/hgext/reviewboard/tests/test-push.t
@@ -141,16 +141,18 @@ created if all the review requests didn'
   [1]
 
 Pushing patches from mq will result in a warning
 
   $ echo 'mq patch' > foo
   $ hg qnew -m 'mq patch' -d '0 0' patch1
   $ hg push -r . --reviewid 2 --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/7458cff9569f-a12db42c-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files (+1 heads)
   remote: recorded push in pushlog
   (You are using mq to develop patches. *) (glob)
   submitting 1 changesets for review
@@ -264,134 +266,138 @@ Prepare for multi changeset tests
   $ echo tip > foo
   $ hg commit -m 'Review tip'
   $ echo beyond > foo
   $ hg commit -m 'Beyond review tip'
   $ hg -q up -r .^
   $ echo newhead > foo
   $ hg commit -m 'Unrelated head'
   created new head
-  $ hg -q up -r 946b2ccfbcc1
+  $ hg -q up -r 84e8a1584aad
 
 A dirty working copy of a reviewed node will abort because of potential rewriting
 
   $ echo dirty > foo
-  $ hg push -r 8::10 --reviewid 7
+  $ hg push -r ::b55f2b9937c7 --reviewid 7
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 4 changesets)
   abort: uncommitted changes
   [255]
 
 A dirty working copy of a child of a review node will abort
 
-  $ hg push -r 8::9 --reviewid 7
+  $ hg push -r 84e8a1584aad::ae66c8223052 --reviewid 7
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 2 changesets)
   abort: uncommitted changes
   [255]
 
   $ hg revert -C foo
 
 Specifying a base revision limits reviewed changesets
 
-  $ hg push -r 8::10 --reviewid 7 --config reviewboard.autopublish=false
+  $ hg push -r 84e8a1584aad::b55f2b9937c7 --reviewid 7 --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 3 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/9b775dfe71c8-8ceb7cd1-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 4 changesets with 4 changes to 1 files (+1 heads)
   remote: recorded push in pushlog
   submitting 3 changesets for review
   
-  changeset:  8:29cc7959baba
+  changeset:  8:8115cfda01b9
   summary:    Review base
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/14 (draft)
   
-  changeset:  9:6d5a65ca7a91
+  changeset:  9:1b934b086d87
   summary:    Middle commit
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/15 (draft)
   
-  changeset:  10:946b2ccfbcc1
+  changeset:  10:2af788c5bc5e
   summary:    Review tip
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/16 (draft)
   
   review id:  bz://7/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/13 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
 
 Specifying multiple -r arguments selects base and tip
 
-  $ hg push -r 8 -r 10 --reviewid 8 --config reviewboard.autopublish=false
+  $ hg push -r 8115cfda01b9 -r 2af788c5bc5e --reviewid 8 --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
   searching for changes
   no changes found
   submitting 3 changesets for review
   
-  changeset:  8:29cc7959baba
+  changeset:  8:8115cfda01b9
   summary:    Review base
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/18 (draft)
   
-  changeset:  9:6d5a65ca7a91
+  changeset:  9:1b934b086d87
   summary:    Middle commit
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/19 (draft)
   
-  changeset:  10:946b2ccfbcc1
+  changeset:  10:2af788c5bc5e
   summary:    Review tip
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/20 (draft)
   
   review id:  bz://8/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/17 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
   [1]
 
 Specifying multiple -r in reverse order still works
 
-  $ hg push -r 10 -r 8 --reviewid 9 --config reviewboard.autopublish=false
+  $ hg push -r 2af788c5bc5e -r 8115cfda01b9 --reviewid 9 --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
   searching for changes
   no changes found
   submitting 3 changesets for review
   
-  changeset:  8:29cc7959baba
+  changeset:  8:8115cfda01b9
   summary:    Review base
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/22 (draft)
   
-  changeset:  9:6d5a65ca7a91
+  changeset:  9:1b934b086d87
   summary:    Middle commit
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/23 (draft)
   
-  changeset:  10:946b2ccfbcc1
+  changeset:  10:2af788c5bc5e
   summary:    Review tip
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/24 (draft)
   
   review id:  bz://9/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/21 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
   [1]
 
 -r and -c are mutually exclusive
 
-  $ hg push -c 8 -r 9
+  $ hg push -c 8115cfda01b9 -r 1b934b086d87
   abort: cannot specify both -r and -c
   [255]
 
 -c can be used to select a single changeset to review
 
-  $ hg push -c 9 --reviewid 11 --config reviewboard.autopublish=false
+  $ hg push -c 1b934b086d87 --reviewid 11 --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
   searching for changes
   no changes found
   submitting 1 changesets for review
   
-  changeset:  9:6d5a65ca7a91
+  changeset:  9:1b934b086d87
   summary:    Middle commit
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/26 (draft)
   
   review id:  bz://11/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/25 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   (visit review url to publish these review requests so others can see them)
@@ -402,50 +408,52 @@ Reviewing merge commits is rejected
   $ hg up -q -r 0
   $ echo merge1 > foo
   $ hg commit -m 'Bug 1 - Merge A'
   created new head
   $ hg up -q -r 0
   $ echo merge2 > foo
   $ hg commit -m 'Bug 1 - Merge B'
   created new head
-  $ hg merge --tool internal:other 47aed783df21
+  $ hg merge --tool internal:other 63170dd88642
   0 files updated, 1 files merged, 0 files removed, 0 files unresolved
   (branch merge, don't forget to commit)
   $ hg commit -m 'Bug 1 - Do merge'
 
   $ hg push
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 3 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/b21a68e5d0e0-20fc94c0-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 3 changesets with 3 changes to 1 files (+1 heads)
   remote: recorded push in pushlog
   submitting 3 changesets for review
-  abort: cannot review merge commits (abd430935a8b)
+  abort: cannot review merge commits (1ea610ba7399)
   [255]
 
 We disallow completely empty revisions.
 
   $ hg up -q -r 0
   $ hg qnew -m 'mq patch' -d '0 0' empty-patch
   $ hg push
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
-  abort: cannot review empty changeset e3b1b495a7d2
+  abort: cannot review empty changeset 72a12b75c815
   (add files to or remove changeset)
   [255]
 
 Check for empty commits not at the tip
 
   $ echo after-empty > foo
   $ hg qnew -m 'Bug 1 - after empty' -d '0 0' after-empty
   $ hg push
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
-  abort: cannot review empty changeset e3b1b495a7d2
+  abort: cannot review empty changeset 72a12b75c815
   (add files to or remove changeset)
   [255]
 
   $ hg qpop -a
   popping after-empty
   popping empty-patch
   patch queue now empty
 
--- a/hgext/reviewboard/tests/test-review-commit-rewrite.t
+++ b/hgext/reviewboard/tests/test-review-commit-rewrite.t
@@ -84,16 +84,38 @@ Rewriting on a child should work against
 Check rewriting when submitter == reviewer
 
   $ bugzilla create-bug TestProduct TestComponent 'Second Bug'
   $ echo another >> foo
   $ hg commit -m 'Bug 2 - Initial commit to review r?l3author' foo
   $ exportbzauth l3author@example.com password
   $ hg --verbose --config bugzilla.username=l3author@example.com --config bugzilla.apikey=$l3key push -c .
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  committing files:
+  foo
+  committing manifest
+  committing changelog
+  resolving manifests
+  1 changesets found
+  uncompressed size of bundle content:
+       218 (changelog)
+       165 (manifests)
+       135  foo
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/ee66baf1dbbf-77ce5791-addcommitid.hg (glob)
+  1 changesets found
+  uncompressed size of bundle content:
+       247 (changelog)
+       165 (manifests)
+       135  foo
+  adding branch
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
   searching for changes
   1 changesets found
   uncompressed size of bundle content:
        247 (changelog)
        165 (manifests)
        135  foo
   remote: adding changesets
   remote: adding manifests
--- a/hgext/reviewboard/tests/test-review-request-approval.t
+++ b/hgext/reviewboard/tests/test-review-request-approval.t
@@ -835,26 +835,26 @@ Review requests created by L3 users
   bugs:
   - '2'
   commit: null
   submitter: level3
   summary: Bug 2 - initial commit to review
   description:
   - Bug 2 - initial commit to review
   - ''
-  - 'MozReview-Commit-ID: F63vXs'
+  - 'MozReview-Commit-ID: 5ijR9k'
   target_people:
   - level1a
   - level1b
   extra_data:
     calculated_trophies: true
   commit_extra_data:
     p2rb: true
     p2rb.author: test
-    p2rb.commit_id: b366ef9913208b4030857319aa20520f229a74f3
+    p2rb.commit_id: 8d040df91cf3c26975d93bda40dd09ed91866737
     p2rb.commit_message_filediff_ids: '{"1": 8}'
     p2rb.commit_message_filename: commit-message-3a9f6
     p2rb.first_public_ancestor: 3a9f6899ef84c99841f546030b036d0124a863cf
     p2rb.identifier: bz://2/mynick
     p2rb.is_squashed: false
   diffs:
   - id: 7
     revision: 1
@@ -884,26 +884,26 @@ Even a ship-it from an L1 user will give
   bugs:
   - '2'
   commit: null
   submitter: level3
   summary: Bug 2 - initial commit to review
   description:
   - Bug 2 - initial commit to review
   - ''
-  - 'MozReview-Commit-ID: F63vXs'
+  - 'MozReview-Commit-ID: 5ijR9k'
   target_people:
   - level1a
   - level1b
   extra_data:
     calculated_trophies: true
   commit_extra_data:
     p2rb: true
     p2rb.author: test
-    p2rb.commit_id: b366ef9913208b4030857319aa20520f229a74f3
+    p2rb.commit_id: 8d040df91cf3c26975d93bda40dd09ed91866737
     p2rb.commit_message_filediff_ids: '{"1": 8}'
     p2rb.commit_message_filename: commit-message-3a9f6
     p2rb.first_public_ancestor: 3a9f6899ef84c99841f546030b036d0124a863cf
     p2rb.identifier: bz://2/mynick
     p2rb.is_squashed: false
   diffs:
   - id: 7
     revision: 1
@@ -946,26 +946,26 @@ ship-its. Posting a new diff should not 
   bugs:
   - '2'
   commit: null
   submitter: level3
   summary: Bug 2 - initial commit to review
   description:
   - Bug 2 - initial commit to review
   - ''
-  - 'MozReview-Commit-ID: F63vXs'
+  - 'MozReview-Commit-ID: 5ijR9k'
   target_people:
   - level1a
   - level1b
   extra_data:
     calculated_trophies: true
   commit_extra_data:
     p2rb: true
     p2rb.author: test
-    p2rb.commit_id: bedcf57f515ad540f582962e37ecd424d82424fd
+    p2rb.commit_id: 8b63e5a1962062c91912d9d7628e3b9c191d3e25
     p2rb.commit_message_filediff_ids: '{"1": 8, "2": 11}'
     p2rb.commit_message_filename: commit-message-3a9f6
     p2rb.first_public_ancestor: 3a9f6899ef84c99841f546030b036d0124a863cf
     p2rb.identifier: bz://2/mynick
     p2rb.is_squashed: false
   diffs:
   - id: 7
     revision: 1
--- a/hgext/reviewboard/tests/test-review-request-closed-discarded.t
+++ b/hgext/reviewboard/tests/test-review-request-closed-discarded.t
@@ -768,16 +768,18 @@ The attachment for the review request sh
 Pushing to a discarded review series will create a new series
 
   $ rbmanage closediscarded 1
 
   $ echo foo3 > foo
   $ hg commit -m 'Bug 1 - Foo 3'
   $ hg push --config reviewboard.autopublish=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/ecd598733446-e31a960e-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 3 changesets for review
   
--- a/hgext/reviewboard/tests/test-review-request-closed-submitted.t
+++ b/hgext/reviewboard/tests/test-review-request-closed-submitted.t
@@ -186,16 +186,18 @@ Child review request with ID 2 should be
 
 Submitting against a published review request results in error
 TODO Fix the error output (bug 1169664)
 
   $ echo foo3 > foo
   $ hg commit -m 'Bug 1 - Foo 3'
   $ hg push
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/ecd598733446-e31a960e-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 3 changesets for review
   abort: Review request is submitted or discarded.
--- a/hgext/reviewboard/tests/test-reviewer-unicode.t
+++ b/hgext/reviewboard/tests/test-reviewer-unicode.t
@@ -50,16 +50,18 @@ Adding a reviewer with emoji in name str
 Adding a reviewer with emoji in name string who is not accepting reviews
 
   $ mozreview exec bmoweb /var/lib/bugzilla/bugzilla/scripts/user-prefs.pl uni@example.com set block_reviews on
   'block_reviews' set to 'on'
   $ echo foo3 > foo
   $ hg commit -m 'Bug 1 - awesome stuff again; r?uni'
   $ hg push
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/c531f3f06e81-7dca74aa-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 2 changesets for review
   
--- a/hgext/reviewboard/tests/test-specify-reviewers.t
+++ b/hgext/reviewboard/tests/test-specify-reviewers.t
@@ -529,26 +529,27 @@ those specified in the commit summary.
 Unrecognized reviewers should be ignored
 
   $ hg phase --public -r .
   $ bugzilla create-bug TestProduct TestComponent 'Second Bug'
   $ echo blah >> foo
   $ hg commit -m 'Bug 2 - different stuff; r?cthulhu'
   $ hg push --reviewid 2
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 1 changesets for review
   unrecognized reviewer: cthulhu
   
-  changeset:  27:e0c35a6f9fc6
+  changeset:  28:c0f7a0ead8a3
   summary:    Bug 2 - different stuff; r?cthulhu
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/13 (draft)
   
   review id:  bz://2/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/12 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   
@@ -556,54 +557,56 @@ Unrecognized reviewers should be ignored
   (published review request 12)
   $ rbmanage list-reviewers 12
   
 
 Reviewer identification should be case insensitive.
 
   $ echo blah >> foo
   $ hg commit -m 'Bug 2 - better stuff; r?ryanvm'
-  $ hg push -c 28
+  $ hg push -c .
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 1 changesets for review
   
-  changeset:  28:dce90596f792
+  changeset:  30:d78ae37a43e4
   summary:    Bug 2 - better stuff; r?ryanvm
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/14 (draft)
   
   review id:  bz://2/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/12 (draft)
   
   publish these review requests now (Yn)?  y
   (published review request 12)
 
   $ rbmanage list-reviewers 14
   RyanVM
 
 Reviewer deduction can be disabled with a config option.
 
   $ echo blah >> foo
   $ hg commit -m 'Bug 2 - awesome stuff; r?remus'
-  $ hg push -c 29 --config reviewboard.deduce-reviewers=false
+  $ hg push -c . --config reviewboard.deduce-reviewers=false
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 1 changesets)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 1 changesets with 1 changes to 1 files
   remote: recorded push in pushlog
   submitting 1 changesets for review
   
-  changeset:  29:df9e974cc15e
+  changeset:  32:8156d1d4e67f
   summary:    Bug 2 - awesome stuff; r?remus
   review:     http://$DOCKER_HOSTNAME:$HGPORT1/r/15 (draft)
   
   review id:  bz://2/mynick
   review url: http://$DOCKER_HOSTNAME:$HGPORT1/r/12 (draft)
   
   (review requests lack reviewers; visit review url to assign reviewers)
   
--- a/hgext/reviewboard/tests/test-unicode.t
+++ b/hgext/reviewboard/tests/test-unicode.t
@@ -141,16 +141,18 @@ Put some wonky byte sequences in the dif
 こんにちは世界 from above
 
   >>> with open('foo', 'wb') as fh:
   ...     fh.write(b'hello world \xe3\x81\x93\xe3\x82\x93\xe3\x81\xab\xe3\x81\xa1\xe3\x81\xaf\xe4\xb8\x96\xe7\x95\x8c\n')
   $ hg commit -m 'Bug 2 - tip'
 
   $ hg --config bugzilla.username=author@example.com --config bugzilla.apikey=${authorkey} --config reviewboard.autopublish=false push -r 2::
   pushing to ssh://$DOCKER_HOSTNAME:$HGPORT6/test-repo
+  (adding commit id to 2 changesets)
+  saved backup bundle to $TESTTMP/client/.hg/strip-backup/3aef4f4bb0d9-c7f01cb3-addcommitid.hg (glob)
   searching for changes
   remote: adding changesets
   remote: adding manifests
   remote: adding file changes
   remote: added 2 changesets with 2 changes to 1 files
   remote: recorded push in pushlog
   submitting 2 changesets for review