_cpcompat_subprocess on windows not fully backwards compatible
*Apologies in advance for a bug report heavy on narrative and light on code. I don't have access to windows, so I can't replicate a problem reported in my project, so I've traced it by reading through code and commit logs.
4aae6961428888611471f3891481ed760e1210be copied in Python 2.7.3
subprocess.py. This seems to work well for most situations except on the windows platform with older versions of Python. On windows,
subprocess.py imports the
_subprocess C module and then imports symbols from it. Some of those symbols (notably
CREATE_NEW_PROCESS_GROUP) are only present in newer
_subprocess so on older Python versions on windows the import will fail.
As far as I can tell this commit from April 2010 introduced the symbol for the first time.
Including the C module in CherryPy is onerous so either the promised compatibility back to much older versions (on windows) is void or some modification is needed.
As far as I can tell
CREATE_NEW_PROCESS_GROUP is not used in cherrypy itself so perhaps just hork that out from lines 449 and 454?
The same issue may be present with CREATE_NEW_CONSOLE.