老师这个哪里出问题了,可以给我分析一下吗
来源:4-9 打造高可用flask mvc框架
慕田峪1533028
2019-12-21
C:\Users\dell\PycharmProjects\untitled4>SET ops_config=local && python manager.py runserver
File "manager.py", line 16
set Exception as e:
^
SyntaxError: invalid syntax
C:\Users\dell\PycharmProjects\untitled4>SET ops_config=local && python manager.py runserver
File "manager.py", line 16
export Exception as e:
^
SyntaxError: invalid syntax
C:\Users\dell\PycharmProjects\untitled4>set ops_config=local && python manager.py runserver
File "manager.py", line 16
set Exception as e:
^
SyntaxError: invalid syntax
C:\Users\dell\PycharmProjects\untitled4>set ops_config=local && python manager.py runserver
File "manager.py", line 16
SET Exception as e:
^
SyntaxError: invalid syntax
C:\Users\dell\PycharmProjects\untitled4>SET ops_config=local && python manager.py runserver
File "manager.py", line 16
SET Exception as e:
^
SyntaxError: invalid syntax
C:\Users\dell\PycharmProjects\untitled4>
4回答
-
编程浪子
2019-12-22
你好
你分开执行命令
set ops_config=local
enter 回车在执行
python manager.py runserver
00 -
慕田峪1533028
提问者
2019-12-21
except Exception as e:
这个报错00 -
慕田峪1533028
提问者
2019-12-21
# -*- coding: utf-8 -*-
from application import app,manager
from flask_script import Server
import www##web server
manager.add_command( "runserver", Server( host='0.0.0.0',port=app.config['SERVER_PORT'],use_debugger = True ,use_reloader = True) )def main():
manager.run( )if __name__ == '__main__':
try:
import sys
sys.exit( main() )
except Exception as e:
import traceback
traceback.print_exc()00 -
编程浪子
2019-12-21
你好
你讲你 manager.py 代码贴出来,特别看看第16行报错是什么
012019-12-21
相似问题