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.

Author loewis
Recipients OPi, loewis, r.david.murray
Date 2014-02-23.22:50:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1393195854.59.0.44065875827.issue20731@psf.upfronthosting.co.za>
In-reply-to
Content
I can reproduce the problem. I started debugging it; the issue is that, after reading the two comment lines (and detecting the source encoding), fileio_readinto gets called, which calls read(), and read() returns 17 (bytes read), with are

"-\n\nprint('test')"

So for some reason, the - is not consumed yet, even though it was previously read out of the file descriptor.
History
Date User Action Args
2014-02-23 22:50:54loewissetrecipients: + loewis, r.david.murray, OPi
2014-02-23 22:50:54loewissetmessageid: <1393195854.59.0.44065875827.issue20731@psf.upfronthosting.co.za>
2014-02-23 22:50:54loewislinkissue20731 messages
2014-02-23 22:50:54loewiscreate