安装第三方库出现 Python version 2.7 required, which was not found in the registry
来源:互联网 发布:dnf低配置优化补丁2017 编辑:程序博客网 时间:2024/04/27 09:37
安装第三方库出现 Python version 2.7 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()
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- 安装第三方库出现 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 内容如下.
- Python安装第三方库报错:Python version 2.7 required, which was not found in the registry.
- 安装第三方库时python version 2.7 required,which was not found in the registry
- 安装 MySQLdb 出现 Python version 2.7 required, which was not found in the registry
- 安装Python-Matplotlib时出现的问题--Python version 2.7 required, which was not found in the registry
- Android 网络通信框架Volley简介(Google IO 2013)(转载自http://blog.csdn.net/t12x3456/article/details/9221611)
- struts2 18拦截器详解(九) --- ScopedModelDrivenInterceptor
- 配置本地环境之apache安装
- magento upsell from cur_category
- 那些过目不忘的无线端交互设计(DRIBBBLE GIF动态图)
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- Same binary weight(stl 位运算)
- ios7 iBeacons
- Android之旅---AppWidget
- SQL Server 2008 中判断对象是否存在
- 运行期向spring加入动态代理类
- IOS变量的property属性设置和意义总结
- Java 与 Json的互相转换
- CTypedPtrList详细说明和具体用法