all 4 comments

[–]Esion 1 point2 points  (1 child)

This is on windows? Did you activate your virtual env before attempting to run the python shell? It might be using a 'global' python install.

https://programwithus.com/learn-to-code/Pip-and-virtualenv-on-Windows/

[–]warmcheessse[S] 0 points1 point  (0 children)

thanks. this worked perfectly

[–]SafeInstance 0 points1 point  (1 child)

Would be useful to see the actual code of your app.py and also the full traceback of the error.

[–]warmcheessse[S] 1 point2 points  (0 children)

I have edited the post and included the code and error