0

I am running a flask server on buster raspbian on my Raspberry Pi Zero W microcomputer. I am not using any environments and I am running my server by command

sudo python www.py

The server is working fine but is a bit slow. So my idea was to use pypy instead of python. However, pypy returns error

ImportError: No module named flask

I have tried all possible options to instal flask (sudo pip install flask, sudo pip3 install flask) to no avail.

Do you have any suggestion what to do?

The information that this simply cannot be done would also be useful, so I can move on finding other (working) solutions.

Pygmalion
  • 785
  • 2
  • 8
  • 24

1 Answers1

0

The standard system commands to install Python stuff always install it for CPython specifically, not PyPy.

Try:

sudo pypy -m ensurepip

sudo pypy -m pip install flask 
biruk1230
  • 3,042
  • 4
  • 16
  • 29