Opened 9 years ago

Closed 9 years ago

#6014 closed (fixed)

Decimal field raises UnicodeDecodeError if i18n characters are entered

Reported by: pigletto Owned by: nobody
Component: Forms Version: master
Severity: Keywords: decimal unicode unicodedecodeerror
Cc: pigletto@… Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

If user enters something like "23 zł" into decimal field it fails with UnicodeDecodeError.

This is caused by a call to str(value). Patch is attached.

Attachments (2)

decimal_v6709.patch (963 bytes) - added by pigletto 9 years ago.
decimal_v6710.patch (1.4 KB) - added by pigletto 9 years ago.
patch with tests against revision 6710

Download all attachments as: .zip

Change History (8)

Changed 9 years ago by pigletto

Attachment: decimal_v6709.patch added

comment:1 Changed 9 years ago by pigletto

Has patch: set
Needs documentation: unset
Needs tests: unset
Patch needs improvement: unset

comment:2 Changed 9 years ago by pigletto

Cc: pigletto@… added

comment:3 Changed 9 years ago by Chris Beaven

Needs tests: set
Triage Stage: UnreviewedAccepted

Changed 9 years ago by pigletto

Attachment: decimal_v6710.patch added

patch with tests against revision 6710

comment:4 Changed 9 years ago by pigletto

Needs tests: unset

comment:5 Changed 9 years ago by Chris Beaven

Triage Stage: AcceptedReady for checkin

comment:6 Changed 9 years ago by Malcolm Tredinnick

Resolution: fixed
Status: newclosed

(In [6746]) Fixed #6014 -- More robust error handling when validating decimal fields.
Thanks, pigletto.

Note: See TracTickets for help on using tickets.
Back to Top