filefield - Workaround Django error on model delete due to empty file field w/Thumbnailer -


i have model easythumbnailer file field, using boto storage , undelete, , instances of model have empty file field prevents me deleting them:

python/lib/python2.7/site-packages/django/db/models/fields/files.pyc in _require_file(self)      39     def _require_file(self):      40         if not self: ---> 41             raise valueerror("the '%s' attribute has no file associated it." % self.field.name)      42       43     def _get_file(self):  valueerror: 'image' attribute has no file associated it. 

i error when try delete within shell or website, , don't know how work around or remove whatever protection causing result in error.

i don't need clean solution, code base not long world, works.

model.delete(trash=false) 

turns out due interactions between "trashable" , empty file field, skips interactions.


Comments

Popular posts from this blog

user interface - Python attempting to create a simple gui, getting "AttributeError: 'MainMenu' object has no attribute 'intro_screen'" -

jquery - Common JavaScript snippet to share files on Google Drive, Dropbox, Box.net or SkyDrive -

Android Gson.fromJson error -