[PATCH 08 of 17 V2] py3: make largefiles/proto.py use absolute_import

liscju piotr.listkiewicz at gmail.com
Thu May 12 06:20:30 EDT 2016


# HG changeset patch
# User liscju <piotr.listkiewicz at gmail.com>
# Date 1462884118 -7200
#      Tue May 10 14:41:58 2016 +0200
# Node ID 2aa19d9da52236a331d3df2c4551ea5ef12cc996
# Parent  d184d25f5ae2ffa71d628319c33718bd9bac3863
py3: make largefiles/proto.py use absolute_import

diff -r d184d25f5ae2 -r 2aa19d9da522 hgext/largefiles/proto.py
--- a/hgext/largefiles/proto.py	Tue May 10 14:26:36 2016 +0200
+++ b/hgext/largefiles/proto.py	Tue May 10 14:41:58 2016 +0200
@@ -2,18 +2,27 @@
 #
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2 or any later version.
+from __future__ import absolute_import
 
 import os
 import re
 
-from mercurial import error, httppeer, util, wireproto
 from mercurial.i18n import _
 
+from mercurial import (
+    error,
+    httppeer,
+    util,
+    wireproto,
+)
+
+from . import (
+    storeutil,
+)
+
 urlerr = util.urlerr
 urlreq = util.urlreq
 
-import storeutil
-
 LARGEFILES_REQUIRED_MSG = ('\nThis repository uses the largefiles extension.'
                            '\n\nPlease enable it in your Mercurial config '
                            'file.\n')
diff -r d184d25f5ae2 -r 2aa19d9da522 tests/test-check-py3-compat.t
--- a/tests/test-check-py3-compat.t	Tue May 10 14:26:36 2016 +0200
+++ b/tests/test-check-py3-compat.t	Tue May 10 14:41:58 2016 +0200
@@ -10,7 +10,6 @@
   hgext/hgcia.py not using absolute_import
   hgext/highlight/__init__.py not using absolute_import
   hgext/highlight/highlight.py not using absolute_import
-  hgext/largefiles/proto.py not using absolute_import
   hgext/largefiles/remotestore.py not using absolute_import
   hgext/largefiles/reposetup.py not using absolute_import
   hgext/largefiles/storeutil.py not using absolute_import


More information about the Mercurial-devel mailing list