diff --git a/hgext3rd/absorb/__init__.py b/hgext3rd/absorb/__init__.py --- a/hgext3rd/absorb/__init__.py +++ b/hgext3rd/absorb/__init__.py @@ -48,6 +48,7 @@ util, ) from mercurial.i18n import _ +from mercurial.utils import stringutil testedwith = 'ships-with-fb-hgext' @@ -615,7 +616,7 @@ targetfctx = targetctx[path] fctxs, ctx2fctx = getfilestack(self.stack, path, seenfctxs) # ignore symbolic links or binary, or unchanged files - if any(f.islink() or util.binary(f.data()) + if any(f.islink() or stringutil.binary(f.data()) for f in [targetfctx] + fctxs if not isinstance(f, emptyfilecontext)): continue diff --git a/hgext3rd/lfs/wrapper.py b/hgext3rd/lfs/wrapper.py --- a/hgext3rd/lfs/wrapper.py +++ b/hgext3rd/lfs/wrapper.py @@ -17,6 +17,7 @@ ) from mercurial.i18n import _ from mercurial.node import bin, nullid, short +from mercurial.utils import stringutil from . import ( blobstore, @@ -90,7 +91,7 @@ # by default, we expect the content to be binary. however, LFS could also # be used for non-binary content. add a special entry for non-binary data. # this will be used by filectx.isbinary(). - if not util.binary(text): + if not stringutil.binary(text): # not hg filelog metadata (affecting commit hash), no "x-hg-" prefix metadata['x-is-binary'] = '0'