安装第三方库出现 Python version 2.7 required, which was not found in the registry
来源:互联网 发布:java非递归后序遍历 编辑:程序博客网 时间:2024/04/24 06:33
安装第三方库出现 Python version 2.7 required, which was not found in the registry
建立一个文件 register.py 内容如下. 然后执行该脚本.
import sys from _winreg import * # tweak as necessaryversion = 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
- Notice:undefined variable
- Android开发环境搭建
- 关于代码清理和文件整理
- 透明度变化和所有px为单位的运动
- 大学规划
- 安装第三方库出现 Python version 2.7 required, which was not found in the registry
- hdu 3724 Encoded Barcodes
- 自己的规划
- 【传输层】TCP三次握手/四次挥手详解
- NASK汇编指令学习记录
- Android开发之多线程环境下更新界面
- 最初的成就
- Java动态代理的实现
- ++i