[ python-Bugs-848907 ] pydoc crash on MacOS X

SourceForge.net noreply at sourceforge.net
Tue Nov 25 07:51:49 EST 2003


Bugs item #848907, was opened at 2003-11-25 13:50
Message generated for change (Settings changed) made by ronaldoussoren
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=848907&group_id=5470

>Category: Macintosh
>Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Ronald Oussoren (ronaldoussoren)
>Assigned to: Jack Jansen (jackjansen)
Summary: pydoc crash on MacOS X

Initial Comment:
pydoc will crash the python interpreter on MacOS X if an 
extension module defines an Objective-C class or category.

The attached tarball contains an example of this, if you build 
the extension module and then run dotest.py the interpreter 
will crash.

The cause for this is the call to 'imp.load_module' in 
pydoc.py. This will load the extension module with __temp__ 
as it's name. load_module will load the executable image, 
search for the init__temp__ function and will then try to 
unload the image because that function is not found. 
Unloading the image (using NSUnloadModule, see 
dynload_next.c) will cause the crash because it is impossible 
to unload executable images that contain an Objective-C 
class or category.

A real world example: install PyObjC and run 'pydoc -k 
hello'.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=848907&group_id=5470



More information about the Python-bugs-list mailing list