Can't instal Scrapy/Twisted

妖精的绣舞 提交于 2019-12-12 04:26:45

问题


When I use "pip install" to install scrapy for Python on Windows, I request this feedback:

Exception:
Traceback (most recent call last):
  File "c:\users\limin\appdata\local\programs\python\python36\lib\site-packages\pip\compat\__init__.py", line 73, in console_to_str
    return s.decode(sys.__stdout__.encoding)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb6 in position 30: invalid start byte

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "c:\users\limin\appdata\local\programs\python\python36\lib\site-packages\pip\basecommand.py", line 215, in main
    status = self.run(options, args)
  File "c:\users\limin\appdata\local\programs\python\python36\lib\site-packages\pip\commands\install.py", line 342, in run
    prefix=options.prefix_path,
  File "c:\users\limin\appdata\local\programs\python\python36\lib\site-packages\pip\req\req_set.py", line 784, in install
    **kwargs
  File "c:\users\limin\appdata\local\programs\python\python36\lib\site-packages\pip\req\req_install.py", line 878, in install
    spinner=spinner,
  File "c:\users\limin\appdata\local\programs\python\python36\lib\site-packages\pip\utils\__init__.py", line 676, in call_subprocess
    line = console_to_str(proc.stdout.readline())
  File "c:\users\limin\appdata\local\programs\python\python36\lib\site-packages\pip\compat\__init__.py", line 75, in console_to_str
    return s.decode('utf_8')
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb6 in position 30: invalid start byte

I know it maybe a coding problem, but I don't know how to solve it. Who can help me? Thanks.


回答1:


Scrapy runs on Python 2.7 and Python 3.3 or above (except on Windows where Python 3 is not supported yet).

Sorry to be the bearer of bad news. It's worth a chance to use Anaconda, which is also stated in the Scrapy docs, if you're particularly hell bent on using Python 3.6. Or if it's urgent, you can use Python 2.7 and pip install scrapy. From my experience, Python 2.7 works a lot better when in comes to Scrapy.



来源:https://stackoverflow.com/questions/42903714/cant-instal-scrapy-twisted

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!