image from URL

Walter Dörwald walter at livinglogic.de
Thu Oct 11 08:16:58 EDT 2001


Oleg Broytmann wrote:

> On Thu, Oct 11, 2001 at 06:01:48AM -0500, Randy Heiland wrote:
> 
>>    fp = __builtin__.open(fp, "rb")
>>TypeError: open() argument 1 must be (encoded string without NULL bytes), not
>>str
>>
> 
>    Please continue to answer to newsgroup.
> 
>    So you have a minor problem - Image expects filename. So, save fp.read()
> to a file, and pass its filename to Image.


or use urllib.urlretrieve instead of urllib.urlopen

Bye,
    Walter Dörwald





More information about the Python-list mailing list