Marc-Andre Lemburg added the comment: STINNER Victor wrote: > > STINNER Victor added the comment: > >> The main reason for keeping the compatibility is that the module is >> also being used outside the stdlib for Python versions starting from >> 2.4 and later. I don't want to maintain two separate versions. > > Which projects use their own copy of platform.py? Where does this file come > from?
It's originally from the mxCGIPython project I ran a few years ago and which now lives on in form of the eGenix PyRun project. Since the main purpose of platform.py is to identify the underlying Python runtime and OS platform across multiple Python runtimes and OS platforms, it's meant to always be used in latest version, even against older Python versions. > Using subprocess sounds safer than adding a (theorical) TOCTTOU issue: > http://en.wikipedia.org/wiki/Time_of_check_to_time_of_use > > If you are concerned about compatibility with Python 2.4, you should maintain > platform outside the stdlib. The stdlib is regulary updated to the most > recent syntax/modules. For example, "yield from" is now used in the stdlib of > Python 3.4. The Python 2.4 compatibility requirement only applies to Python 2.x, not Python 3.x. Since Python 2.4 does ship with subprocess, I guess we could use subprocess even in Python 2.7, but I'm not sure whether it's a good idea to change the code in such a major way for a patch level release. -- Marc-Andre Lemburg eGenix.com Professional Python Services directly from the Source (#1, Oct 18 2012) >>> Python Projects, Consulting and Support ... http://www.egenix.com/ >>> mxODBC.Zope/Plone.Database.Adapter ... http://zope.egenix.com/ >>> mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/ ________________________________________________________________________ 2012-09-27: Released eGenix PyRun 1.1.0 ... http://egenix.com/go35 2012-09-26: Released mxODBC.Connect 2.0.1 ... http://egenix.com/go34 2012-09-25: Released mxODBC 3.2.1 ... http://egenix.com/go33 2012-10-23: Python Meeting Duesseldorf ... 5 days to go eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/ ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue16112> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com