I was following this guide https://realpython.com/blog/python/setting-up-a-simple-ocr-server/ and got to the part where I run cli.py python flask_server/cli.py
python flask_server/cli.py
I had the same error. My solution is
$ pip3 install pytesseract
since I have python 2 and python 3 installed together.