cyx-6 commented on issue #694:
URL: https://github.com/apache/tvm-ffi/issues/694#issuecomment-5133466565
Thanks for trying the pre-release on Python 3.15 free-threaded!
The traceback points at the cause directly:
```
File "/home/cc/venv/lib/python3.15t/site-packages/pathlib.py", line 10, in
<module>
from collections import Sequence
```
That's `site-packages/pathlib.py` — the old [`pathlib`
1.0.1](https://pypi.org/project/pathlib/) backport from PyPI, not the standard
library's `pathlib` (which is a package and has no such import). It was
published in 2014 for Python 2.7/3.2–3.3, became unnecessary in 3.4 when
`pathlib` entered the stdlib, and hasn't been updated since — its `from
collections import Sequence` stopped working in Python 3.10 when the ABC
aliases were removed.
Since it shadows the stdlib module, anything importing `pathlib` fails,
including Cython. That's why the build stops before reaching any tvm-ffi code —
it got through 39 of 41 steps, so the C++ all compiled fine.
The fix:
```bash
pip uninstall pathlib
```
`pip show pathlib` will show `Required-by`, in case something is pulling it
in as a transitive dependency.
I confirmed v0.1.13 builds and works on CPython 3.15 free-threaded once it's
removed. Note that 3.15 isn't in our wheel matrix yet (we build
`cp39`–`cp314t`), so a source build is the only route there for now.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]