Module not found Error

I tried to install the mflix package, I have followed all the instructions given in the course. However when I tried to run the python code run.py . I got the following error:-

Traceback (most recent call last):
File “run.py”, line 1, in
from mflix.factory import create_app
File “F:\mflix-python\mflix\factory.py”, line 5, in
from flask_cors import CORS
ModuleNotFoundError: No module named ‘flask_cors’

Can someone please advice how to proceed

Hi @Anandram_Mariappan

There are a couple of potential causes for this. I’d recommend checking out this thread to start Errors Installing Dependencies (pip install -r requirements.txt)

Can you confirm if you have loaded Conda or your virtual environment when running “run.py”?

The error indicates that you do not have the required flask_cors library installed, this means that the error is related to ensuring your environment has the complete set of requirements installed per the ‘requirements.txt’ file (which can be installed with pip and lists the required libraries and the specific version that should be installed).

Hope this helps and kindest regards,
Eoin