We have very few callers left that call the low-level merge.update()
function. I think it's time to make it private. I'll remove the
remaining callers in coming patches, except for one call from the
rebase module. I hope to eventually fix that too, but it's more
complex because it requires teaching merge.graft() to work with a
dirty working copy.
Details
Details
- Reviewers
pulkit - Group Reviewers
hg-reviewers - Commits
- rHG2c86b9587740: merge: make low-level update() private (API)
rHG2748f837e192: merge: make low-level update() private (API)
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Event Timeline
Comment Actions
tests/test-install.t and tests/test-duplicateoptions.py are unhappy about this change.
--- /tmp/mercurial-ci/tests/test-duplicateoptions.py.out +++ /tmp/mercurial-ci/tests/test-duplicateoptions.py.err @@ -0,0 +1,9 @@ +Traceback (most recent call last): + File "/tmp/hgtests.j0rlbd/install/lib/python/mercurial/extensions.py", line 264, in _runextsetup + extsetup(ui) + File "/tmp/hgtests.j0rlbd/install/lib/python/hgext/fsmonitor/__init__.py", line 730, in extsetup + extensions.wrapfunction(merge, b'update', wrapupdate) + File "/tmp/hgtests.j0rlbd/install/lib/python/mercurial/extensions.py", line 652, in wrapfunction + origfn = getattr(container, funcname) +AttributeError: 'module' object has no attribute 'update' +*** failed to set up extension fsmonitor: 'module' object has no attribute 'update' ERROR: test-duplicateoptions.py output changed --- /tmp/mercurial-ci/tests/test-install.t +++ /tmp/mercurial-ci/tests/test-install.t.err @@ -164,12 +164,28 @@ debuginstall extension support $ hg debuginstall --config extensions.fsmonitor= --config fsmonitor.watchman_exe=false | grep atchman - fsmonitor checking for watchman binary... (false) - watchman binary missing or broken: warning: Watchman unavailable: watchman exited with code 1 + Traceback (most recent call last): + File "/tmp/hgtests.j0rlbd/install/lib/python/mercurial/extensions.py", line 264, in _runextsetup + extsetup(ui) + File "/tmp/hgtests.j0rlbd/install/lib/python/hgext/fsmonitor/__init__.py", line 730, in extsetup + extensions.wrapfunction(merge, b'update', wrapupdate) + File "/tmp/hgtests.j0rlbd/install/lib/python/mercurial/extensions.py", line 652, in wrapfunction + origfn = getattr(container, funcname) + AttributeError: 'module' object has no attribute 'update' + *** failed to set up extension fsmonitor: 'module' object has no attribute 'update' + [1] Verify the json works too: $ hg debuginstall --config extensions.fsmonitor= --config fsmonitor.watchman_exe=false -Tjson | grep atchman - "fsmonitor-watchman": "false", - "fsmonitor-watchman-error": "warning: Watchman unavailable: watchman exited with code 1", + Traceback (most recent call last): + File "/tmp/hgtests.j0rlbd/install/lib/python/mercurial/extensions.py", line 264, in _runextsetup + extsetup(ui) + File "/tmp/hgtests.j0rlbd/install/lib/python/hgext/fsmonitor/__init__.py", line 730, in extsetup + extensions.wrapfunction(merge, b'update', wrapupdate) + File "/tmp/hgtests.j0rlbd/install/lib/python/mercurial/extensions.py", line 652, in wrapfunction + origfn = getattr(container, funcname) + AttributeError: 'module' object has no attribute 'update' + *** failed to set up extension fsmonitor: 'module' object has no attribute 'update' + [1] Verify that Mercurial is installable with pip. Note that this MUST be the last test in this file, because we do some nasty things to the ERROR: test-install.t output changed