disabled auto_reload by default in windows (#1280)

This commit is contained in:
abuckenheimer 2018-08-07 14:48:18 -04:00 committed by Raphael Deem
parent b238be54a4
commit 212da1029e

View File

@ -671,8 +671,8 @@ class Sanic:
"""
# Default auto_reload to false
auto_reload = False
# If debug is set, default it to true
if debug:
# If debug is set, default it to true (unless on windows)
if debug and os.name == 'posix':
auto_reload = True
# Allow for overriding either of the defaults
auto_reload = kwargs.get("auto_reload", auto_reload)