remotefilelog: fix various minor py3 problems
authorAugie Fackler <augie@google.com>
Mon, 05 Nov 2018 17:48:23 -0500
changeset 40526 1419f780207c
parent 40525 433189151d5d
child 40527 1b49b84d5ed5
remotefilelog: fix various minor py3 problems # skip-blame b prefixes and pycompat.long, nothing remotely interesting Differential Revision: https://phab.mercurial-scm.org/D5223
hgext/remotefilelog/basepack.py
hgext/remotefilelog/repack.py
hgext/remotefilelog/shallowutil.py
--- a/hgext/remotefilelog/basepack.py	Mon Nov 05 17:37:37 2018 -0500
+++ b/hgext/remotefilelog/basepack.py	Mon Nov 05 17:48:23 2018 -0500
@@ -512,8 +512,8 @@
         self.idxfp.write(struct.pack('!BB', self.VERSION, config))
 
 class indexparams(object):
-    __slots__ = ('fanoutprefix', 'fanoutstruct', 'fanoutcount', 'fanoutsize',
-                 'indexstart')
+    __slots__ = (r'fanoutprefix', r'fanoutstruct', r'fanoutcount',
+                 r'fanoutsize', r'indexstart')
 
     def __init__(self, prefixsize, version):
         self.fanoutprefix = prefixsize
--- a/hgext/remotefilelog/repack.py	Mon Nov 05 17:37:37 2018 -0500
+++ b/hgext/remotefilelog/repack.py	Mon Nov 05 17:48:23 2018 -0500
@@ -753,8 +753,8 @@
 class repackentry(object):
     """Simple class representing a single revision entry in the repackledger.
     """
-    __slots__ = ['filename', 'node', 'datasource', 'historysource',
-                 'datarepacked', 'historyrepacked', 'gced']
+    __slots__ = (r'filename', r'node', r'datasource', r'historysource',
+                 r'datarepacked', r'historyrepacked', r'gced')
     def __init__(self, filename, node):
         self.filename = filename
         self.node = node
--- a/hgext/remotefilelog/shallowutil.py	Mon Nov 05 17:37:37 2018 -0500
+++ b/hgext/remotefilelog/shallowutil.py	Mon Nov 05 17:48:23 2018 -0500
@@ -158,8 +158,8 @@
     return metabuf
 
 _metaitemtypes = {
-    constants.METAKEYFLAG: (int, long),
-    constants.METAKEYSIZE: (int, long),
+    constants.METAKEYFLAG: (int, pycompat.long),
+    constants.METAKEYSIZE: (int, pycompat.long),
 }
 
 def buildpackmeta(metadict):