classification
Title: subprocess.Popen.poll/__del__ API breakage
Type: resource usage Stage:
Components: Library (Lib) Versions: Python 2.6, Python 2.5
process
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: gregory.p.smith Nosy List: amaury.forgeotdarc, gregory.p.smith, rene.st
Priority: normal Keywords: patch

Created on 2008-01-17 11:29 by rene.st, last changed 2008-08-04 00:16 by gregory.p.smith. This issue is now closed.

Files
File name Uploaded Description Edit
subprocessapi.py rene.st, 2008-01-17 11:29 Very simple test program
subprocess_poll.patch amaury.forgeotdarc, 2008-01-17 21:15
Messages (4)
msg60024 - (view) Author: René Stadler (rene.st) Date: 2008-01-17 11:29
The commit to r45234 has added an internally used keyword attribute
named _deadstate to subprocess.Popen.poll, which is called by the
__del__ method of this class.  If you derived your own class from
subprocess.Popen that overrides .poll() without taking kwargs, the
__del__ method will trigger a TypeError about the unexpected keyword
argument.

Attached is a very simple test program that triggers the problem.  It
runs just fine with Python 2.4 however.
msg60061 - (view) Author: Amaury Forgeot d'Arc (amaury.forgeotdarc) * (Python committer) Date: 2008-01-17 21:15
Does the attached patch correct your problem?
msg60098 - (view) Author: René Stadler (rene.st) Date: 2008-01-18 16:03
Yes, it works.
msg70670 - (view) Author: Gregory P. Smith (gregory.p.smith) * (Python committer) Date: 2008-08-04 00:16
Fixed in trunk r65459.  release25-maint r65460.
History
Date User Action Args
2008-08-04 00:16:16gregory.p.smithsetstatus: open -> closed
resolution: accepted
messages: + msg70670
2008-07-07 20:43:40gregory.p.smithsetkeywords: + patch
assignee: gregory.p.smith
nosy: + gregory.p.smith
2008-01-18 16:03:58rene.stsetmessages: + msg60098
2008-01-17 21:15:32amaury.forgeotdarcsetfiles: + subprocess_poll.patch
nosy: + amaury.forgeotdarc
messages: + msg60061
2008-01-17 20:56:45christian.heimessetpriority: normal
type: resource usage
2008-01-17 11:29:58rene.stcreate