# HG changeset patch # User Augie Fackler # Date 2017-03-12 01:57:04 # Node ID ff2f90503d64ccd462c5526b7e389f96fdf0fcca # Parent 1470b0f771c8d78896c5c2965ed87f6f3562b527 context: work around `long` not existing on Python 3 I can't figure out what this branch is even trying to accomplish, and it was introduced in ac89a23ca814 which doesn't really shed any insight into why longs are treated differently from ints. diff --git a/mercurial/context.py b/mercurial/context.py --- a/mercurial/context.py +++ b/mercurial/context.py @@ -33,6 +33,7 @@ from . import ( obsolete as obsmod, patch, phases, + pycompat, repoview, revlog, scmutil, @@ -419,7 +420,7 @@ class changectx(basectx): self._node = repo.changelog.node(changeid) self._rev = changeid return - if isinstance(changeid, long): + if not pycompat.ispy3 and isinstance(changeid, long): changeid = str(changeid) if changeid == 'null': self._node = nullid