Export to GitHub

django-photologue - issue #71

Unicode error while trying to remove image


Posted on Sep 22, 2008 by Quick Cat

What steps will reproduce the problem? 1. Create a image who's title contains any unicode-character (åäö etc) 2. Try to remove it... 3. ...and it returns with a UnicodeEncodeError

What is the expected output? What do you see instead?

http://dpaste.com/hold/79836/

What version of the product are you using? On what operating system?

Django 1.0 final, using the development server on OS X 10.5.

Comment #1

Posted on Sep 23, 2008 by Happy Giraffe

From what I can see it looks like your running into collisions with an old pre-unicode version. From you traceback I can see the code doesn’t match. See here:

http://code.djangoproject.com/browser/django/trunk/django/contrib/admin/options.py

Line 683:

obj_display = force_unicode(obj)

Not:

obj_display = str(object)

...like your dpaste at line 40 (692).

You probably need to remove the the version of django from "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/django/", which looks like it was installed using MacPorts and reinstall Django 1.0. You also might want to look into running Django in a virtualenv as it makes these collisions less likely.

Status: Invalid

Labels:
Type-Defect Priority-Medium