Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

typed-ast is dead and should be replaced by stdlib ast module #431

Open
sscherfke opened this issue Jun 19, 2024 · 2 comments
Open

typed-ast is dead and should be replaced by stdlib ast module #431

sscherfke opened this issue Jun 19, 2024 · 2 comments

Comments

@sscherfke
Copy link

The typed-ast project is archived since July 2023: https://github.com/python/typed_ast

It suggests to switch to the ast module from the stdlib.

@NangiDev
Copy link

I get this when trying to install

`
Building wheels for collected packages: typed-ast
Building wheel for typed-ast (pyproject.toml) ... error
error: subprocess-exited-with-error

× Building wheel for typed-ast (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [21 lines of output]
running bdist_wheel
running build
running build_py
creating build/lib.linux-x86_64-cpython-312/typed_ast
copying typed_ast/ast27.py -> build/lib.linux-x86_64-cpython-312/typed_ast
copying typed_ast/conversions.py -> build/lib.linux-x86_64-cpython-312/typed_ast
copying typed_ast/ast3.py -> build/lib.linux-x86_64-cpython-312/typed_ast
copying typed_ast/init.py -> build/lib.linux-x86_64-cpython-312/typed_ast
creating build/lib.linux-x86_64-cpython-312/typed_ast/tests
copying ast3/tests/test_basics.py -> build/lib.linux-x86_64-cpython-312/typed_ast/tests
running build_ext
building '_ast27' extension
creating build/temp.linux-x86_64-cpython-312/ast27/Custom
creating build/temp.linux-x86_64-cpython-312/ast27/Parser
creating build/temp.linux-x86_64-cpython-312/ast27/Python
x86_64-linux-gnu-gcc -fno-strict-overflow -Wsign-compare -DNDEBUG -g -O2 -Wall -fPIC -Iast27/Include -I/home/nangi/git/Compliance/frontend/.venv/include -I/usr/include/python3.12 -c ast27/Custom/typed_ast.c -o build/temp.linux-x86_64-cpython-312/ast27/Custom/typed_ast.o
ast27/Custom/typed_ast.c:1:10: fatal error: Python.h: No such file or directory
1 | #include "Python.h"
| ^~~~~~~~~~
compilation terminated.
error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for typed-ast`

Is that related to typed-ast being archived?

Can I work around this somehow?

@NangiDev
Copy link

For now I just removed the typed-ast dependency in pyproject.toml and installed it locally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants