largefile: replace the `normallookup` call when creating a new lfdirstate
This is the newer, more semantic API.
Differential Revision: https://phab.mercurial-scm.org/D11165
--- a/hgext/largefiles/lfutil.py Mon Jul 19 05:46:16 2021 +0200
+++ b/hgext/largefiles/lfutil.py Mon Jul 19 02:44:11 2021 +0200
@@ -229,9 +229,12 @@
if len(standins) > 0:
vfs.makedirs(lfstoredir)
- for standin in standins:
- lfile = splitstandin(standin)
- lfdirstate.normallookup(lfile)
+ with lfdirstate.parentchange():
+ for standin in standins:
+ lfile = splitstandin(standin)
+ lfdirstate.update_file(
+ lfile, p1_tracked=True, wc_tracked=True, possibly_dirty=True
+ )
return lfdirstate