RuntimeError: Wrong version of PyObjC C API
quantonganh opened this issue · comments
- 10.14
It works on my workstation with:
pyobjc-core (3.1.1)
pyobjc-framework-Cocoa (3.1.1)
pyobjc-framework-Quartz (3.1.1)
But it doesn't work on the build machine with the same versions of OS, pyobjc-core
, ...
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/PyObjC/Cocoa/__init__.py", line 9, in <module>
import Foundation
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/PyObjC/Foundation/__init__.py", line 9, in <module>
import CoreFoundation
File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/PyObjC/CoreFoundation/__init__.py", line 21, in <module>
import CoreFoundation._CoreFoundation
RuntimeError: Wrong version of PyObjC C API
I tried to update pyobjc
and pyobjc-core
to 5.1.2 but it didn't help.
fileicon
explicitly targets the stock version of Python at /usr/bin/python
, which, as of macOS 10.14, is 2.7.10
.
Perhaps what you installed interferes with that? See also: https://stackoverflow.com/a/36823327/45375