pathlab icon indicating copy to clipboard operation
pathlab copied to clipboard

Library broken since python 3.11.0

Open shuckc opened this issue 1 year ago • 0 comments

It looks like Python's pathlib no longer has an _Accessor attribute:

$ python
Python 3.12.3 (main, Jul 31 2024, 17:43:48) [GCC 13.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from pathlab import IsoAccessor
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/chris/repos/zed/z-parser/venv/lib/python3.12/site-packages/pathlab/__init__.py", line 1, in <module>
    from pathlab.core.accessor import Accessor
  File "/home/chris/repos/zed/z-parser/venv/lib/python3.12/site-packages/pathlab/core/accessor.py", line 7, in <module>
    class Accessor(pathlib._Accessor, pathlib._PosixFlavour):
                   ^^^^^^^^^^^^^^^^^
AttributeError: module 'pathlib' has no attribute '_Accessor'
>>> 

This was found in cpython's release notes Misc/NEWS.d/3.11.0a5.rst:

The pathlib module's obsolete and internal _Accessor class has been removed to prepare the terrain for upcoming enhancements to the module.

shuckc avatar Sep 16 '24 09:09 shuckc