I have added Flask
and Flask-Script
to PyCharm
virtual environment. The app runs but PyCharm
gives me various errors:
Unresolved reference "Manager" (from flask.ext.script import Manager) Cannot find reference "script" in "__init__.py" (from flask.ext.script import Manager) No module named "script" (command = flask.ext.script.Command(app)
As a result code completion doesn't work.
So if I directly import the modules like import flask_script code completion works but I am not sure if that's an intended use!
I can fix that if I import flask_script
directly instead of flask.ext
. Is that a valid workaround?
Is there any other proper way to solve that? I read a few answers but none of them seems to address this issue.
In your venv > lib > python3.x > site-packages mark site-packages as source root.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With