PYTHON3.7 SCRAPY CRAWL 运行出错解决方法SyntaxError: invalid syntax

2020-03-24 17:21:40 浏览数 (1)

代码语言:javascript复制
File "D:Python37libsite-packagesscrapyextensionstelnet.py", line 12, in <module>
    from twisted.conch import manhole, telnet
  File "D:Python37libsite-packagestwistedconchmanhole.py", line 154
    def write(self, data, async=False):
                              ^
SyntaxError: invalid syntax

Process finished with exit code 
**

## 解决方法
将源码manhole.py中的async参数更改为async1(注意更换全部(ctrl R 更换)) 
1.可以直接点击错误跳转 
2.也可以通过文件路径查找 
D:Python37Libsite-packagestwistedconchmanhole.py
改完再运行就好了

** 

0 人点赞