You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It implements the documented Traversable interface, but it doesn't implement the undocumented SimplePath interface used by importlib.metadata. This causes an exception from this code in numpy/testing/_private/utils.py:
File "/data/data/com.chaquo.python.pkgtest3/files/chaquopy/AssetFinder/requirements/numpy/testing/_private/utils.py", line 86, in <module>
File "stdlib/importlib/metadata/__init__.py", line 922, in locate_file
AttributeError: 'AssetPath' object has no attribute 'parent'
Review all Path properties and methods to see if there's anything else we should add at the same time.
The following workaround is good enough for numpy. In the production fix, we should also make it possible to traverse out of the importer root and get a normal Path object.
Review all Path properties and methods to see if there's anything else we should add at the same time.
There are far too many of them, but in theory nothing should be depending on anything except for the methods of Traversable and SimplePath. In fact, we've had no reports of any missing members affecting anyone except via importlib.metadata, which is even more likely to respect the limited interface.
Activity
mhsmith commentedon Jan 11, 2026
The following workaround is good enough for numpy. In the production fix, we should also make it possible to traverse out of the importer root and get a normal Path object.
mhsmith commentedon Sep 20, 2026
#1471 suggests that
dirnamemay be simpler thanrpartition, but check first whether they're totally equivalent.mhsmith commentedon Oct 2, 2026
There are far too many of them, but in theory nothing should be depending on anything except for the methods of
TraversableandSimplePath. In fact, we've had no reports of any missing members affecting anyone except viaimportlib.metadata, which is even more likely to respect the limited interface.Implement AssetPath.parent (closes chaquo#1433)