Wanted: a python24 package for Python 2.3

Jonathan Fine jfine at pytex.org
Wed Mar 21 12:19:58 CET 2007

Gerald Klix wrote:
> Hi,
> You can't import subproces from future, only syntactic and semantic 
> changes that will become standard feature in future python version can 
> be activated that way.
> You can copy the subprocess module from python 2.4 somewhere where it 
> will be found from python 2.3. At least subporcess is importable after 
> that:
> --- snip ---
> klix at vesuv6:~/ttt> cp -av /usr/local/lib/python2.4/subprocess.py .
> »/usr/local/lib/python2.4/subprocess.py« -> »./subprocess.py«
> klix at vesuv6:~/ttt> python2.3
> Python 2.3.3 (#1, Jun 29 2004, 14:43:40)
> [GCC 3.3 20030226 (prerelease) (SuSE Linux)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
>  >>> import subprocess
>  >>>

You're quite right about the use of __future__.  I decided to
put subprocess in a package, so that my system can choose
which one to find, whether running Python 2.3 or 2.4.

(Well, in 2.3 there's no choice, but in 2.4 I don't want
the "just for 2.3" module to hide the real 2.4 module.)

The responses I've had indicate that my approach might
be a good idea, and might be useful to others.  For me,
that's enough for now.


More information about the Python-list mailing list