Pycharm interpreter error for Flaskr application (official Flask tutorial sample) -


my context

the issue

  • i open sample code of tutorial pycharm project

  • got invalid python interpreter error below snapshot

my question

how can fix it?

enter image description here

enter image description here

it's looking functional python installation.

if open 2 drop-down you've referenced you'll see selection of python installations on machine.

the better option though, create virtualenv current project, click on cog icon right of project interpreter drop-down , click create virtualenv , follow prompts.

once created, should pick virtualenv default python interpreter project , error disappear, though remember, because it's new virtualenv, won't yet have flask etc installed on it. can install flask library clicking + icon underneath cog , searching/installing flask.

alternatively, create requirements.txt file on project root directory, flask contents, , pycharm notice next time in .py file , suggest automatically install flask.


Comments

Popular posts from this blog

java - Suppress Jboss version details from HTTP error response -

gridview - Yii2 DataPorivider $totalSum for a column -

Sass watch command compiles .scss files before full sftp upload -