maxcountryman / maxcountryman/flask-bcrypt

ImportError: No module named bcrypt._bcrypt In GAE

Open
#41 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
327
Forks
65
PR merge metrics
No merged PRs in 30d

Description

bcrypt is required to use Flask-Bcrypt
ERROR 2016-11-10 09:07:35,749 wsgi.py:263]
Traceback (most recent call last):
File "/home/emu/google-cloud-sdk/platform/google_appengine/google/appengine/runtime/wsgi.py", line 240, in Handle
handler = _config_handle.add_wsgi_middleware(self._LoadHandler())
File "/home/emu/google-cloud-sdk/platform/google_appengine/google/appengine/runtime/wsgi.py", line 299, in _LoadHandler
handler, path, err = LoadObject(self._handler)
File "/home/emu/google-cloud-sdk/platform/google_appengine/google/appengine/runtime/wsgi.py", line 85, in LoadObject
obj = import(path[0])
File "/home/emu/GCP/gcp-bcrypt/main.py", line 5, in
from flask.ext.bcrypt import Bcrypt
File "/home/emu/GCP/gcp-bcrypt/lib/flask/exthook.py", line 81, in load_module
reraise(exc_type, exc_value, tb.tb_next)
File "/home/emu/GCP/gcp-bcrypt/lib/flask_bcrypt.py", line 27, in
raise e
ImportError: No module named bcrypt._bcrypt

I've create a Google App Engine project. And add Flask-Bcrypt in my requirements.txt file. Then install the dependencies in my project lib folder. When I run the project this gives me above error. But my Flask module which is also a 3rd party library works fine.
What's the solution? I'm using Python 2.7

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with lib/flask_bcrypt.py at line 27 and the Google App Engine dependency installation described in the issue. Reproduce the Python 2.7 deployment and determine why bcrypt._bcrypt is unavailable; done means Flask-Bcrypt imports successfully on GAE without the reported ImportError.

Written by the indexing model from the issue text.

Assessment

Tech stack
flask, google-cloud, python
Domain
cloud, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.