-
-
Save TheMuellenator/29acd670326c6313bc2b8f7e66fd441f to your computer and use it in GitHub Desktop.
Day 61 L464 - Installing Flask-WTF
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask, render_template | |
app = Flask(__name__) | |
@app.route("/") | |
def home(): | |
return render_template('index.html') | |
@app.route("/login") | |
def login(): | |
return render_template("login.html") | |
if __name__ == '__main__': | |
app.run(debug=True) |
I still have error on "address already in use and start with a new server port"
For people who see this part in December 2022 and receive error : ImportError: cannot import name 'Markup' from 'jinja2', put below codes inside of requirement.txt. Good luck!.
click==8.0.4 Flask==2.0.3 itsdangerous==2.1.2 Jinja2==3.1.1 MarkupSafe==2.1.1 Werkzeug==2.0.3
Thanks man this works.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add Werkzeug==2.2.2 to your requirements.txt