Re: [Pyobjc-dev] ValueError: Unknown typestr
Brought to you by:
ronaldoussoren
From: Luc H. <lu...@ho...> - 2010-05-10 19:46:49
|
On 10 mai 2010, at 00:37, Luc Heinrich wrote: > Traceback (most recent call last): > File "/Users/luc/Desktop/Miro.app/Contents/Resources/__boot__.py", line 31, in <module> _run('Miro.py') > File "/Users/luc/Desktop/Miro.app/Contents/Resources/__boot__.py", line 28, in _runexecfile(path, globals(), globals()) > File "/Users/luc/Desktop/Miro.app/Contents/Resources/Miro.py", line 42, in <module> import Foundation > File "build/bdist.macosx-10.5-fat/egg/Foundation/__init__.py", line 10, in <module> > File "build/bdist.macosx-10.5-fat/egg/CoreFoundation/__init__.py", line 19, in <module> > File "objc/_bridgesupport.pyo", line 156, in initFrameworkWrapper > File "objc/_bridgesupport.pyo", line 58, in _parseBridgeSupport > ValueError: Don't know CF type for typestr '^{__CFAllocator=}', cannot create special wrapper I was able to make it all work. For the record my problem was, as Aahz said in his detailed report of the issue [1], related to py2app and not PyObjC itself. I did build everything from sources so I was expecting everything to work, but it didn't. The clue was in the stack trace, where you can see "normal" pathnames, like this one... > File "/Users/luc/Desktop/Miro.app/Contents/Resources/Miro.py", line 42, in <module> import Foundation ...and weird ones, like the four last ones: > File "build/bdist.macosx-10.5-fat/egg/Foundation/__init__.py", line 10, in <module> > File "build/bdist.macosx-10.5-fat/egg/CoreFoundation/__init__.py", line 19, in <module> > File "objc/_bridgesupport.pyo", line 156, in initFrameworkWrapper > File "objc/_bridgesupport.pyo", line 58, in _parseBridgeSupport The reason why it fails miserably is because py2app doesn't seem to know how to deal (or fail to deal correctly) with compressed Python eggs. The solution (at least for me :)) is to force PyObjC and any other library to be installed as non-compressed eggs. I personnally did it by patching all the setup.cfg files with an additional easy_install section, like this: [easy_install] zip_ok = 0 [1] http://sourceforge.net/mailarchive/message.php?msg_name=20100304190050.GA17310%40panix.com -- Luc Heinrich - lu...@ho... |