python / cpython

The Python programming language
https://www.python.org
Other
62.87k stars 30.12k forks source link

subprocess module docs contain an inconsistent mix of repeated versionchanged descriptions #101715

Open gpshead opened 1 year ago

gpshead commented 1 year ago

Documentation

The subprocess module documentation has an explosion of repeated text in versionchanged or versionadded markers splattered over multiple APIs within the docs.

The reality is that many of these are technically all directly Popen API changes, that the other higher level preferred more user friendly APIs like run() and call() and check_call() and check_output() all make use of internally and forward a majority of their arguments to.

Examples to look for: where are cwd, input, text, encoding, errors argument behavior changes/additions mentioned vs which APIs accept these.

I noticed this when looking over the changes made in https://github.com/python/cpython/issues/101283 where it became apparent to me that we're not internally consistent in how we do this within the doc today. The doc needs some cleanup and a strategy for this.

bzip2 commented 1 year ago

errors is not explained at all.

It might be helpful to have a table showing which combinations of arguments you can use together, and what they do.