changeset 52090:2876d077a796

filelog: drop the CamelCase name for `filelog.filelog` See 61557734c0ae for the reasoning.
author Matt Harbison <matt_harbison@yahoo.com>
date Wed, 23 Oct 2024 16:24:18 -0400
parents 9e94f9dbbbe8
children 35400ce47b64
files hgext/remotefilelog/debugcommands.py mercurial/filelog.py
diffstat 2 files changed, 2 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/remotefilelog/debugcommands.py	Wed Oct 23 16:22:21 2024 -0400
+++ b/hgext/remotefilelog/debugcommands.py	Wed Oct 23 16:24:18 2024 -0400
@@ -64,7 +64,7 @@
             queue.append(p2)
 
 
-def buildtemprevlog(repo, file) -> filelog.FileLog:
+def buildtemprevlog(repo, file) -> filelog.filelog:
     # get filename key
     filekey = hex(hashutil.sha1(file).digest())
     filedir = os.path.join(repo.path, b'store/data', filekey)
--- a/mercurial/filelog.py	Wed Oct 23 16:22:21 2024 -0400
+++ b/mercurial/filelog.py	Wed Oct 23 16:24:18 2024 -0400
@@ -7,8 +7,6 @@
 
 from __future__ import annotations
 
-import typing
-
 from typing import (
     Iterable,
     Iterator,
@@ -22,7 +20,6 @@
 )
 from .interfaces import (
     repository,
-    util as interfaceutil,
 )
 from .utils import storageutil
 from .revlogutils import (
@@ -31,7 +28,7 @@
 )
 
 
-class FileLog:
+class filelog:  # (repository.ifilestorage)
     _revlog: revlog.revlog
     nullid: bytes
     _fix_issue6528: bool
@@ -273,12 +270,6 @@
         return self._revlog.clone(tr, destrevlog._revlog, **kwargs)
 
 
-filelog = interfaceutil.implementer(repository.ifilestorage)(FileLog)
-
-if typing.TYPE_CHECKING:
-    filelog = FileLog
-
-
 class narrowfilelog(filelog):
     """Filelog variation to be used with narrow stores."""