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 kyle.roberts
Recipients kyle.roberts, ncoghlan, pitrou, r.david.murray
Date 2013-04-29.15:11:27
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1367248288.34.0.731919592439.issue17673@psf.upfronthosting.co.za>
In-reply-to
Content
Thanks for the comments Antoine. I didn't have a good reason for using the file name at the time, although even when using the file name I should have used the "file" variable that was already created. I tried using the file descriptor, but I encountered a "[Errno 9] Bad file descriptor" once the methods using _mkstemp_inner call _io.open on the returned fd. This leads me to believe that the fd is being closed somehow, but as you can see from my copy function, I don't implicitly or explicitly close the file using the file descriptor. I'm not sure yet why the file name works as expected but the fd does not. Am I missing something simple?

As for points 2-4 I have most of that done. What's the pythonic way for determining if an argument is file-like? I've seen isinstance, hasattr, etc.
History
Date User Action Args
2013-04-29 15:11:28kyle.robertssetrecipients: + kyle.roberts, ncoghlan, pitrou, r.david.murray
2013-04-29 15:11:28kyle.robertssetmessageid: <1367248288.34.0.731919592439.issue17673@psf.upfronthosting.co.za>
2013-04-29 15:11:28kyle.robertslinkissue17673 messages
2013-04-29 15:11:27kyle.robertscreate