mercurial/rewriteutil.py
branchstable
changeset 47787 48da5c325750
parent 47553 debc29900b97
child 48875 6000f5b25c9b
child 48991 d4752aeb20f1
--- a/mercurial/rewriteutil.py	Thu Jul 29 16:18:35 2021 -0400
+++ b/mercurial/rewriteutil.py	Thu Jul 29 16:23:45 2021 -0400
@@ -207,7 +207,12 @@
     hashes = re.findall(NODE_RE, commitmsg)
     unfi = repo.unfiltered()
     for h in hashes:
-        fullnode = scmutil.resolvehexnodeidprefix(unfi, h)
+        try:
+            fullnode = scmutil.resolvehexnodeidprefix(unfi, h)
+        except error.WdirUnsupported:
+            # Someone has an fffff... in a commit message we're
+            # rewriting. Don't try rewriting that.
+            continue
         if fullnode is None:
             continue
         ctx = unfi[fullnode]