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

A source distribution install can generates .pyc files with stale bytecode #437

Open
wimglenn opened this issue Sep 29, 2021 · 0 comments
Open

Comments

@wimglenn
Copy link

Steps to reproduce: use --no-binary option to force pip to use the .tar.gz distribution instead of the wheel (the problem doesn't occur when using a wheel install)

python3 -m pip install pycparser --no-binary=:all:

Then the file pycparser/__pycache__/c_ast.cpython-39.pyc is stale and needs to be recompiled (a bad mtime header gets burnt into the pyc file).

python3 -v -c "import pycparser" |& grep "stale\|bad mtime"
# bytecode is stale for 'pycparser.c_ast'

I guess the problem is somewhere inside _build_tables.py but I can't see what exactly.

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

No branches or pull requests

2 participants