Bug report
I was trying to add Python3.12 beta 2 to the test suit of xonsh . The tests on Windows were failing because of the difference in behaviour of PureWindowsPath.
This can be reproduced like this
in Python 3.11
>>> from pathlib import PurePosixPath, PureWindowsPath
>>> PurePosixPath("///tmp")
PurePosixPath('/tmp')
>>> PureWindowsPath(r"\\\tmp")
PureWindowsPath('/tmp')
but the same in Python 3.12.0b2 would be giving different result
In [1]: from pathlib import PurePosixPath, PureWindowsPath
In [2]: PurePosixPath("///tmp")
Out[2]: PurePosixPath('/tmp')
In [3]: PureWindowsPath(r"\\\tmp")
Out[3]: PureWindowsPath('///tmp')
I've checked the changelog and this change of behaviour wasn't mentioned in it.
Your environment
- CPython versions tested on: 3.12.0b2
- Operating system and architecture: Windows 64bit
Bug report
I was trying to add Python3.12 beta 2 to the test suit of xonsh . The tests on Windows were failing because of the difference in behaviour of PureWindowsPath.
This can be reproduced like this
in Python 3.11
but the same in Python 3.12.0b2 would be giving different result
I've checked the changelog and this change of behaviour wasn't mentioned in it.
Your environment