https://blog.csdn.net/u012424313/article/details/89511520
按照上面博客内容操作后,可能还是会报错:
ImportError: cannot import name 'DispatcherMiddleware' from 'werkzeug.wsgi' (f:\python\install\lib\site-packages\werkzeug\wsgi.py)
还是版本导致,werkzeug的版本为1.0.1,这个版本中没有DispatcherMiddleware方法,所以还是降低版本。(注意降低版本不能低于0.15版本,因为我们的pyspider要求大于0.15版本以上)
- # 卸载原有版本
python -m pip uninstall werkzeug
- #卸载完毕,安装0.16.1版本
python -m pip install werkzeug==0.16.1
- 运行pyspider all:
- 浏览器访问:
证明运行成功,Over!