| Summary: | [abrt] yum-3.2.27-14.el6: up2dateLog.py:57:write_log:UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-24: ordinal not in range(128) | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 6 | Reporter: | Red Hat Case Diagnostics <case-diagnostics> | ||||||
| Component: | rhn-client-tools | Assignee: | Michael Mráka <mmraka> | ||||||
| Status: | CLOSED ERRATA | QA Contact: | Martin Minar <mminar> | ||||||
| Severity: | medium | Docs Contact: | |||||||
| Priority: | medium | ||||||||
| Version: | 6.0 | CC: | ffotorel, hkim, mkoci, mminar, mmraka, mpatocka, rdassen | ||||||
| Target Milestone: | rc | ||||||||
| Target Release: | --- | ||||||||
| Hardware: | x86_64 | ||||||||
| OS: | Unspecified | ||||||||
| Whiteboard: | abrt_hash:2f16c311 | ||||||||
| Fixed In Version: | rhn-client-tools-1.0.0-64.el6 | Doc Type: | Bug Fix | ||||||
| Doc Text: |
Prior to this update, the presence of a UTF-8 character in an error or log message caused rhnplugin to terminate unexpectedly with a traceback. Such messages are now printed as expected.
|
Story Points: | --- | ||||||
| Clone Of: | Environment: | ||||||||
| Last Closed: | 2011-12-06 16:49:42 UTC | Type: | --- | ||||||
| Regression: | --- | Mount Type: | --- | ||||||
| Documentation: | --- | CRM: | |||||||
| Verified Versions: | Category: | --- | |||||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||||
| Attachments: |
|
||||||||
Created attachment 505247 [details]
File: backtrace
Fixed in spacewalk.git in commit 400df68c3498fc4800aa449e1ed9dc2226542e1c Created attachment 516991 [details]
File: backtrace
Backported to CLIENT_RHEL-6 as
commit 159c638cdf862afbf8cd14fad1028e21aa1dc743
714113 - handle writing unicode to log file (cherry picked from commit 400df68c3498f
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
New Contents:
yum-rhn-plugin did not like utf8 log messages and they caused tracebacks.
It's been fixed to be able to print utf8 messages to log file.
Technical note updated. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
Diffed Contents:
@@ -1,3 +1 @@
-yum-rhn-plugin did not like utf8 log messages and they caused tracebacks.
+Prior to this update, the presence of a UTF-8 character in an error or log message caused rhnplugin to terminate unexpectedly with a traceback. Such messages are now printed as expected.-
-It's been fixed to be able to print utf8 messages to log file.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHBA-2011-1664.html *** Bug 786985 has been marked as a duplicate of this bug. *** |
This description generated by Andreas from an ABRT report architecture: x86_64 cmdline: /usr/bin/python /usr/bin/yum install libtiff-devel component: yum executable: /usr/bin/yum kernel: 2.6.32-71.el6.x86_64 package: yum-3.2.27-14.el6 reason: up2dateLog.py:57:write_log:UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-24: ordinal not in range(128) release: Red Hat Enterprise Linux Workstation release 6.1 (Santiago) reproduce: 1.yum install libtiff-develを実行したら発生 2. 3. time: 1308342371 uid: 0 backtrace: up2dateLog.py:57:write_log:UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-24: ordinal not in range(128) Traceback (most recent call last): File "/usr/bin/yum", line 29, in <module> yummain.user_main(sys.argv[1:], exit_code=True) File "/usr/share/yum-cli/yummain.py", line 274, in user_main errcode = main(args) File "/usr/share/yum-cli/yummain.py", line 211, in main return_code = base.doTransaction() File "/usr/share/yum-cli/cli.py", line 584, in doTransaction resultobject = self.runTransaction(cb=cb) File "/usr/lib/python2.6/site-packages/yum/__init__.py", line 1527, in runTransaction self.plugins.run('posttrans') File "/usr/lib/python2.6/site-packages/yum/plugins.py", line 184, in run func(conduitcls(self, self.base, conf, **kwargs)) File "/usr/share/yum-plugins/rhnplugin.py", line 221, in posttrans_hook str(e)) File "/usr/share/rhn/up2date_client/up2dateErrors.py", line 179, in __repr__ log.log_me(msg) File "/usr/share/rhn/up2date_client/up2dateLog.py", line 37, in log_me self.write_log(s) File "/usr/share/rhn/up2date_client/up2dateLog.py", line 57, in write_log msg = "%s %s\n" % (self.log_info, str(s)) UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-24: ordinal not in range(128) Local variables in innermost frame: s: u'\u30b5\u30fc\u30d0\u3068\u306e\u901a\u4fe1\u4e2d\u306b\u30a8\u30e9\u30fc\u304c\u767a\u751f\u3057\u307e\u3057\u305f\u3002\u30e1\u30c3\u30bb\u30fc\u30b8:\nConnection timed out on readline' log_file: <open file '/var/log/up2date', mode 'a' at 0x48cf540> log_name: '/var/log/up2date' self: <up2date_client.up2dateLog.Log instance at 0x2f9c9e0>