[ python-Bugs-912943 ] 7.5.6 Thread Objects is too vague
SourceForge.net
noreply at sourceforge.net
Sun Jan 23 06:46:37 CET 2005
Bugs item #912943, was opened at 2004-03-10 06:16
Message generated for change (Comment added) made by alanvgreen
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=912943&group_id=5470
Category: Documentation
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Roy Smith (roysmith)
Assigned to: Nobody/Anonymous (nobody)
Summary: 7.5.6 Thread Objects is too vague
Initial Comment:
Some items which could be improved....
"Once the thread's activity is started, the thread is considered
'alive' and 'active' (these concepts are almost, but not quite
exactly, the same; their definition is intentionally somewhat
vague)."
This is a bit silly. Either these attributes are intended to be
exposed to users or they're not. If they are, they should be well
defined. If not, they shouldn't be mentioned at all.
"If the subclass overrides the constructor, it must make sure to
invoke the base class constructor (Thread.__init__()) before doing
anything else to the thread."
This is misleading. You need to call "Thread.__init__ (self)", i.e.
pass along the self argument. At least I think you do :-)
"join([timeout]) ... When the timeout argument is present and not
None, it should be a floating point number specifying a timeout for
the operation in seconds (or fractions thereof)."
What happens if you pass None? Does it wait forever? Is this any
different from not passing any argument at all? What happens if a
timeout occurs? Is there any way to differentiate between a
timeout and a normal return?
"A thread can be join()ed many times."
Presumably only if all but the last call timed out? Or maybe not?
If you get a normal return (i.e. not a timeout) from join(), and
then call join() again, what happens? Does it just return
immediately with no error?
----------------------------------------------------------------------
Comment By: Alan Green (alanvgreen)
Date: 2005-01-23 16:46
Message:
Logged In: YES
user_id=1174944
Submitted Patch 1107656 which addresses the 'alive' and
'active' issue. It does this by deprecating the isAlive()
method and adding an isActive method instead. The patch also
updates the documentation to talk about threads being
'active' rather than 'alive and active'.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=912943&group_id=5470
More information about the Python-bugs-list
mailing list