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

Reloader picks wrong module when Flask is run with the pydev debugger #1607

Closed
davidism opened this issue Jul 10, 2019 · 0 comments
Closed

Reloader picks wrong module when Flask is run with the pydev debugger #1607

davidism opened this issue Jul 10, 2019 · 0 comments

Comments

@davidism
Copy link
Member

@davidism davidism commented Jul 10, 2019

This is a weird situation where the #1416 fix to make python -m reloading more correct actually exposed an issue with PyDev. It rewrites python -m flask to python flask (which is clearly not correct), while Python itself rewrites it to python /path/to/flask_entry_point.py. Werkzeug still correctly detects that we were run as a module, but since sys.argv[0] is no longer a path but the module name, it incorrectly decides that there is a module named flask.flask in the current directory.

Originally posted by @davidism in pallets/flask#3297 (comment)

@davidism davidism added this to the 0.15.5 milestone Jul 10, 2019
@davidism davidism changed the title Reloader picks wrong module when run with pydev debugger Reloader picks wrong module when Flask is run with the pydev debugger Jul 10, 2019
@davidism davidism closed this Jul 10, 2019
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant