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

AssertionError on python 2.7.9 in Werkzeug>=0.15.3 #1553

Closed
DOlearczyk opened this issue May 20, 2019 · 4 comments
Closed

AssertionError on python 2.7.9 in Werkzeug>=0.15.3 #1553

DOlearczyk opened this issue May 20, 2019 · 4 comments
Labels
Milestone

Comments

@DOlearczyk
Copy link

DOlearczyk commented May 20, 2019

When trying to create new flask object, I get following error:

>>> from flask import Flask
>>> flask_app = Flask(__name__)
python: /mnt/builds/jenkins-builds/workspace/pulsar-8/RC/icedge-apl-4/build-intel-apollolake/tmp/work/core2-64-wrs-linux/python/2.7.9-r1/Python-2.7.9/Python/symtable.c:1319: symtable_visit_params: Assertion `arg->v.Name.ctx == Param || (arg->v.Name.ctx == Store && !toplevel)' failed.
Aborted (core dumped)

This assertion error only shows up with Werkzeug version 0.15.3 and 0.15.4. It doesn't appear with version 0.15.2.

OS: Pulsar Linux 8.0.0.14
Python: 2.7.9
Flask: 1.0.2

@davidism
Copy link
Member

@asottile 😢

It's ridiculous that direct bytecode manipulation appears to be a more stable API than the AST above it.

@davidism
Copy link
Member

@DOlearczyk we'll try to fix this, but you're very far behind on patch updates to Python 2.7. There is no easy way we can test on different patch versions of Python, so you're always running the risk of weird bugs in this case.

@davidism davidism added the bug label May 20, 2019
@davidism davidism added this to the 0.15.5 milestone May 20, 2019
@asottile
Copy link
Contributor

I think I know how to fix this, but I'd like to reproduce it first, I tried with 2.7.9 but it doesn't trigger the assertion -- are you perchance using a debug build of python?

I guess I could follow my own docs for doing that 🤔

@asottile
Copy link
Contributor

(I spent a ton of time trying to compile 2.7.9 on bionic, but libssl is too new for such an old python version 😆 -- ended up resorting to docker, see #1554 for the fix)

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

No branches or pull requests

3 participants