mercurial/shelve.py
changeset 50054 e2b89b6d4cdd
parent 50053 5327ae76b740
child 50079 acd2a0267660
--- a/mercurial/shelve.py	Thu Dec 15 03:04:58 2022 +0100
+++ b/mercurial/shelve.py	Thu Dec 15 02:54:06 2022 +0100
@@ -607,7 +607,8 @@
         activebookmark = _backupactivebookmark(repo)
         extra = {b'internal': b'shelve'}
         if includeunknown:
-            _includeunknownfiles(repo, pats, opts, extra)
+            with repo.dirstate.changing_files(repo):
+                _includeunknownfiles(repo, pats, opts, extra)
 
         if _iswctxonnewbranch(repo) and not _isbareshelve(pats, opts):
             # In non-bare shelve we don't store newly created branch