Message265812
Since this issue was first filed, the "opener" parameter was added to the open() builtin: https://docs.python.org/3/library/functions.html#open
I mention that, as the problem there is similar to the problem here: wanting to construct a buffered text-mode interface, but with a different stream at the lowest layer (whatever "opener" returns for the builtin open(), the implicitly created pipes for the subprocess module).
To answer Martin's question about "Why not just wrap things manually?", the main issue with that is that it doesn't work for the check_output helper function - to get text out of that, currently your only option is to enable universal newlines and trust that the output is encoded as UTF-8 (which is fortunately often a valid assumption on modern systems). |
|
Date |
User |
Action |
Args |
2016-05-18 06:08:56 | ncoghlan | set | recipients:
+ ncoghlan, amaury.forgeotdarc, pitrou, vstinner, mark, eric.araujo, segfaulthunter, Arfrever, r.david.murray, srid, mightyiam, chris.jerdonek, martin.panter, berwin22 |
2016-05-18 06:08:56 | ncoghlan | set | messageid: <1463551736.76.0.456870656666.issue6135@psf.upfronthosting.co.za> |
2016-05-18 06:08:56 | ncoghlan | link | issue6135 messages |
2016-05-18 06:08:56 | ncoghlan | create | |
|