comparison mercurial/policy.py @ 51685:39e2b2d062c1

pytype: work around wrong ImportError flagging As documented in https://github.com/google/pytype/issues/163, newer versions of Pytype do not understand caught `ImportError`, so we temporarily ignore them where applicable.
author Rapha?l Gom?s <rgomes@octobus.net>
date Thu, 18 Jul 2024 12:03:29 +0200
parents 18c8c18993f0
children 7f0cb9ee0534
comparison
equal deleted inserted replaced
51684:25e7f9dcad0f 51685:39e2b2d062c1
35 b'rust+c': ('cext', None), 35 b'rust+c': ('cext', None),
36 b'rust+c-allow': ('cext', 'pure'), 36 b'rust+c-allow': ('cext', 'pure'),
37 } 37 }
38 38
39 try: 39 try:
40 from . import __modulepolicy__ 40 from . import __modulepolicy__ # type: ignore
41 41
42 policy = __modulepolicy__.modulepolicy 42 policy = __modulepolicy__.modulepolicy
43 except ImportError: 43 except ImportError:
44 pass 44 pass
45 45