Python3.7 scrapy遇到async报错

Python3.7 scrapy遇到async报错


2018.08.01
版本:
python3.7 64bit
Scrapy 1.5.1
Twisted 18.7.0


出现报错:

File”c:\users\name\appdata\locall\programs\python37\lib\site-packages\twisted\conch\manhole.py”, line 12,in from twisted.conch import manhole, telnet

def write(self, data, async=false):
File”c:\users\name\appdata\locall\programs\python37\lib\site-packages\twisted\conch\manhole.py”, line 154
def write(self, data, async=false):

Python3.7 scrapy遇到async报错_第1张图片

每当出新语法糖,这些单词就会成为关键字,禁止当作变量名了。
这里async下面出现报错,因为await async成为了3.7的关键字,不能作为变量名使用。
进入manhole.py将async全改成async1就阔以了。

或者…重装Python3.6可破。

你可能感兴趣的:(Python3.7 scrapy遇到async报错)