comparison mercurial/debugcommands.py @ 46794:e2f7b2695ba1

merge with stable
author Matt Harbison <matt_harbison@yahoo.com>
date Thu, 18 Mar 2021 18:24:59 -0400
parents b6ac612445e0 521ac0d7047f
children 13d973690ecd
comparison
equal deleted inserted replaced
46782:6b52cffd8d0a 46794:e2f7b2695ba1
1700 _(b"checking Python lib (%s)...\n"), 1700 _(b"checking Python lib (%s)...\n"),
1701 pythonlib or _(b"unknown"), 1701 pythonlib or _(b"unknown"),
1702 ) 1702 )
1703 1703
1704 try: 1704 try:
1705 from . import rustext 1705 from . import rustext # pytype: disable=import-error
1706 1706
1707 rustext.__doc__ # trigger lazy import 1707 rustext.__doc__ # trigger lazy import
1708 except ImportError: 1708 except ImportError:
1709 rustext = None 1709 rustext = None
1710 1710
2119 store = m.getstorage(b'') 2119 store = m.getstorage(b'')
2120 for n in add: 2120 for n in add:
2121 try: 2121 try:
2122 manifest = m[store.lookup(n)] 2122 manifest = m[store.lookup(n)]
2123 except error.LookupError as e: 2123 except error.LookupError as e:
2124 raise error.Abort(e, hint=b"Check your manifest node id") 2124 raise error.Abort(
2125 bytes(e), hint=b"Check your manifest node id"
2126 )
2125 manifest.read() # stores revisision in cache too 2127 manifest.read() # stores revisision in cache too
2126 return 2128 return
2127 2129
2128 cache = getcache() 2130 cache = getcache()
2129 if not len(cache): 2131 if not len(cache):
2454 ui=ui, 2456 ui=ui,
2455 ) 2457 )
2456 tr.close() 2458 tr.close()
2457 except ValueError as exc: 2459 except ValueError as exc:
2458 raise error.Abort( 2460 raise error.Abort(
2459 _(b'bad obsmarker input: %s') % pycompat.bytestr(exc) 2461 _(b'bad obsmarker input: %s') % stringutil.forcebytestr(exc)
2460 ) 2462 )
2461 finally: 2463 finally:
2462 tr.release() 2464 tr.release()
2463 finally: 2465 finally:
2464 l.release() 2466 l.release()