(base) F:\learn>python learn2.py
* Serving Flask app "learn2" (lazy loading)
* Environment: production
WARNING: Do not use the development server in a production environment.
Use a production WSGI server instead.
* Debug mode: on
* Restarting with stat
* Debugger is active!
* Debugger PIN: 210-393-144
* Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)
127.0.0.1 - - [04/Aug/2020 21:07:49] "GET / HTTP/1.1" 200 -
127.0.0.1 - - [04/Aug/2020 21:07:50] "GET /favicon.ico HTTP/1.1" 404 -
hello,world 之flask web
# -*- coding: utf-8 -*-
"""
Spyder Editor
This is a temporary script file.
"""
from flask import Flask
app=Flask(__name__)
@app.route('/')
def index():
return '<h1>hello,wolrd</h1>'
if __name__=='__main__':
app.run(debug=True)