[issue16125] open accepts arbitrary mode strings as long as they contain U

2020-05-31 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Python 2.7 is no longer supported. -- nosy: +serhiy.storchaka resolution: -> out of date stage: needs patch -> resolved status: open -> closed ___ Python tracker

[issue16125] open accepts arbitrary mode strings as long as they contain U

2015-04-17 Thread Arfrever Frehtes Taifersar Arahesis
Arfrever Frehtes Taifersar Arahesis added the comment: Still reproducible with Python 2.7.10rc0 on GNU/Linux: >>> open('/tmp/a', 'az') >>> open('/tmp/a', 'rz') >>> open('/tmp/a', 'wz') >>> open('/tmp/a', 'zU') -- ___ Python tracker

[issue16125] open accepts arbitrary mode strings as long as they contain U

2015-04-13 Thread Wolfgang Maier
Wolfgang Maier added the comment: I'm able to reproduce this with Python 2.7.6 on Linux, but not 2.7.9 on Windows. Is this a POSIX-only bug or has it been fixed in the meantime ? -- nosy: +wolma ___ Python tracker

[issue16125] open accepts arbitrary mode strings as long as they contain U

2015-04-13 Thread Nick Coghlan
Nick Coghlan added the comment: +1 for a Py3k warning. Filing a pylint --py3k RFE may also be appropriate. -- nosy: +ncoghlan ___ Python tracker ___ _

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-09 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis : -- nosy: +Arfrever ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-09 Thread R. David Murray
R. David Murray added the comment: I think we'd probably better find out if there is support for applying it before you go to the trouble of writing it. It might be appropriate as a -3 warning, since the behavior changes in python3. I would be +1 for applying it as a -3 warning, and -0 as a

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-09 Thread Kushal Das
Kushal Das added the comment: So, should I submit a new patch which will just put a warning ? -- ___ Python tracker ___ ___ Python-bug

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-04 Thread R. David Murray
R. David Murray added the comment: Unfortunately, this is a backward compatibility concern (currently working-even-if-buggy code could stop working), so I'm -1 on fixing it. Option [2] would be an enhancement/API change, and is thus also ruled out. A third alternative might be to add a warn

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-04 Thread Kushal Das
Kushal Das added the comment: Patch to update mode parsing of open call. All tests seem to be running ok. File changed: Objects/fileobject.c -- keywords: +patch Added file: http://bugs.python.org/file27411/open_mode2.patch ___ Python tracker

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-04 Thread Kushal Das
Kushal Das added the comment: I am working on patch for this. -- nosy: +kushaldas ___ Python tracker ___ ___ Python-bugs-list mailing

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-03 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti, pitrou stage: -> needs patch versions: -Python 2.6 ___ Python tracker ___ ___ Pyth

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-03 Thread Robert Xiao
Changes by Robert Xiao : -- type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue16125] open accepts arbitrary mode strings as long as they contain U

2012-10-03 Thread Robert Xiao
New submission from Robert Xiao: This issue affects Python 2.5 through 2.7, but not Python 3. open accepts basically anything for the second argument, so long as it either starts with r, w, or a, or contains U somewhere in the string. Therefore, the following are all legal in Python 2.7.3: >>