Bug 865033
Summary: | Non ascii characters cause traceback when setting into the TestCase.notes | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Lukáš Zachar <lzachar> | ||||
Component: | python-nitrate | Assignee: | Petr Šplíchal <psplicha> | ||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | unspecified | Docs Contact: | |||||
Priority: | unspecified | ||||||
Version: | rawhide | CC: | ohudlick, psplicha | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2013-01-07 18:53:06 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Lukáš Zachar
2012-10-10 16:32:47 UTC
It seems to be the problem of the format string. See: In [13]: print "Updating {0}'s {1} to '{2}'".format(1, 'foo', u'\u2026') UnicodeEncodeError: 'ascii' codec can't encode character u'\u2026' in position 0: ordinal not in range(128) But: In [15]: u"Updating {0}'s {1} to '{2}'".format(1, 'foo', u'\u2026') Out[15]: u"Updating 1's foo to '\u2026'" I am not sure if this is the best way how to fix is, though. Created attachment 625914 [details]
partial patch
This patch fixes only the error in the situation when I run into it.
It might be necessary to fix other/all "".format() calls.
Thanks for the patch, I've pushed it to the git repo https://github.com/psss/python-nitrate/commit/2d19ffa and also applied the same fix for other necessary places: https://github.com/psss/python-nitrate/commit/24d5841 python-nitrate-0.9-0.el6 has been submitted as an update for Fedora EPEL 6. https://admin.fedoraproject.org/updates/python-nitrate-0.9-0.el6 python-nitrate-0.9-0.fc18 has been submitted as an update for Fedora 18. https://admin.fedoraproject.org/updates/python-nitrate-0.9-0.fc18 python-nitrate-0.9-0.fc16 has been submitted as an update for Fedora 16. https://admin.fedoraproject.org/updates/python-nitrate-0.9-0.fc16 python-nitrate-0.9-0.fc17 has been submitted as an update for Fedora 17. https://admin.fedoraproject.org/updates/python-nitrate-0.9-0.fc17 python-nitrate-0.9-0.el6 has been submitted as an update for Fedora EPEL 6. https://admin.fedoraproject.org/updates/FEDORA-EPEL-2012-13721/python-nitrate-0.9-0.el6 Package python-nitrate-0.9-0.el6: * should fix your issue, * was pushed to the Fedora EPEL 6 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=epel-testing python-nitrate-0.9-0.el6' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-EPEL-2012-13721/python-nitrate-0.9-0.el6 then log in and leave karma (feedback). Tried the same and it works now. python-nitrate-0.9-0.fc17 has been pushed to the Fedora 17 stable repository. If problems still persist, please make note of it in this bug report. python-nitrate-0.9-0.fc16 has been pushed to the Fedora 16 stable repository. If problems still persist, please make note of it in this bug report. python-nitrate-0.9-0.el6 has been pushed to the Fedora EPEL 6 stable repository. If problems still persist, please make note of it in this bug report. python-nitrate-0.9-0.fc18 has been pushed to the Fedora 18 stable repository. If problems still persist, please make note of it in this bug report. |