2018-01-21 01:06 UTC

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0013660Buildsyscentpkgpublic2017-10-17 12:36
ReporterSandro Bonazzola 
PrioritynormalSeverityminorReproducibilityhave not tried
Summary0013660: yum - UnicodeEncodeError on Could not retrieve mirrorlist

  File "/usr/lib/python2.7/site-packages/yum/__init__.py", line 3455, in searchPackageProvides
    where = self.returnPackagesByDep(arg)
  File "/usr/lib/python2.7/site-packages/yum/__init__.py", line 4281, in returnPackagesByDep
    return self.pkgSack.searchProvides(depstring)
  File "/usr/lib/python2.7/site-packages/yum/__init__.py", line 1074, in <lambda>
    pkgSack = property(fget=lambda self: self._getSacks(),
  File "/usr/lib/python2.7/site-packages/yum/__init__.py", line 778, in _getSacks
  File "/usr/lib/python2.7/site-packages/yum/repos.py", line 347, in populateSack
  File "/usr/lib/python2.7/site-packages/yum/repos.py", line 158, in doSetup
  File "/usr/lib/python2.7/site-packages/yum/plugins.py", line 188, in run
    func(conduitcls(self, self.base, conf, **kwargs))
  File "/usr/lib/yum-plugins/fastestmirror.py", line 197, in postreposetup_hook
    if downgrade_ftp and _len_non_ftp(repo.urls) == 1:
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 876, in <lambda>
    urls = property(fget=lambda self: self._geturls(),
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 873, in _geturls
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 822, in _baseurlSetup
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 1974, in _getMirrorList
    print "Could not retrieve mirrorlist %s error was\n%s: %s" % (url, e.args[0], misc.to_unicode(e.args[1]))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe8' in position 180: ordinal not in range(128)

I was using Italian as system language and accessing directly yum API for oVirt/RHV OTOPI project.

OTOPI detected:
2017-08-11 13:18:21,151+0200 DEBUG otopi.context context.dumpEnvironment:771 ENV BASE/exceptionInfo=list:'[(<type 'exceptions.UnicodeEncodeError'>, UnicodeEncodeError('ascii', u'Could not retrieve mirrorlist htt
p://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock error was\n14: curl#7 - "Failed to connect to 2001:1b48:203::4:10: La rete non \xe8 raggiungibile"', 180, 181, 'ordinal not in range(128)'), <
traceback object at 0x111fb00>)]'

# rpm -qv yum

TagsNo tags attached.
Attached Files




bstinson (developer)

Is this supposed to be filed against centpkg?


Sandro Bonazzola (reporter)

No, it's a yum bug. looks like it uses curl and has issues with IPv6 addresses returned by http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock
The parser raises an error with ordinal not in range.
I have reproduced this on CentOS not on RHEL so opened the bug here.


avij (manager)

Interesting, but I'm afraid this can't be fixed from the CentOS side of things. yum is trying to print "La rete non รจ raggiungibile" but fails at doing that. You can probably reproduce this on RHEL as well if you point some repository to an IPv6-only address, such as http://ipv6.miuku.net/, on a RHEL host that has only an IPv4 address and with Italian locale.

(that ipv6.miuku.net address not a repository, but will probably be OK for this testing purpose)


Sandro Bonazzola (reporter)

Ok, I think this can be closed then.

-Issue History
Date Modified Username Field Change
2017-08-11 11:25 Sandro Bonazzola New Issue
2017-08-17 18:31 bstinson Note Added: 0029890
2017-08-21 07:25 Sandro Bonazzola Note Added: 0029914
2017-08-23 17:49 avij Note Added: 0029940
2017-10-17 05:34 Sandro Bonazzola Note Added: 0030382
2017-10-17 12:36 JohnnyHughes Status new => closed
2017-10-17 12:36 JohnnyHughes Resolution open => fixed
+Issue History