Comment 7 for bug 1932313

Revision history for this message
Dan Bungert (dbungert) wrote :

As Michael mentions, it's not clear to me that this was reverted in upstream python. I did a test against python 3.10.0b4 and 3.9.6 and was able to see the same problem in both.

The above line from Chris is a very efficient test case.
./brz -Derror selftest -v -Oselftest.timeout=6000 breezy.tests.test_plugins.TestPlugins

The python PR addresses,
which links to https://<email address hidden>/thread/DE3MDGB2JGOJ3X4NWEGJS26BK6PJUPKW/ ,
which talks about sys.path problems when using '.' as a method to reference CWD.

I'm testing this change, which makes the above TestPlugins pass but still has failures elsewhere

--- old/breezy/ 2020-07-28 02:11:05 +0000
+++ new/breezy/ 2021-07-26 22:50:14 +0000
@@ -154,6 +154,8 @@

     paths = _iter_plugin_paths(_env_plugin_path(), path)
+ # Workaround regression in py3.9.5 where '.' doesn't get treated as cwd
+ paths = [os.getcwd() if path == '.' else path for path in paths]

     return _Path(name, blocks, extra_details, paths)