[BUG] Catnip fails to run
mike-dooley66 opened this issue · 2 comments
When I try to run the Flask app in the Catnip example I get the following error:
Traceback (most recent call last):
File "/usr/src/app/./app.py", line 1, in
from flask import Flask, render_template
File "/usr/local/lib/python3.10/site-packages/flask/init.py", line 21, in
from .app import Flask, Request, Response
File "/usr/local/lib/python3.10/site-packages/flask/app.py", line 25, in
from . import cli, json
File "/usr/local/lib/python3.10/site-packages/flask/json/init.py", line 21, in
from itsdangerous import json as _json
ImportError: cannot import name 'json' from 'itsdangerous' (/usr/local/lib/python3.10/site-packages/itsdangerous/init.py)
To Reproduce
- Download the repo for the Flask App
- Build the container --> docker build -t yourusername/catnip .
- Run the container --> docker run -p 8888:5000 yourusername/catnip
- See error
Expected behavior
Output should indicate that the webserver is running
There's a simple fix to this issue.
In the requirements.txt file update the version of flask to 2.0.1 or above:Flask==2.0.1
Here's more info in this issue.
Fixed in #313