check-py3-compat: use an absolute path in sys.path stable
authorAnton Shestakov <av6@dwimlabs.net>
Wed, 04 May 2022 13:48:40 +0400
branchstable
changeset 49204 3f9125db466f
parent 49202 2d0e22171ef9
child 49205 45e71954612c
check-py3-compat: use an absolute path in sys.path The idea and rationale is similar to https://phab.mercurial-scm.org/D12599 (landed as 1b6e381521c5). Differential Revision: https://phab.mercurial-scm.org/D12621
contrib/check-py3-compat.py
--- a/contrib/check-py3-compat.py	Thu May 19 12:23:38 2022 +0100
+++ b/contrib/check-py3-compat.py	Wed May 04 13:48:40 2022 +0400
@@ -105,7 +105,7 @@
         # specified. When running as test-check-py3-compat.t, we technically
         # would import the correct paths, but it's cleaner to have both cases
         # use the same import logic.
-        sys.path.insert(0, '.')
+        sys.path.insert(0, os.getcwd())
         fn = check_compat_py3
 
     for f in sys.argv[1:]: