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
(helloflask-_7dot6hq) c:\helloflask\demos\hello>flask run
之后就报错,如下:
Environment: development
Debug mode: on
Restarting with stat
Traceback (most recent call last):
File "C:\ProgramData\Anaconda2\Lib\runpy.py", line 1
"main", fname, loader, pkg_name)
File "C:\ProgramData\Anaconda2\Lib\runpy.py", line 7
exec code in run_globals
File "C:\Users\Administrator.virtualenvs\helloflask
e_main_.py", line 9, in
File "c:\users\administrator.virtualenvs\helloflask
s\flask\cli.py", line 894, in main
cli.main(args=args, prog_name=name)
File "c:\users\administrator.virtualenvs\helloflask
s\flask\cli.py", line 557, in main
return super(FlaskGroup, self).main(*args, **kwarg
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 697, in main
rv = self.invoke(ctx)
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 1066, in invoke
return process_result(sub_ctx.command.invoke(sub
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 535, in invoke
return callback(*args, **kwargs)
File "c:\users\administrator.virtualenvs\helloflask
s\click\decorators.py", line 64, in new_func
return ctx.invoke(f, obj, *args[1:], **kwargs)
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 535, in invoke
return callback(*args, **kwargs)
File "c:\users\administrator.virtualenvs\helloflask
s\flask\cli.py", line 771, in run_command
threaded=with_threads, ssl_context=cert)
File "c:\users\administrator.virtualenvs\helloflask
s\werkzeug\serving.py", line 812, in run_simple
reloader_type)
File "c:\users\administrator.virtualenvs\helloflask
s\werkzeug_reloader.py", line 275, in run_with_reload
sys.exit(reloader.restart_with_reloader())
File "c:\users\administrator.virtualenvs\helloflask
s\werkzeug_reloader.py", line 132, in restart_with_re
close_fds=False)
File "C:\ProgramData\Anaconda2\Lib\subprocess.py", l
return Popen(*popenargs, **kwargs).wait()
File "C:\ProgramData\Anaconda2\Lib\subprocess.py", l
errread, errwrite)
File "C:\ProgramData\Anaconda2\Lib\subprocess.py", l
startupinfo)
TypeError: environment can only contain strings
有时候会报这个错误,如下:
(helloflask-_7dot6hq) c:\helloflask>cd demos\hell
(helloflask-_7dot6hq) c:\helloflask\demos\hello>fl
Usage: flask run [OPTIONS]
Error: Could not locate Flask application. You did
ironment variable.
折腾了几个小时,就是运行不了- - python版本:Python 2.7.14 |Anaconda custom (64-bit)| (default, Mar 27 2018, 12:30:5
.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
win7系统
The text was updated successfully, but these errors were encountered:
c:\helloflask>pipenv shell
Launching subshell in virtual environment鈥?Microsoft Wind
版权所有 (c) 2009 Microsoft Corporation。保留所有权利。
(helloflask-_7dot6hq) c:\helloflask>cd demos\hello
(helloflask-_7dot6hq) c:\helloflask\demos\hello>flask run
之后就报错,如下:
Environment: development
Debug mode: on
Restarting with stat
Traceback (most recent call last):
File "C:\ProgramData\Anaconda2\Lib\runpy.py", line 1
"main", fname, loader, pkg_name)
File "C:\ProgramData\Anaconda2\Lib\runpy.py", line 7
exec code in run_globals
File "C:\Users\Administrator.virtualenvs\helloflask
e_main_.py", line 9, in
File "c:\users\administrator.virtualenvs\helloflask
s\flask\cli.py", line 894, in main
cli.main(args=args, prog_name=name)
File "c:\users\administrator.virtualenvs\helloflask
s\flask\cli.py", line 557, in main
return super(FlaskGroup, self).main(*args, **kwarg
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 697, in main
rv = self.invoke(ctx)
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 1066, in invoke
return process_result(sub_ctx.command.invoke(sub
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 535, in invoke
return callback(*args, **kwargs)
File "c:\users\administrator.virtualenvs\helloflask
s\click\decorators.py", line 64, in new_func
return ctx.invoke(f, obj, *args[1:], **kwargs)
File "c:\users\administrator.virtualenvs\helloflask
s\click\core.py", line 535, in invoke
return callback(*args, **kwargs)
File "c:\users\administrator.virtualenvs\helloflask
s\flask\cli.py", line 771, in run_command
threaded=with_threads, ssl_context=cert)
File "c:\users\administrator.virtualenvs\helloflask
s\werkzeug\serving.py", line 812, in run_simple
reloader_type)
File "c:\users\administrator.virtualenvs\helloflask
s\werkzeug_reloader.py", line 275, in run_with_reload
sys.exit(reloader.restart_with_reloader())
File "c:\users\administrator.virtualenvs\helloflask
s\werkzeug_reloader.py", line 132, in restart_with_re
close_fds=False)
File "C:\ProgramData\Anaconda2\Lib\subprocess.py", l
return Popen(*popenargs, **kwargs).wait()
File "C:\ProgramData\Anaconda2\Lib\subprocess.py", l
errread, errwrite)
File "C:\ProgramData\Anaconda2\Lib\subprocess.py", l
startupinfo)
TypeError: environment can only contain strings
有时候会报这个错误,如下:
(helloflask-_7dot6hq) c:\helloflask>cd demos\hell
(helloflask-_7dot6hq) c:\helloflask\demos\hello>fl
Usage: flask run [OPTIONS]
Error: Could not locate Flask application. You did
ironment variable.
For more information see http://flask.pocoo.org/do
折腾了几个小时,就是运行不了- -
python版本:Python 2.7.14 |Anaconda custom (64-bit)| (default, Mar 27 2018, 12:30:5
.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
win7系统
The text was updated successfully, but these errors were encountered: