You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docs/05_flask_smorest/02_data_model_improvements/README.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -108,14 +108,14 @@ Next, let's create the `.flaskenv` file:
108
108
109
109
```txt title=".flaskenv"
110
110
FLASK_APP=app
111
-
FLASK_ENV=development
111
+
FLASK_DEBUG=True
112
112
```
113
113
114
114
If we have the `python-dotenv` library installed, when we run the `flask run` command, Flask will read the variables inside `.flaskenv` and use them to configure the Flask app.
115
115
116
-
The configuration that we'll do is to define the Flask app file (here, `app.py`). Then we'll also set the Flask environment to `development`, which does a couple things:
116
+
The configuration that we'll do is to define the Flask app file (here, `app.py`). Then we'll also set the `FLASK_DEBUG` flag to `True`, which does a couple things:
117
117
118
-
-Sets debug mode to true, which makes the app give us better error messages
118
+
-Makes the app give us better error messages and return a traceback when we make requests if there's an error.
119
119
- Sets the app reloading to true, so the app restarts when we make code changes
120
120
121
121
We don't want debug mode to be enabled in production (when we deploy our app), but while we're doing development it's definitely a time-saving tool!
0 commit comments