Re: [Pyobjc-dev] Problems documenting API using code introspection tools
Brought to you by:
ronaldoussoren
From: Ronald O. <ous...@ci...> - 2003-07-29 19:51:47
|
On Tuesday, 29 July, 2003, at 20:09, Dinu Gherman wrote: > Hi, > > when epydoc 2.0 was announced I immediately tried it on PyObjC, but > as it seems it always fails doing proper code introspection for some > parts of the code tree. I'm attaching a log of sample run below. > > I am pretty sure this is not a bug in epydoc and Edward Loper can't > do any debugging without having a Mac, I guess. I'm making a wild > estimate that there is too much magic going on in the __init__ files. > > Has anybody else succedeed in using a tool like epydoc (maybe pydoc) > on the PyObjC code base? I'm hunting a bug that affects pydoc, 'pydoc Foundation' crashes at the moment. Extracting documentation from the other modules seems to work fine. There is some more comment in the trace below. > > Thanks, > > Dinu > > PS: http://epydoc.sourceforge.net/ Thanks, I hadn't seen epydoc before. > > > [localhost:python2.2/site-packages/PyObjC] dinu% ll total 280 > drwxr-xr-x 13 dinu staff 442 Jul 29 19:57 Foundation/ [snip] > -rw-r--r-- 1 dinu staff 10843 Nov 22 2002 plistlib.py > [localhost:python2.2/site-packages/PyObjC] dinu% > [localhost:python2.2/site-packages/PyObjC] dinu% > [localhost:python2.2/site-packages/PyObjC] dinu% sudo epydoc --debug > --pdf Foundation/ > Password: > Importing 23 modules. > [.......................] > Building API documentation for 23 modules. > [.... > Warning: UID conflict detected: Foundation.NSStringFromClass > Warning: UID conflict detected: Foundation.NSSelectorFromString These are caused by unnecessary definitions, these functions are defined in python but there are also generated wrappers in Foundation._Foundation. I'll remove the unnecessary pure-python version. I get another message when running 'epydoc Foundation': Warning: __builtin__.type.__new__ appears to override itself epydoc __builtin__ gives the same warning (with some others). This is with Python 2.3 (b1) > ...Traceback (most recent call last): > File "/usr/bin/epydoc", line 8, in ? > cli() [snip] > File "/usr/lib/python2.2/site-packages/epydoc/uid.py", line 448, in > _findname > objname = obj.__name__ > AttributeError: No attribute __name__ I fixed this one over the weekend, objc.objc_class didn't have a __name__ attribute. Ronald |