Closed Bug 1128698 Opened 6 years ago Closed 6 years ago

hooks should not prevent strips from completing

Categories

(Developer Services :: Mercurial: hg.mozilla.org, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: gps, Unassigned)

References

Details

Attachments

(13 files, 1 obsolete file)

39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
39 bytes, text/x-review-board-request
bkero
: review+
Details
Mercurial fires the pretxnchangegroup and similar hooks during `hg strip` when it applies the backup bundle to the repository. Our existing hooks will often reject the backup bundle application for whatever reason (tree closure, multiple heads, etc).

We should rewrite all our hooks that block changes to ignore changegroups where source=='strip'.

(This issue is responsible for me temporarily corruption the Aurora repo last week due to a broken strip operation.)
Attached file MozReview Request: bz://1128698/gps (obsolete) —
/r/3335 - hghooks: test bad strip behavior in commit-message.py hook
/r/3337 - hghooks: don't process strips from commit-message hook (bug 1128698)
/r/3339 - hghooks: add test showing prevent_string_changes exhibits wrong stripping behavior
/r/3341 - hghooks: don't process strips from prevent_string_changes hook (bug 1128698)
/r/3343 - hghooks: add test showing that prevent_uuid_changes disallows strip
/r/3345 - hghooks: don't process strips in prevent_uuid_changes hook (bug 1128698)

Pull down these commits:

hg pull review -r 10750a32148889eae21655b9e96fac77a9fbbd5f
Attachment #8559525 - Flags: review?(bkero)
Comment on attachment 8559525 [details]
MozReview Request: bz://1128698/gps

/r/3335 - hghooks: test bad strip behavior in commit-message.py hook
/r/3337 - hghooks: don't process strips from commit-message hook (bug 1128698)
/r/3339 - hghooks: add test showing prevent_string_changes exhibits wrong stripping behavior
/r/3341 - hghooks: don't process strips from prevent_string_changes hook (bug 1128698)
/r/3343 - hghooks: add test showing that prevent_uuid_changes disallows strip
/r/3345 - hghooks: don't process strips in prevent_uuid_changes hook (bug 1128698)
/r/3507 - hghooks: add test showing prevent_webidl_changes prevents strips
/r/3509 - hghooks: don't process strips in prevent_webidl_changes hook (bug 1128698)
/r/3511 - hghooks: add test showing that treeclosure prevents stripping
/r/3513 - hghooks: don't process strips from treeclosure hook (bug 1128698)
/r/3515 - hghooks: don't process strips in treeclosure_comm_central hook (bug 1128698)
/r/3517 - hghooks: don't process strips from try_mandatory hook (bug 1128698)
/r/3519 - hghooks: don't process strips from whitelist_* hooks (bug 1128698)

Pull down these commits:

hg pull review -r 5f2d38269e17eb5bc1c26bb5c47495264bb2d9d2
Comment on attachment 8559525 [details]
MozReview Request: bz://1128698/gps

https://reviewboard.mozilla.org/r/3333/#review2885

Ship It!
Attachment #8559525 - Flags: review?(bkero) → review+
I have synchronized mozhghooks on hgssh and hgweb machines.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Attachment #8559525 - Attachment is obsolete: true
Attachment #8619294 - Flags: review+
Attachment #8619295 - Flags: review+
Attachment #8619296 - Flags: review+
Attachment #8619297 - Flags: review+
Attachment #8619298 - Flags: review+
Attachment #8619299 - Flags: review+
Attachment #8619300 - Flags: review+
Attachment #8619301 - Flags: review+
Attachment #8619302 - Flags: review+
Attachment #8619303 - Flags: review+
Attachment #8619304 - Flags: review+
Attachment #8619305 - Flags: review+
Attachment #8619306 - Flags: review+
You need to log in before you can comment on or make changes to this bug.