Error on running run.py <flash_bcrypt module missing>

Traceback (most recent call last):
File “run.py”, line 1, in
from mflix.factory import create_app
File “E:\M220P\Chapter1\chapter_1_driver_setup\m220\mflix-python\mflix\factory.py”, line 6, in
from flask_bcrypt import Bcrypt
ModuleNotFoundError: No module named ‘flask_bcrypt’

Hello nelson_selvam,

Have you tried installing the Python requirements? You can do this with the following command:

pip install -r requirements.txt

I hope this helps!

Matt

Hi everybody,

I also have a problem while running run.py. I’m using Anaconda3 for win32 and have installed the requirements but I’m getting this error:

(mflix) E:\2_Coding\MongoDB\Python\mflix-python>python run.py
bcrypt is required to use Flask-Bcrypt
Traceback (most recent call last):
File “run.py”, line 1, in
from mflix.factory import create_app
File “E:\2_Coding\MongoDB\Python\mflix-python\mflix\factory.py”, line 6, in
from flask_bcrypt import Bcrypt
File “E:\Anaconda3\lib\site-packages\flask_bcrypt.py”, line 27, in
raise e
File “E:\Anaconda3\lib\site-packages\flask_bcrypt.py”, line 24, in
import bcrypt
File “C:\Users\Cristina\AppData\Roaming\Python\Python36\site-packages\bcrypt_init_.py”, line 25, in
from bcrypt import _bcrypt
ImportError: DLL load failed: %1 is not a valid Win32 application.

Not sure what to do, any help will be appreciated!

Hello criztina,

What version of Windows are you using? A requirement for this course is a 64-bit version (Windows 8 or later).

Matt

Hi Matt,
I’m using Windows10 64-bit, I will try changing my python installations to the 64-bit version.

that was it, thank you Matt!

1 Like

I’m glad to hear you solved the problem! Good luck with the rest of the course.