New submission from Gregory P. Smith <g...@krypto.org>: We started down this path in https://bugs.python.org/issue31961 but had to revert part of that before 3.7 as the implementation was incomplete making it inconsistent across platforms. https://github.com/python/cpython/pull/4329.
Specifically accepting PathLike objects within the args list hasn't been ruled out... There is at least one question about behavior though, is str() called when running on posix systems or bytes() (bytes uses fsencode)? Or does what gets called depend on the specific sub-type of the path vs the current platform? Example scenario: if you're processing a PureWindowsPath on a posix system and passing that to a child process, sending that through os.fsencode would presumably be the wrong choice... ---------- messages: 355890 nosy: gregory.p.smith priority: normal severity: normal stage: needs patch status: open title: can we accept os.PathLike objects within the subprocess args= list? type: enhancement versions: Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue38670> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com