Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ModuleNotFoundError when importing BookReview in app.py #1

Open
faizanxmulla opened this issue Jan 17, 2024 · 0 comments
Open

ModuleNotFoundError when importing BookReview in app.py #1

faizanxmulla opened this issue Jan 17, 2024 · 0 comments

Comments

@faizanxmulla
Copy link
Owner

Description :

I am facing an issue with importing the BookReview class in my app.py file. The code works perfectly fine when running locally; however, I encounter a ModuleNotFoundError when deploying the application, specifically on the Render platform.

Steps to reproduce :

  1. Clone the repository - Link
  2. Navigate to the project directory - Implementing REST API's
  3. Run the application locally using : python app.py
  4. Confirm that the application runs without any import errors.
  5. Deploy the application on Render.
  6. Observe the ModuleNotFoundError: No module named 'book_review' error during deployment.

Expected Behavior :

The BookReview class should be successfully imported both locally and when deployed on Render, and the application should run without any import errors in both environments.

Actual Behavior :

The code works without issues when running locally but encounters a ModuleNotFoundError when deploying on Render.

Additional Information :

  • Python version - 3.8.10
  • Render build command - cd "Implementing REST API's" && pip install -r requirements.txt
  • Render start command - gunicorn "Implementing REST API's.app:app"

Relevant Links :

Screenshots :

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant