#10933: Avoid " TypeError: Cannot convert Decimal("0.0000") to Decimal " when
the
decimal module has been reloaded
-------------------------------------+-------------------------------------
Reporter: gagravarr | Owner: nobody
Type: Bug | Status: new
Component: Database layer | Version: 1.3
(models, ORM) | Resolution:
Severity: Normal | Triage Stage: Accepted
Keywords: dceu2011 | Needs documentation: 0
Has patch: 1 | Patch needs improvement: 0
Needs tests: 1 | UI/UX: 0
Easy pickings: 0 |
-------------------------------------+-------------------------------------
Comment (by anonymous):
Replying to [comment:12 adrian.boczkowski@…]:
> This problem also occurs with Django 1.3 on Apache + mod_wsgi. I fix it
by changing (sorry, I can't make .diff file):
> {{{
> try:
> return decimal.Decimal(value)
> }}}
>
> to:
>
> {{{
> try:
> return decimal.Decimal(str(value))
> }}}
>
> I know it's rather ugly workaround than beautiful fix ;-), but it seems
to work fine.
Hi Adrian,
Just asking on where you applied this fix?
--
Ticket URL: <https://code.djangoproject.com/ticket/10933#comment:16>
Django <https://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.