Bug 1266159 - Python errors when executing dnf with spanish locale
Python errors when executing dnf with spanish locale
Status: CLOSED DUPLICATE of bug 1262082
Product: Fedora
Classification: Fedora
Component: dnf (Show other bugs)
22
x86_64 Linux
unspecified Severity high
: ---
: ---
Assigned To: packaging-team-maint
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-09-24 12:01 EDT by jorge.gonzalez
Modified: 2015-10-02 05:53 EDT (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-10-02 05:53:57 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description jorge.gonzalez 2015-09-24 12:01:40 EDT
Description of problem:

A python stack trace show when trying to execute 'dnf -y upgrade' as root.

Version-Release number of selected component (if applicable):

- Fedora 22, fully up to date as of Sep 24th 2015.
- dnf-1.1.1-2.fc22.noarch

How reproducible:

Always




Steps to Reproduce:

On a system with a spanish locale, enter:


[root@bespin ~]# echo $LANG
es_ES.UTF-8
[root@bespin ~]# dnf -y upgrade

Actual results:

[root@bespin ~]# dnf -y upgrade
Traceback (most recent call last):
  File "/bin/dnf", line 36, in <module>
    main.user_main(sys.argv[1:], exit_code=True)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 198, in user_main
    errcode = main(args)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 84, in main
    return _main(base, args)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 117, in _main
    cli.configure(map(ucd, args))
  File "/usr/lib/python2.7/site-packages/dnf/cli/cli.py", line 1007, in configure
    self.optparser.usage = self.optparser.get_usage()
  File "/usr/lib/python2.7/site-packages/dnf/cli/option_parser.py", line 273, in get_usage
    usage += "%-25s %s\n" % (name, summary)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 40: ordinal not in range(128)


Expected results:

Upgrade starts correctly.

Additional info:

When overriding the locale, it works as expected:

[root@bespin ~]# LANG=C dnf -y upgrade
Last metadata expiration check performed 0:15:05 ago on Thu Sep 24 17:45:09 2015.
Dependencies resolved.
Nothing to do.
Complete!
[root@bespin ~]# 

It seems that there's some problem with an Unicode translated message for DNF, which is in the Spanish locale but not on the English one.
Comment 1 Michal Luscon 2015-10-02 05:53:57 EDT

*** This bug has been marked as a duplicate of bug 1262082 ***

Note You need to log in before you can comment on or make changes to this bug.