File objects? - under the hood question

Eric Pederson whereU at now.com
Fri Jan 21 00:06:31 EST 2005


Jeremy responds:


[kind enough not to mention I must have had only 10% of my brain cells functioning when I posted]

> And note that with the possible exception of that last one, there is no
> relationship between these two questions. 


Right, I just want there to be.


> There is no argument you can pass to file() that will read 
> an
> HTTP file.


A file is a file, no matter where it resides; yes I know it's not that simple.

Here the sort of thing (seek, then read) I think I want:

>>> IDV2=open(("http://musicsite.com/song453.mp3","rb")[:-128])

>>> song453.tags=IDV2.read()

>>> len(song453.tags)

128


But it's not a Python problem.  :-(


Thanks for the responses and indulgence.


I'm OK now - the repair man fixed the coffee pot.



Eric Pederson
http://www.songzilla.blogspot.com




More information about the Python-list mailing list