[Patches] [ python-Patches-514628 ] bug in pydoc on python 2.2 release
noreply@sourceforge.net
noreply@sourceforge.net
Fri, 01 Mar 2002 14:45:41 -0800
Patches item #514628, was opened at 2002-02-07 21:09
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=514628&group_id=5470
Category: Library (Lib)
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Raj Kunjithapadam (mmaster25)
>Assigned to: Tim Peters (tim_one)
Summary: bug in pydoc on python 2.2 release
Initial Comment:
pydoc has a bug when trying to generate html doc
more importantly it has bug in the method
writedoc()
attached is my fix.
Here is the diff between my fix and the regular dist
1338c1338
< def writedoc(thing, forceload=0):
---
> def writedoc(key, forceload=0):
1340,1346c1340,1343
< object = thing
< if type(thing) is type(''):
< try:
< object = locate(thing, forceload)
< except ErrorDuringImport, value:
< print value
< return
---
> try:
> object = locate(key, forceload)
> except ErrorDuringImport, value:
> print value
1351c1348
< file = open(thing.__name__ + '.html', 'w')
---
> file = open(key + '.html', 'w')
1354c1351
< print 'wrote', thing.__name__ + '.html'
---
> print 'wrote', key + '.html'
1356c1353
< print 'no Python documentation found for
%s' % repr(thing)
---
> print 'no Python documentation found for
%s' % repr(key)
----------------------------------------------------------------------
>Comment By: Guido van Rossum (gvanrossum)
Date: 2002-03-01 17:45
Message:
Logged In: YES
user_id=6380
assigned to Tim; this may be Ping's terrain but Ping is
typically not responsive.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=514628&group_id=5470