changeset 52080:513b413702e8

localrepo: drop the CamelCase name for `localrepo.ilocalrepositorymain` See 61557734c0ae for the reasoning. This one is slightly different, however, because the `localrepository` class already subclasses the interface class in the type checking phase.
author Matt Harbison <matt_harbison@yahoo.com>
date Wed, 23 Oct 2024 17:08:57 -0400
parents fc77b968aace
children a021da4ec509
files mercurial/localrepo.py
diffstat 1 files changed, 1 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/localrepo.py	Wed Oct 23 17:04:59 2024 -0400
+++ b/mercurial/localrepo.py	Wed Oct 23 17:08:57 2024 -0400
@@ -83,7 +83,6 @@
 
 from .interfaces import (
     repository,
-    util as interfaceutil,
 )
 
 from .utils import (
@@ -1304,7 +1303,7 @@
     ]
 
 
-class LocalRepository(_localrepo_base_classes):
+class localrepository(_localrepo_base_classes):
     """Main class for representing local repositories.
 
     All local repositories are instances of this class.
@@ -3606,15 +3605,6 @@
         self._sidedata_computers[kind][category] = (keys, computer, flags)
 
 
-localrepository = interfaceutil.implementer(repository.ilocalrepositorymain)(
-    LocalRepository
-)
-
-if typing.TYPE_CHECKING:
-    # Help pytype by hiding the interface stuff that confuses it.
-    localrepository = LocalRepository
-
-
 def undoname(fn: bytes) -> bytes:
     base, name = os.path.split(fn)
     assert name.startswith(b'journal')