在安装scrapy时遇到问题

环境:win10(64位), Python3.6(64位)

安装scrapy:

1、安装wheel(安装后,便支持通过wheel文件安装软件)

pip3 install wheel

2、安装lxml、pyopenssl

lxml:解析XML的库,很强大,做爬虫BS4,selenium,XPATH都会用到

pip3 install lxml
pip3 install pyopenssl

3、安装pywin32

下载网址: https://sourceforge.net/projects/pywin32/files/pywin32/

根据自己python版本下载64位或32位((注意:pywin32版本跟随Python版本,即如果win是64位,但python是32位,pywin32要装32位的,与win无关))

双击安装(可能会遇到下列错误是注册表问题)

安装第三方库出现Python version 3.6 required, which was not found in the registry错误解决

建立一个文件 register.py 内容如下. 然后执行该脚本.

import sys

from winreg import *

# tweak as necessary
version = sys.version[:3]
installpath = sys.prefix regpath = "SOFTWARE\\Python\\Pythoncore\\%s\\" % (version)
installkey = "InstallPath"
pythonkey = "PythonPath"
pythonpath = "%s;%s\\Lib\\;%s\\DLLs\\" % (
installpath, installpath, installpath
) def RegisterPy():
try:
reg = OpenKey(HKEY_CURRENT_USER, regpath)
except EnvironmentError as e:
try:
reg = CreateKey(HKEY_CURRENT_USER, regpath)
SetValue(reg, installkey, REG_SZ, installpath)
SetValue(reg, pythonkey, REG_SZ, pythonpath)
CloseKey(reg)
except:
print("*** Unable to register!")
return
print("--- Python", version, "is now registered!")
return
if (QueryValue(reg, installkey) == installpath and
QueryValue(reg, pythonkey) == pythonpath):
CloseKey(reg)
print("=== Python", version, "is already registered!")
return
CloseKey(reg)
print("*** Unable to register!")
print("*** You probably have another Python installation!") if __name__ == "__main__":
RegisterPy()

4、下载twisted

下载twisted的wheel文件:http://www.lfd.uci.edu/~gohlke/pythonlibs/

pip3 install 下载目录\Twisted-17.9.0-cp36-cp36m-win_amd64.whl

安装可能会报错

error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools

说明电脑需要安装visual C++ Build Tools 2015

5、安装scrapy

pip3 install scrapy

6、大功告成

这是今天安装scrapy时遇到的问题 明天会发一篇关于scrapy的详细随笔有兴趣的可以关注

python version 3.6 required,which was not fount in the registry(python3.6安装scrapy)的更多相关文章

  1. 96、python version 3.6 required,which was not fount in the registry(python3.6安装scrapy)

    在安装scrapy时遇到问题 环境:win10(64位), Python3.6(64位) 安装scrapy: 1.安装wheel(安装后,便支持通过wheel文件安装软件) pip3 install ...

  2. 【转】安装第三方库出现 Python version 2.7 required, which was not found in the registry

    安装第三方库出现 Python version 2.7 required, which was not found in the registry 建立一个文件 register.py 内容如下. 然 ...

  3. Python 安装Twisted 提示python version 2.7 required,which was not found in the registry

    由于我安装Python64位的,下载后没注册,安装Twisted时老提示“python version 2.7 required,which was not found in the registry ...

  4. 安装第三方库出现 Python version 2.7 required, which was not found in the registry

    安装第三方库出现 Python version 2.7 required, which was not found in the registry 建立一个文件 register.py 内容如下. 然 ...

  5. 【亲测】Python:解决方案:Python Version 2.7 required, which was not found in the registry

    好久不更新随笔了,今天因为数据可视化作业,想抓取一些人人网好友关系数据,于是开始尝试python,用到numpy模块,安装的时候提示: 'Python Version 2.7 required, wh ...

  6. Python version 3.6 required, which was not found in the registry错误解决

    问题: 安装pywin32出现Python version 3.6 required, which was not found in the registry错误解决 解决: 建立一个文件 regis ...

  7. 安装pywin32出现--Python version 3.x required, which was not found in the registry

    这两天安装pywin32时出现了这个问题 双击.exe文件进入安装界面,然后点击下一步,它会自动定位你的python安装在什么地方,但是我的安装过程中未自动定位到python安装位置,并显示显示: 安 ...

  8. 安装 pywin32-218.win32-py2.7.exe 报错python version 2.7 required,which was not found in the registry解决方案

    随便在一个盘下 新建register.py的文件,内容如下: #   # script to register Python 2.0 or later for use with win32all    ...

  9. <转>python version 2.7 required,which was not found in the registry

    安装PIL-1.1.7.win32-py2.7的时候,不能再注册表中识别出来python2.7 方法:新建一个register.py 文件,把一下代码贴进去,保存 # # script to regi ...

随机推荐

  1. bzoj2870

    题解: 边分治入门题 当然并查集+维护直径更加简单 就是两棵树二合一直径是两颗树上的4个直径两两组合的最大值 查询路径长度你搞个差分查个lca就好了 点分治并不能做这题 分成多个联通块就gg了(点分治 ...

  2. [转]Ubuntu /home下中文目录如何修改成英文?

    http://www.linuxidc.com/Linux/2016-05/130873.htm 打开终端,在终端中输入命令: export LANG=en_US xdg-user-dirs-gtk- ...

  3. 使用java操作kudu

    使用maven导入kudu <dependency> <groupId>org.apache.kudu</groupId> <artifactId>ku ...

  4. OSPF协议之详细图解

    OSPF是一种基于SPF算法的链路状态路由协议. 上图是在一个OSPF区域里面添入一台新的路由器的时候,OSPF协议的工作过程,如果你能非常详细的叙述出这张图的话,基本上OSPF协议的工作过程你就掌握 ...

  5. Python学习(七) —— 装饰器、迭代器、生成器

    一.装饰器(decorator) 1.装饰器的本质是闭包函数,作用:在不改变函数的调用方式的情况下,给函数的前后添加新的功能 #装饰器的固定结构 def warpper(func): #定义装饰器函数 ...

  6. BZOJ1975 [Sdoi2010]魔法猪学院 k短路

    欢迎访问~原文出处——博客园-zhouzhendong 去博客园看该题解 题目传送门 - BZOJ1975 题意概括 给出一个无向图,让你走不同的路径,从1到n,路径长度之和不超过E,求最大路径条数. ...

  7. 040 Http与RPC

    一直在说,但是没有系统的文档理解过. 1.本质 目前有很多Java的RPC框架,有基于Json的,有基于XML,也有基于二进制对象的. 他们最本质的区别,就是RPC主要是基于TCP/IP协议的,而HT ...

  8. sql查询月的数据

    https://zhidao.baidu.com/question/557935059.html

  9. Idea中lombok不生效原因

    我们可以通过在maven中插入配置信息 <dependency> <groupId>org.projectlombok</groupId> <artifact ...

  10. TF:Tensorflow结构简单应用,随机生成100个数,利用Tensorflow训练使其逼近已知线性直线的效率和截距—Jason niu

    import os os.environ[' import tensorflow as tf import numpy as np x_data = np.random.rand(100).astyp ...