From d612ffb0a3e6cb2b909a9a8ff1c0a25122190feb Mon Sep 17 00:00:00 2001 From: Miguel Grinberg Date: Sat, 12 May 2018 22:11:27 -0400 Subject: [PATCH] fix broken sys.argv list --- flask/cli.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flask/cli.py b/flask/cli.py index efc1733e..a97bf359 100644 --- a/flask/cli.py +++ b/flask/cli.py @@ -887,7 +887,7 @@ def main(as_module=False): # Python rewrites "python -m flask" to the path to the file in argv. # Restore the original command so that the reloader works. - sys.argv = ['-m', this_module] + args + sys.argv = [sys.executable, '-m', this_module] + args else: name = None