From 7401342d67a163b177af47cbc2e0b01e73b770c6 Mon Sep 17 00:00:00 2001 From: meehow Date: Tue, 27 Aug 2013 20:34:01 +0200 Subject: [PATCH] Update hello-world.md Shouldn't Flask start in debug mode? App server is reloaded automatically then. --- core/hello-world.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/core/hello-world.md b/core/hello-world.md index 549e556..3acb5bf 100644 --- a/core/hello-world.md +++ b/core/hello-world.md @@ -32,6 +32,7 @@ Open a new file called `catseverywhere.py` in your workshop directory. This migh return 'Hello World!' if __name__ == '__main__': + app.debug = True app.run() Let's break it down a little: @@ -50,9 +51,10 @@ The `@` is new, it's called a [_decorator_](http://en.wikipedia.org/wiki/Python_ The function itself returns the string "Hello World!". This will be sent to the web browser. if __name__ == '__main__': + app.debug = True app.run() -This is Python for "if this script is run directly then start the application". +This is Python for "if this script is run directly then enable debug mode and start the application". Now you can start running your first website!