changeset 27339:6ab8c6511a6a

parsers: use absolute_import
author Gregory Szorc <gregory.szorc@gmail.com>
date Sat, 12 Dec 2015 13:39:29 -0500
parents 810337ae1b76
children 7b8b6e3b3571
files mercurial/pure/parsers.py tests/test-check-py3-compat.t
diffstat 2 files changed, 7 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/pure/parsers.py	Sat Dec 12 13:46:32 2015 -0500
+++ b/mercurial/pure/parsers.py	Sat Dec 12 13:39:29 2015 -0500
@@ -5,8 +5,13 @@
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2 or any later version.
 
-from mercurial.node import nullid
-import struct, zlib, cStringIO
+from __future__ import absolute_import
+
+import cStringIO
+import struct
+import zlib
+
+from .node import nullid
 
 _pack = struct.pack
 _unpack = struct.unpack
--- a/tests/test-check-py3-compat.t	Sat Dec 12 13:46:32 2015 -0500
+++ b/tests/test-check-py3-compat.t	Sat Dec 12 13:39:29 2015 -0500
@@ -122,7 +122,6 @@
   mercurial/manifest.py not using absolute_import
   mercurial/mdiff.py not using absolute_import
   mercurial/patch.py not using absolute_import
-  mercurial/pure/parsers.py not using absolute_import
   mercurial/pvec.py not using absolute_import
   mercurial/py3kcompat.py not using absolute_import
   mercurial/revlog.py not using absolute_import