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 sdaoden
Recipients r.david.murray, sdaoden
Date 2011-03-28.12:30:19
SpamBayes Score 1.255945e-06
Marked as misclassified No
Message-id <1301315420.28.0.123524956156.issue11701@psf.upfronthosting.co.za>
In-reply-to
Content
... and that closes the original file, too!
(I've also opened #11700 due to the mailbox.py
side of this.)


static PyObject *
textiowrapper_close(textio *self, PyObject *args)
        return PyObject_CallMethod(self->buffer, "close", NULL);


>>> mb = mailbox.Maildir('sdaoden', create=False)
>>> mbf = mb.get_file(mb.keys()[0])
>>> msg = email.parser.BytesParser().parse(mbf, headersonly=True)
>>> mbf.close()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/steffen/usr/opt/py3k/lib/python3.3/mailbox.py", line 1922, in close
    if hasattr(self._file, 'close'):
AttributeError: '_ProxyFile' object has no attribute '_file'
History
Date User Action Args
2011-03-28 12:30:20sdaodensetrecipients: + sdaoden, r.david.murray
2011-03-28 12:30:20sdaodensetmessageid: <1301315420.28.0.123524956156.issue11701@psf.upfronthosting.co.za>
2011-03-28 12:30:19sdaodenlinkissue11701 messages
2011-03-28 12:30:19sdaodencreate