[Python-Dev] deprecate commands.getstatus()

Titus Brown titus at caltech.edu
Fri Mar 23 18:37:56 CET 2007


On Fri, Mar 23, 2007 at 10:30:37AM -0600, Steven Bethard wrote:
-> On 3/23/07, Hrvoje Nik??i?? <hrvoje.niksic at avl.com> wrote:
-> > On Thu, 2007-03-22 at 13:38 -0700, Guido van Rossum wrote:
-> > > Sounds good to me. In 3.0 we should probably not have os.popen*(), nor
-> > > the popen2 module at all, and do everything via the subprocess module.
-> > > I wonder if we should even get rid of os.system(); then there should
-> > > be a subprocess.system() instead. And do we even need os.fork(),
-> > > os.exec*(), os.spawn*()?
-> >
-> > Please don't remove os.fork and os.exec*.  Some people need to fine-tune
-> > process creation and don't need portability to non-Unix OS'es.  For
-> > them, the functions that call the underlying system API and little or
-> > nothing else are a god-send.
-> 
-> Right, but if you're really using only Posix, you can simply use
-> ``posix.fork`` and ``posix.exec*`` and then you're even being explicit
-> about the fact.

Yes, but:

http://docs.python.org/lib/module-posix.html

	"""Do not import this module directly."""

Unless people want me to try to extract something coherent from the
recent discussion, I'm going to avoid doing anything with os.*
functions.  That can be done separately from the contemplated subprocess
patch, anyway.

The whole thread is here:

	http://www.gossamer-threads.com/lists/engine?post=553519;list=python

and I will finish up a patch to do this:

	http://www.gossamer-threads.com/lists/python/dev/555743#555743

(add get_*output* functions to subprocess, modify docs appropriately,
add 'require_success', and put in a docs deprecation for
popen2/commands).

I'll post again when I have a patch ready so there's something concrete
to complain about ;).

thanks,
--titus


More information about the Python-Dev mailing list