diff --git a/mercurial/dirstate.py b/mercurial/dirstate.py --- a/mercurial/dirstate.py +++ b/mercurial/dirstate.py @@ -5,11 +5,24 @@ # This software may be used and distributed according to the terms of the # GNU General Public License version 2 or any later version. -from node import nullid -from i18n import _ -import scmutil, util, osutil, parsers, encoding, pathutil, error -import os, stat, errno -import match as matchmod +from __future__ import absolute_import + +import errno +import os +import stat + +from .i18n import _ +from .node import nullid +from . import ( + encoding, + error, + match as matchmod, + osutil, + parsers, + pathutil, + scmutil, + util, +) propertycache = util.propertycache filecache = scmutil.filecache diff --git a/tests/test-check-py3-compat.t b/tests/test-check-py3-compat.t --- a/tests/test-check-py3-compat.t +++ b/tests/test-check-py3-compat.t @@ -102,7 +102,6 @@ mercurial/cmdutil.py not using absolute_import mercurial/commands.py not using absolute_import mercurial/context.py not using absolute_import - mercurial/dirstate.py not using absolute_import mercurial/dispatch.py requires print_function mercurial/exchange.py not using absolute_import mercurial/httpclient/__init__.py not using absolute_import