This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2011年11月21日 15:18 by Ronny.Pfannschmidt, last changed 2022年04月11日 14:57 by admin. This issue is now closed.
| Messages (5) | |||
|---|---|---|---|
| msg148055 - (view) | Author: Ronny Pfannschmidt (Ronny.Pfannschmidt) | Date: 2011年11月21日 15:18 | |
not sure if this is to be considered a bug, but python3.2 tries to flush sys.stdout on shutdown, even if its closed $ python3.2 -c 'import sys;sys.stdout.close()' Exception ValueError: 'I/O operation on closed file.' in <_io.TextIOWrapper name='<stdout>' mode='w' encoding='ANSI_X3.4-1968'> ignored its related to how Issue #5319 was fixed |
|||
| msg148155 - (view) | Author: Antoine Pitrou (pitrou) * (Python committer) | Date: 2011年11月22日 23:46 | |
I think closing stdout is a legitimate desire so, yes, I would consider it a bug if we print an error in that case. A patch could either first check the "closed" attribute, or silence the ValueError. |
|||
| msg148198 - (view) | Author: Ronny Pfannschmidt (Ronny.Pfannschmidt) | Date: 2011年11月23日 18:04 | |
i think checking for closed is the correct solution |
|||
| msg148422 - (view) | Author: Roundup Robot (python-dev) (Python triager) | Date: 2011年11月26日 21:11 | |
New changeset 150e096095e5 by Antoine Pitrou in branch '3.2': Issue #13444: When stdout has been closed explicitly, we should not attempt to flush it at shutdown and print an error. http://hg.python.org/cpython/rev/150e096095e5 New changeset 37300a1df7d7 by Antoine Pitrou in branch 'default': Issue #13444: When stdout has been closed explicitly, we should not attempt to flush it at shutdown and print an error. http://hg.python.org/cpython/rev/37300a1df7d7 |
|||
| msg231062 - (view) | Author: Martin Panter (martin.panter) * (Python committer) | Date: 2014年11月12日 05:23 | |
Shouldn’t this issue be marked closed and fixed? |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:24 | admin | set | github: 57653 |
| 2014年11月12日 05:49:16 | berker.peksag | set | status: open -> closed resolution: fixed stage: needs patch -> resolved |
| 2014年11月12日 05:23:35 | martin.panter | set | nosy:
+ martin.panter messages: + msg231062 |
| 2014年11月11日 16:13:28 | jleedev | set | nosy:
+ jleedev |
| 2011年11月27日 00:29:50 | Arfrever | set | nosy:
+ Arfrever |
| 2011年11月26日 21:11:58 | python-dev | set | nosy:
+ python-dev messages: + msg148422 |
| 2011年11月23日 18:04:41 | Ronny.Pfannschmidt | set | messages: + msg148198 |
| 2011年11月22日 23:46:55 | pitrou | set | type: behavior stage: needs patch messages: + msg148155 versions: + Python 3.3 |
| 2011年11月21日 15:18:19 | Ronny.Pfannschmidt | create | |