[Pythonmac-SIG] py2app plugin problem: "Error loading code"

Niko Matsakis niko at alum.mit.edu
Sun Dec 10 22:19:15 CET 2006

As a follow up, I decided to see if the problem was related to my  
project in any way by followiing the tutorial at http:// 
pyobjc.sourceforge.net/doc/extending_objc_with_python.php.  I still  
get the same error, so it must be something in my machine.

I can't seem to find any kind of reference to what "error code 2"  
might mean....


On Dec 10, 2006, at 8:25 AM, Niko Matsakis wrote:

> All of a sudden, for reasons I completely fail to understand, py2app-
> created plug-ins will no longer load in my application.  I am not
> 100% sure if this is the right list for this kind of question: feel
> free to set me straight.
> The error I get is as follows:
> 2006-12-09 17:10:59.988 drachma[25673] *** -[NSBundle load]: Error
> loading code /Users/niko/hg/proj/drachma/src/build/Debug/drachma.app/
> Contents/Resources/PyPlugin.plugin/Contents/MacOS/PyPlugin for
> bundle /Users/niko/hg/proj/drachma/src/build/Debug/drachma.app/
> Contents/Resources/PyPlugin.plugin, error code 2 (link edit error
> code 0, error number 0 ())
> The only slightly strange thing I noticed is that when I use "file"
> on the content of the plugin I get:
> /Users/niko/hg/proj/drachma/src/build/Debug/drachma.app/Contents/
> Resources/PyPlugin.plugin/Contents/MacOS/PyPlugin: Mach-O bundle i386
> Which says "i386", but this is running on a PPC.  I tried to use the
> "--prefer-ppc" option, but I get the same result either way.
> Any ideas on what's wrong, or where to find more information?  It
> doesn't seem to matter whether I use -A mode or not.
> I am using a version of Python 2.4 from DarwinPorts; PyObjC was
> installed the same way.
> What's very odd is that all of this USED to work --- I had to do a
> bit of a hack to make the -A mode work, introducing a .pth file into
> ~/Library/Python/2.4/site-packages, but now nothing works, whether or
> not I add or remove that file.  The only thing I can think of that I
> did  in between is to attempt to build a "Release" version of the
> program instead of a "Debug" version, but now neither Release nor
> Debug works.
> thanks in advance for any clues,
> Niko
> _______________________________________________
> Pythonmac-SIG maillist  -  Pythonmac-SIG at python.org
> http://mail.python.org/mailman/listinfo/pythonmac-sig

More information about the Pythonmac-SIG mailing list