I've become unable to use the get_IMAGEFIELD_dimensions() set of  
methods on images recently: using pic.get_picFile_width() (where  
picFile is my model's ImageField) returns this traceback:

   File "/Library/Python/2.5/site-packages/django/utils/ 
functional.py", line 55, in _curried
     return _curried_func(*(args+moreargs), **dict(kwargs,  
**morekwargs))
   File "/Library/Python/2.5/site-packages/django/db/models/base.py",  
line 429, in _get_FIELD_width
     return self._get_image_dimensions(field)[0]
   File "/Library/Python/2.5/site-packages/django/db/models/base.py",  
line 439, in _get_image_dimensions
     setattr(self, cachename, get_image_dimensions(filename))
   File "/Library/Python/2.5/site-packages/django/utils/images.py",  
line 12, in get_image_dimensions
     fp = open(path, 'rb')
IOError: [Errno 2] No such file or directory: u'/Library/WebServer/ 
Documents/BJbyfoot/media/http://localhost/BJbyfoot/media/img/pics/02/07/IMG_0697.JPG'


Apparently PIL's ImageFile module is being fed MEDIA_ROOT +  
pic.get_picFile_url() as the location of the image file to open. I can  
see that _get_FIELD_filename() joins MEDIA_ROOT with something, but  
that's as far as I understand it.

I haven't touched this bit of the code for a while. I recently updated  
to r7196, but I couldn't immediately see anything in the revision that  
might have messed with this issue.

Hope someone can help...

ERic

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to