Message283213
The problem with Python2.7 is that 'open' does not take 'closefd', or any of the other parameters that were added for Python3.
open(name[, mode[, buffering]])
'rb' may make a difference on Py2 on Windows, but I haven't done any work in the environment in a long time.
I wasn't aware of that other issue. Some core Python developers have participated in that one. I suspect a lot of the discussion is beyond my level of expertise.
I once wrote that I thought 'FileType' was included primarily as an example of a 'type' factory. Something users could copy and extend for their own use. Bethard corrected me, saying that it was meant for quick-n-dirty script uses, ones with an input file, output file and a few options. In a bigger scripts, the users are encouraged to open/close files in 'with' contexts.
See http://bugs.python.org/issue22884 and the issues I reference there. |
|
Date |
User |
Action |
Args |
2016-12-14 19:10:41 | paul.j3 | set | recipients:
+ paul.j3, pitrou, bethard, eli.bendersky, anacrolix, moritz, markgrandi, josh.r, palaviv |
2016-12-14 19:10:41 | paul.j3 | set | messageid: <1481742641.86.0.211507266272.issue14156@psf.upfronthosting.co.za> |
2016-12-14 19:10:41 | paul.j3 | link | issue14156 messages |
2016-12-14 19:10:41 | paul.j3 | create | |
|