pyscripter与python的关系_【转】PyScripter启动出错:Python could not be properly initialized. We must quit....

【问题】

折腾:

过程中,安装完毕PyScripter后,启动出错:

Python could not be properly initialized. We must quit.

【解决过程】

1. 由于我当前已经安装的Python版本是2.7.2的,所以,后来从启动菜单中,找到了PyScripter for 2.7的,打算去试试:

结果错误依旧。

2.顺便去看了看,对应的实现机制,得知,上述不同的快捷方式,是在启动时,添加了对应的参数:

3.看到:

中的解释,说是PyScripter,对于:

64位的系统(win7),必须安装32位的Python,然后才可以使用PyScripter的:

If you are using a 64bit version of Windows note that PyScripter will only work if a 32bit version of Python is installed.

如果是真的,那么真的有够变态。

4. 另外,看到开源中国:

也是这么说:

PyScripter只能使用 32位的 Python版本。

5.参考官网的issue:

中的解释是,64位的PyScripter,必须搭配64位的Python用。

而我这里,去启动Python shell(command line)后发现,我这里不是64位,而是32位的:

Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)] on win32      Type "help", "copyright", "credits" or "license" for more information.      >>>

所以,看来,貌似我应该去重新安装64位的Python才对。

6.然后去从Python主页,找到了x64的Python 2.7.3:

下载。

再去卸载掉原先的Python 2.7.2 32bit,再去安装此Python 2.7.3 64bit。

7.安装之后,去确认一下,的确是64位了:

Python 2.7.3 (default, Apr 10 2012, 23:24:47) [MSC v.1500 64 bit (AMD64)] on win32     Type "help", "copyright", "credits" or "license" for more information.      >>>

然后再去运行PyScripter for Python 2.7,看看结果。

终于可以正常运行了:

【总结】

目前最新的PyScripter,是支持64位的。

正常的逻辑是:

如果你安装了32位的Python,那么需要安装对应的32位的PyScripter;

如果你安装了64位的Python,那么需要安装对应的64位的PyScripter;

1. 如何检测Python是32位还是64位

开始->Python 2.7-> Python (command line) -> 可以看到:

Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)] on win32

Python 2.7.3 (default, Apr 10 2012, 23:24:47) [MSC v.1500 64 bit (AMD64)] on win32

等字样,其中就显示了是32 bit还是64 bit;

2.如何确定PyScripter是32位还是64位

下载PyScripter的时候,选择的是32位还是64位:

中的:

总之,Python和PyScripter的版本要互相匹配才行。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值