在PythonAnywhere上升级python 3.8后Dash WSGI文件出现问题

时间:2020-02-03 06:10:49

标签: python wsgi plotly-dash pythonanywhere

升级我的virtualenv(按照requirements.txt的建议)后,确认它是 Python 3.8 ,然后重新加载Web应用程序(确保 PythonAnywhere 网页是< em> Python 3.8 )我收到以下错误。

我注意到在早期版本的Python 3.8 Problem Solution中发生了此错误。答案是“ 传递一个空列表作为Module()的第二个参数”。我看不到如何在WSGI文件中执行此操作。令人反感的代码行是from EF16 import EF。有什么想法吗?

2020-02-03 05:01:39,514: Error running WSGI application
2020-02-03 05:01:39,523: TypeError: required field "type_ignores" missing from Module
2020-02-03 05:01:39,524:   File "/var/www/davidcolinbryant_pythonanywhere_com_wsgi.py", line 34, in <module>
2020-02-03 05:01:39,524:     from EF16 import EF  # noqa
2020-02-03 05:01:39,524: 
2020-02-03 05:01:39,524:   File "./EF16.py", line 378, in <module>
2020-02-03 05:01:39,525:     EF = dash.Dash(__name__, external_stylesheets=external_stylesheets,
2020-02-03 05:01:39,525: 
2020-02-03 05:01:39,525:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/dash/dash.py", line 253, in __init__
2020-02-03 05:01:39,525:     self.server = flask.Flask(name) if server else None
2020-02-03 05:01:39,526: 
2020-02-03 05:01:39,526:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/flask/app.py", line 559, in __init__
2020-02-03 05:01:39,526:     self.add_url_rule(
2020-02-03 05:01:39,526: 
2020-02-03 05:01:39,527:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/flask/app.py", line 67, in wrapper_func
2020-02-03 05:01:39,527:     return f(self, *args, **kwargs)
2020-02-03 05:01:39,527: 
2020-02-03 05:01:39,527:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/flask/app.py", line 1217, in add_url_rule
2020-02-03 05:01:39,527:     self.url_map.add(rule)
2020-02-03 05:01:39,527: 
2020-02-03 05:01:39,528:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/werkzeug/routing.py", line 1388, in add
2020-02-03 05:01:39,528:     rule.bind(self)
2020-02-03 05:01:39,528: 
2020-02-03 05:01:39,528:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/werkzeug/routing.py", line 730, in bind
2020-02-03 05:01:39,528:     self.compile()
2020-02-03 05:01:39,529: 
2020-02-03 05:01:39,529:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/werkzeug/routing.py", line 794, in compile
2020-02-03 05:01:39,529:     self._build = self._compile_builder(False).__get__(self, None)
2020-02-03 05:01:39,529: 
2020-02-03 05:01:39,529:   File "/home/DavidColinBryant/.virtualenvs/Dash/lib/python3.8/site-packages/werkzeug/routing.py", line 951, in _compile_builder
2020-02-03 05:01:39,529:     code = compile(module, "<werkzeug routing>", "exec")

0 个答案:

没有答案