Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I encountered the error as my docker container got exited after creating it from docker image.
After checking the docker logs I found the below error;
634c41109fd3 flaskapp:latest "python app.py" About a minute ago Exited (1) About a minute ago practical_wilbur
ubuntu@ip-172-31-92-203:~/two-tier-flask-app$ docker logs 634c
Traceback (most recent call last):
File "/app/app.py", line 2, in
from flask import Flask, render_template, request, redirect, url_for
File "/usr/local/lib/python3.9/site-packages/flask/init.py", line 7, in
from .app import Flask as Flask
File "/usr/local/lib/python3.9/site-packages/flask/app.py", line 28, in
from . import cli
File "/usr/local/lib/python3.9/site-packages/flask/cli.py", line 18, in
from .helpers import get_debug_flag
File "/usr/local/lib/python3.9/site-packages/flask/helpers.py", line 16, in
from werkzeug.urls import url_quote
ImportError: cannot import name 'url_quote' from 'werkzeug.urls' (/usr/local/lib/python3.9/site-packages/werkzeug/urls.py
After adding the "Werkzeug==2.0.1" in requirement.txt file,the issue got resolved.
So kindly review this and accept my pull request, if necessary.