#11819: Should __unicode__ be used when returning purely numerical values?
------------------------------------+---------------------------------------
Reporter: sampablokuper | Owner: nobody
Status: closed | Milestone:
Component: Documentation | Version: 1.1
Resolution: invalid | Keywords:
Stage: Unreviewed | Has_patch: 0
Needs_docs: 0 | Needs_tests: 0
Needs_better_patch: 0 |
------------------------------------+---------------------------------------
Changes (by mrts):
* status: new => closed
* resolution: => invalid
Comment:
There's nothing Django-specific in `__unicode__` and it's sufficiently
documented (answering your question among other things) in general
[http://docs.python.org/reference/datamodel.html#object.__unicode__ Python
docs]:
''Called to implement unicode() builtin; should return a Unicode object.
When this method is not defined, string conversion is attempted, and the
result of string conversion is converted to Unicode using the system
default encoding.''
--
Ticket URL: <http://code.djangoproject.com/ticket/11819#comment:2>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---