[issue1706039] Added clearerr() to clear EOF state

2020-05-31 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> out of date stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue1706039] Added clearerr() to clear EOF state

2011-03-11 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: On Wed, Mar 9, 2011 at 2:32 AM, Scott Dial wrote: .. > By rejecting unittests on the merits of its coding style, you are creating a > double-standard for people like > me (outside of the core committers), which eventually wears out my interest > in help

[issue1706039] Added clearerr() to clear EOF state

2011-03-09 Thread Scott Dial
Scott Dial added the comment: I'm well aware of the limited use of Py_UniversalNewlineFgets() in py3k, but it remains the case that it is a public API that fails to work correctly under the conditions specified by the reporter, and Alexander confirmed the original patch fixed the issue. AFAIC

[issue1706039] Added clearerr() to clear EOF state

2011-03-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: I'm afraid there's a misunderstanding here about the scope of the issue. fileobject.c is not really used in py3k (except for a couple very specific uses such as the tokenizer or the import machinery). The standard I/O stack uses object in the _io module (that

[issue1706039] Added clearerr() to clear EOF state

2011-03-08 Thread Scott Dial
Scott Dial added the comment: I've updated the patch to apply to the current tip. (This patch was an opportunity for me to update to an Hg workflow.) Alexander, I disagree with you about the tests. The unittests use the exact same pattern/model that testIteration uses. I find your complaint t

[issue1706039] Added clearerr() to clear EOF state

2010-12-08 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: The tests need to be cleaned up a little. The setup code should go to setUp() method and instead of calling different methods in a loop with a switch over method names, it should just have a separate test_ method for each method tested. A "with" state

[issue1706039] Added clearerr() to clear EOF state

2010-11-30 Thread Scott Dial
Scott Dial added the comment: The patch includes unittests; the issue is that the tests pass without the changes. That is an entirely different state to be in. The tests should be committed unless somebody wants to object to the behavior that they are testing (although I believe this behavior

[issue1706039] Added clearerr() to clear EOF state

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: I don't know how to reproduce the issue and without unit tests this patch cannot be committed. -- assignee: belopolsky -> ___ Python tracker

[issue1706039] Added clearerr() to clear EOF state

2010-07-24 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: The patch passes tests on OSX, but the old code passes the new tests as well, so I am not sure what this patch fixes anymore. Looking back through the messages I see that I had trouble reproducing the problem, then I succeeded, but I don't remember the

[issue1706039] Added clearerr() to clear EOF state

2010-07-24 Thread Mark Lawrence
Mark Lawrence added the comment: Could somebody with an OS X system please try out the py3k patch, thanks. -- ___ Python tracker ___ __

[issue1706039] Added clearerr() to clear EOF state

2010-07-17 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- assignee: -> belopolsky resolution: -> accepted stage: patch review -> commit review ___ Python tracker ___ _

[issue1706039] Added clearerr() to clear EOF state

2010-07-17 Thread Mark Lawrence
Mark Lawrence added the comment: The patch adds one line and moves one line in fileobject.c. The rest of the patch is new tests. I've successfully applied the patch on Windows and the tests were fine. Can someone kindly repeat the tests on OS X as this is where the problem was originally r

[issue1706039] Added clearerr() to clear EOF state

2009-12-10 Thread Scott Dial
Changes by Scott Dial : Removed file: http://bugs.python.org/file15516/issue1706039-py3k.patch ___ Python tracker ___ ___ Python-bugs-list m

[issue1706039] Added clearerr() to clear EOF state

2009-12-10 Thread Scott Dial
Changes by Scott Dial : Added file: http://bugs.python.org/file15517/issue1706039-py3k.patch ___ Python tracker ___ ___ Python-bugs-list mai

[issue1706039] Added clearerr() to clear EOF state

2009-12-10 Thread Scott Dial
Scott Dial added the comment: I've attached a patch that applies cleanly against py3k. I do not have an in-depth understanding of the new io module, but at a cursory glance, it seems to not use FILE streams, and would not be subject to this bug. However, Py_UniversalNewlineFgets() still remains

[issue1706039] Added clearerr() to clear EOF state

2009-05-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: Does it apply to 3.1? -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: h

[issue1706039] Added clearerr() to clear EOF state

2009-05-14 Thread Daniel Diniz
Changes by Daniel Diniz : -- components: +IO nosy: +benjamin.peterson, pitrou priority: -> normal stage: -> patch review versions: +Python 3.1 -Python 3.0 ___ Python tracker

[issue1706039] Added clearerr() to clear EOF state

2008-12-23 Thread Scott Dial
Scott Dial added the comment: They differ because in Py_UniversalNewlineFgets() there is a call to FLOCKFILE(), and it seemed appropriate to ensure that clearerr() was called after locking the FILE stream. I certainly pondered over whether it made a difference to do it before or after, and it wo

[issue1706039] Added clearerr() to clear EOF state

2008-12-23 Thread John Smith
John Smith added the comment: Sorry for inconvenience caused with the patch. I should've got more reviews before asking it checked in. I verified eof2.diff-applied-python gets "Bus error" and Scott Dial's fileobject.diff fixes this. (Test was on 9.6.0 Darwin Kernel Version 9.6.0) _

[issue1706039] Added clearerr() to clear EOF state

2008-12-23 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Maybe not a problem, but an inconsistency: in Py_UniversalNewlineFgets clearerr is added inside univ_newline conditional and then again before the loop over characters, but in Py_UniversalNewlineFread it is added only once before "if (!f->f_univ_newline

[issue1706039] Added clearerr() to clear EOF state

2008-12-23 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: I've combined Scott's patch with John's (?) test case in issue1706039.diff. Confirmed that the patch fixes the issue on Mac OS X 10.5.6 (Intel). Added file: http://bugs.python.org/file12434/issue1706039.diff ___ Pyt

[issue1706039] Added clearerr() to clear EOF state

2008-12-23 Thread Martin v. Löwis
Martin v. Löwis added the comment: I have now reverted the patch in r67914. I won't reject the patch because of Scott's alternative, but leave it open for review. Since Scott's patch is not approved yet, this is not a release blocker anymore. -- assignee: loewis -> priority: release bl

[issue1706039] Added clearerr() to clear EOF state

2008-12-22 Thread Scott Dial
Scott Dial added the comment: I believe the original patch is overreaching. I believe the changes to fileobject.c should've been much simpler, just as the title describes (adding clearerr() just before performing reads on the FILE handles). I've attached a much simpler patch that I believe corr

[issue1706039] Added clearerr() to clear EOF state

2008-12-21 Thread Guilherme Polo
Guilherme Polo added the comment: On Sun, Dec 21, 2008 at 9:52 PM, Martin v. Löwis wrote: > > Martin v. Löwis added the comment: > >> It isn't being careful when calling PyErr_SetFromErrno inside the >> Py_UniversalNewlineFread function since this function is being called >> all over fileobjec

[issue1706039] Added clearerr() to clear EOF state

2008-12-21 Thread Martin v. Löwis
Martin v. Löwis added the comment: > It isn't being careful when calling PyErr_SetFromErrno inside the > Py_UniversalNewlineFread function since this function is being called > all over fileobject after releasing the GIL.. so, isn't this just a > matter of adding pairs of PyGILState_Ensure/PyGIL

[issue1706039] Added clearerr() to clear EOF state

2008-12-21 Thread Guilherme Polo
Guilherme Polo added the comment: It isn't being careful when calling PyErr_SetFromErrno inside the Py_UniversalNewlineFread function since this function is being called all over fileobject after releasing the GIL.. so, isn't this just a matter of adding pairs of PyGILState_Ensure/PyGILState_Rel

[issue1706039] Added clearerr() to clear EOF state

2008-12-21 Thread Martin v. Löwis
Martin v. Löwis added the comment: Unfortunately, the patch is broken. The program fname='test123' f=open(fname,'w') f.read() crashes with the patch applied. I think I will revert the patch in 2.5.3, release 2.5.4, and reject the patch. ___ Python tracker

[issue1706039] Added clearerr() to clear EOF state

2008-12-20 Thread Martin v. Löwis
Changes by Martin v. Löwis : -- versions: -Python 2.5.3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http

[issue1706039] Added clearerr() to clear EOF state

2008-12-19 Thread Martin v. Löwis
Changes by Martin v. Löwis : -- priority: deferred blocker -> release blocker ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue1706039] Added clearerr() to clear EOF state

2008-12-13 Thread Martin v. Löwis
Martin v. Löwis added the comment: Thanks for the patch. Committed into the 2.5 branch as r67740. This still needs to be applied to the other branches. -- priority: release blocker -> deferred blocker ___ Python tracker

[issue1706039] Added clearerr() to clear EOF state

2008-12-10 Thread Martin v. Löwis
Changes by Martin v. Löwis <[EMAIL PROTECTED]>: -- priority: normal -> release blocker ___ Python tracker <[EMAIL PROTECTED]> ___ ___

[issue1706039] Added clearerr() to clear EOF state

2008-11-29 Thread John Smith
John Smith <[EMAIL PROTECTED]> added the comment: Hi, when will this patch be checkedin? -- versions: +Python 2.5.3, Python 2.6, Python 3.0 ___ Python tracker <[EMAIL PROTECTED]> __

[issue1706039] Added clearerr() to clear EOF state

2008-01-21 Thread Raghuram Devarakonda
Changes by Raghuram Devarakonda: -- nosy: -draghuram _ Tracker <[EMAIL PROTECTED]> _ ___ Python-bugs-list mailing list Unsubscribe:

[issue1706039] Added clearerr() to clear EOF state

2007-12-04 Thread John Smith
John Smith added the comment: What's in a name? :p Done, anyway. _ Tracker <[EMAIL PROTECTED]> _ ___ Python-bugs-list mailing list Unsubscrib

[issue1706039] Added clearerr() to clear EOF state

2007-12-04 Thread Martin v. Löwis
Martin v. Löwis added the comment: jos, can you please provide a real name in "Your Details" of this tracker? We cannot accept anonymous/pseudonymous patches. _ Tracker <[EMAIL PROTECTED]> _

[issue1706039] Added clearerr() to clear EOF state

2007-12-03 Thread Martin v. Löwis
Martin v. Löwis added the comment: Yes, a number of items were not moved, as SF failed to provide them on export. -- nosy: +loewis _ Tracker <[EMAIL PROTECTED]> _ __

[issue1706039] Added clearerr() to clear EOF state

2007-12-03 Thread Raghuram Devarakonda
Raghuram Devarakonda added the comment: I get an error when I try to read 1523853. Is this not moved to the new tracker or others are able to access it? -- nosy: +draghuram _ Tracker <[EMAIL PROTECTED]> __

[issue1706039] Added clearerr() to clear EOF state

2007-12-01 Thread jos
jos added the comment: Any chance to get this fix commmited in? -- type: -> behavior _ Tracker <[EMAIL PROTECTED]> _ ___ Python-bugs

[issue1706039] Added clearerr() to clear EOF state

2007-08-24 Thread Georg Brandl
Changes by Georg Brandl: -- assignee: -> loewis _ Tracker <[EMAIL PROTECTED]> _ ___ Python-bugs-list mailing list Unsubscribe: htt