只有两行会重现它,如下所示:
from multiprocessing import Event
e=Event()
给出:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/work/python2.7/lib/python2.7/multiprocessing/__init__.py", line 206, in Event
from multiprocessing.synchronize import Event
File "/home/work/python2.7/lib/python2.7/multiprocessing/synchronize.py", line 33, in <module>
" function, see issue 3770.")
ImportError: This platform lacks a functioning sem_open implementation, therefore, the required synchronization primitives needed will not function, see issue 3770.
但是,错误消息不正确。如果Python是由root安装的,我以root用户身份登录,那么效果很好。
我想普通用户缺乏运行API的特权,但我不知道哪个。
如何在linux2.6.9上使用Python 2.7.1解决这个问题?