# HG changeset patch # User Matt Harbison # Date 2024-08-16 22:02:32 # Node ID c1d7ac70980b78394ce99d5a3ab56ed836d61c95 # Parent 0b2c978f595fb3984488eb3c5b442acc6b3a1653 dirstate: remove the interface decorator to help pytype This is the same change that was made for some of the manifest classes in 3e9a660b074a. Note that `dirstate` is still inferred as `Any`, but at least we have `DirState` with all of the expected attributes. diff --git a/mercurial/dirstate.py b/mercurial/dirstate.py --- a/mercurial/dirstate.py +++ b/mercurial/dirstate.py @@ -134,8 +134,7 @@ CHANGE_TYPE_PARENTS = "parents" CHANGE_TYPE_FILES = "files" -@interfaceutil.implementer(intdirstate.idirstate) -class dirstate: +class DirState: # used by largefile to avoid overwritting transaction callback _tr_key_suffix = b'' @@ -1807,3 +1806,6 @@ class dirstate: entry = self.get_entry(f) if not entry.p1_tracked: yield missing_from_ds % (f, node.short(p1)) + + +dirstate = interfaceutil.implementer(intdirstate.idirstate)(DirState)