[Updated] D11827: errors: use detailed exit code when trying to merge file outside narrowspec

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Tue Nov 30 15:15:26 UTC 2021


Closed by commit rHG8e855e9984a6: errors: use detailed exit code when trying to merge file outside narrowspec (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D11827?vs=31199&id=31214

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D11827/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D11827

AFFECTED FILES
  mercurial/merge.py
  tests/test-narrow-merge.t
  tests/test-narrow-rebase.t

CHANGE DETAILS

diff --git a/tests/test-narrow-rebase.t b/tests/test-narrow-rebase.t
--- a/tests/test-narrow-rebase.t
+++ b/tests/test-narrow-rebase.t
@@ -96,4 +96,4 @@
   $ hg rebase -d 'desc("modify outside/f1")'
   rebasing 4:707c035aadb6 "conflicting outside/f1"
   abort: conflict in file 'outside/f1' is outside narrow clone
-  [255]
+  [20]
diff --git a/tests/test-narrow-merge.t b/tests/test-narrow-merge.t
--- a/tests/test-narrow-merge.t
+++ b/tests/test-narrow-merge.t
@@ -101,4 +101,4 @@
   $ hg merge 'desc("conflicting outside/f1")'
   abort: conflict in file 'outside/f1' is outside narrow clone (flat !)
   abort: conflict in file 'outside/' is outside narrow clone (tree !)
-  [255]
+  [20]
diff --git a/mercurial/merge.py b/mercurial/merge.py
--- a/mercurial/merge.py
+++ b/mercurial/merge.py
@@ -542,7 +542,7 @@
                 hint=_(b'merging in the other direction may work'),
             )
         else:
-            raise error.Abort(
+            raise error.StateError(
                 _(b'conflict in file \'%s\' is outside narrow clone') % f
             )
 



To: martinvonz, durin42, #hg-reviewers, Alphare
Cc: mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20211130/885eb99f/attachment-0002.html>


More information about the Mercurial-patches mailing list