 |
 |
 |
 |
| Using Fedora General support for current versions. Ask questions about Fedora and it's software that do not belong in any other forum. |

26th April 2005, 04:07 PM
|
 |
Retired Community Manager
|
|
Join Date: Feb 2004
Posts: 2,999

|
|
I've been recieving the following error, whenever i try to use Yum. Yum has been working, but has now stopped.
Code:
Setting up Update Process
Setting up Repos
Traceback (most recent call last):
File "/usr/bin/yum", line 7, in ?
yummain.main(sys.argv[1:])
File "/usr/share/yum-cli/yummain.py", line 68, in main
result, resultmsgs = base.doCommands()
File "/usr/share/yum-cli/cli.py", line 408, in doCommands
return self.updatePkgs()
File "/usr/share/yum-cli/cli.py", line 923, in updatePkgs
self.doRepoSetup()
File "/usr/share/yum-cli/cli.py", line 69, in doRepoSetup
repo.baseurlSetup()
File "repos.py", line 437, in baseurlSetup
File "repos.py", line 690, in getMirrorList
File "grabber.py", line 433, in urlopen
File "grabber.py", line 562, in urlopen
File "grabber.py", line 534, in _retry
File "grabber.py", line 561, in retryfunc
File "grabber.py", line 714, in __init__
File "grabber.py", line 758, in _do_open
File "grabber.py", line 835, in _make_request
File "/usr/lib/python2.3/urllib2.py", line 326, in open
'_open', req)
File "/usr/lib/python2.3/urllib2.py", line 306, in _call_chain
result = func(*args)
File "/usr/lib/python2.3/urllib2.py", line 491, in <lambda>
lambda r, proxy=url, type=type, meth=self.proxy_open: \
File "/usr/lib/python2.3/urllib2.py", line 498, in proxy_open
if '@' in host:
TypeError: iterable argument required
I've attempted to reinstall yum but with no success. I'm behind a proxy, but yum was working until i had to logout whilst yum was still running. Since then i've had this problem. Any ideas?
|

26th April 2005, 04:12 PM
|
 |
Registered User
|
|
Join Date: Apr 2005
Location: Northants, UK
Posts: 2,026

|
|
|
Does this help?
yum update yum
then try again
|

26th April 2005, 04:21 PM
|
 |
Retired Community Manager
|
|
Join Date: Feb 2004
Posts: 2,999

|
|
Not in the slightest. Peforming a: Results in:
Code:
Setting up Update Process
Setting up Repos
Traceback (most recent call last):
File "/usr/bin/yum", line 7, in ?
yummain.main(sys.argv[1:])
File "/usr/share/yum-cli/yummain.py", line 68, in main
result, resultmsgs = base.doCommands()
File "/usr/share/yum-cli/cli.py", line 408, in doCommands
return self.updatePkgs()
File "/usr/share/yum-cli/cli.py", line 923, in updatePkgs
self.doRepoSetup()
File "/usr/share/yum-cli/cli.py", line 69, in doRepoSetup
repo.baseurlSetup()
File "repos.py", line 437, in baseurlSetup
File "repos.py", line 690, in getMirrorList
File "grabber.py", line 433, in urlopen
File "grabber.py", line 562, in urlopen
File "grabber.py", line 534, in _retry
File "grabber.py", line 561, in retryfunc
File "grabber.py", line 714, in __init__
File "grabber.py", line 758, in _do_open
File "grabber.py", line 835, in _make_request
File "/usr/lib/python2.3/urllib2.py", line 326, in open
'_open', req)
File "/usr/lib/python2.3/urllib2.py", line 306, in _call_chain
result = func(*args)
File "/usr/lib/python2.3/urllib2.py", line 491, in <lambda>
lambda r, proxy=url, type=type, meth=self.proxy_open: \
File "/usr/lib/python2.3/urllib2.py", line 498, in proxy_open
if '@' in host:
TypeError: iterable argument required
Yum update yum, provides the same result.
|

26th April 2005, 04:36 PM
|
 |
Registered User
|
|
Join Date: Apr 2005
Location: Northants, UK
Posts: 2,026

|
|
|
The code traceback seems to show an attempt to parse a broken or empty mirror list?
Try to change your base repo file, or whichever repo file comes up first, to a fixed URL, eg
baseurl=http://mirror.hiwaay.net/redhat/fedora/linux/core/$releasever/$basearch/os/
|

26th April 2005, 04:58 PM
|
 |
Retired Community Manager
|
|
Join Date: Feb 2004
Posts: 2,999

|
|
|
No such luck. I didn't think that would make a difference either, as when I unistalled Yum it removed those files as well.
|

26th April 2005, 05:16 PM
|
 |
Retired Community Manager
|
|
Join Date: Feb 2004
Posts: 2,999

|
|
|
Sorry you don't seem to understand. I have this yum problem, but it has not been fixed by me reinstalling yum. So yum is installed.
|

26th April 2005, 06:47 PM
|
 |
Community Manager
|
|
Join Date: Mar 2004
Location: Vancouver, Canada
Posts: 2,366

|
|
|
Could you provide the code of yum(/usr/bin/yum) and /usr/share/yum-cli/yummain.py, please? It will be interesting to see the problem.
__________________
Desktop CPU: AMD Phenom II(tm) X4 Processor 940 AM2+ - Memory: 8GB DDR2-RAM - GPU: Nvidia Geforce GTX 460 v2 - OS: Fedora 18 Spherical Cow x86-64 and Windows 7 Ultimate SP1 64-bit
Laptop Toshiba Satellite C650D - OS: Fedora 19 Schrödinger's Cat (preview release) x86-64 and Microsoft Windows 7 64-bit
|

26th April 2005, 08:04 PM
|
 |
Registered User
|
|
Join Date: Apr 2005
Location: Northants, UK
Posts: 2,026

|
|
Quote:
|
when I unistalled Yum it removed those files as well.
|
You're right, for some unaccountable reason I misunderstood. Apologies.
|

27th April 2005, 09:26 AM
|
 |
Retired Community Manager
|
|
Join Date: Feb 2004
Posts: 2,999

|
|
Quote:
|
Originally Posted by AndyGreen
You're right, for some unaccountable reason I misunderstood. Apologies.
|
No problem, you were only trying to help.
And as requested the code for /usr/bin/yum:
Code:
#!/usr/bin/python
import sys
sys.path.insert(0, '/usr/share/yum-cli')
try:
import yummain
yummain.main(sys.argv[1:])
except KeyboardInterrupt, e:
print >> sys.stderr, "\n\nExiting on user cancel."
sys.exit(1)
And /usr/share/yum-cli/yummain.py:
Code:
#!/usr/bin/python -t
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Library General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Copyright 2004 Duke University
import os
import sys
import locale
import time # test purposes only
import yum
import yum.Errors as Errors
import cli
from i18n import _
def main(args):
"""This does all the real work"""
locale.setlocale(locale.LC_ALL, '')
# our core object for the cli
base = cli.YumBaseCli()
if len(args) < 1:
base.usage()
def unlock():
try:
base.closeRpmDB()
base.doUnlock('/var/run/yum.pid')
except Errors.LockError, e:
sys.exit(200)
# do our cli parsing and config file setup
# also sanity check the things being passed on the cli
try:
base.getOptionsConfig(args)
except Errors.YumBaseError, e:
result = 1
resultmsgs = [str(e)]
for msg in resultmsgs:
print >> sys.stderr, msg
sys.exit(1)
try:
base.doLock('/var/run/yum.pid')
except Errors.LockError, e:
base.errorlog(0,'%s' % e.msg)
sys.exit(200)
# build up an idea of what we're supposed to do
try:
result, resultmsgs = base.doCommands()
except Errors, e:
result = 1
resultmsgs = [str(e)]
except KeyboardInterrupt, e:
base.errorlog(0, '\n\nExiting on user cancel')
unlock()
sys.exit(1)
except IOError, e:
if e.errno == 32:
base.errorlog(0, '\n\nExiting on Broken Pipe')
unlock()
sys.exit(1)
if result not in [0, 1, 2, 100]:
base.errorlog(0, 'Unknown Error(s): Exit Code: %d:' % result)
for msg in resultmsgs:
base.errorlog(0, msg)
unlock()
sys.exit(3)
if result == 100:
unlock()
sys.exit(100)
elif result == 0:
for msg in resultmsgs:
base.log(2, '%s' % msg)
unlock()
sys.exit(0)
elif result == 1:
for msg in resultmsgs:
base.errorlog(0, 'Error: %s' % msg)
unlock()
sys.exit(1)
# Depsolve stage
base.log(2, 'Resolving Dependencies')
base.log(3, time.time())
try:
(result, resultmsgs) = base.buildTransaction()
except Errors.YumBaseError, e:
result = 1
resultmsgs = [str(e)]
except KeyboardInterrupt, e:
base.errorlog(0, '\n\nExiting on user cancel')
unlock()
sys.exit(1)
except IOError, e:
if e.errno == 32:
base.errorlog(0, '\n\nExiting on Broken Pipe')
unlock()
sys.exit(1)
if result not in [0, 1, 2]:
base.errorlog(0, 'Unknown Error(s): Exit Code: %d:' % result)
for msg in resultmsgs:
base.errorlog(0, msg)
unlock()
sys.exit(3)
if result == 0:
unlock()
sys.exit(0)
elif result == 1:
for msg in resultmsgs:
base.errorlog(0, 'Error: %s' % msg)
unlock()
sys.exit(1)
base.log(2, '\nDependencies Resolved')
base.log(3, time.time())
#run post-depresolve script here
#run pre-trans script here
# run the transaction
try:
base.doTransaction()
except Errors.YumBaseError, e:
base.errorlog(0, '%s' % e)
unlock()
sys.exit(1)
except KeyboardInterrupt, e:
base.errorlog(0, '\n\nExiting on user cancel')
unlock()
sys.exit(1)
except IOError, e:
if e.errno == 32:
base.errorlog(0, '\n\nExiting on Broken Pipe')
unlock()
sys.exit(1)
# run post-trans script here
# things ran correctly
# run a report function base.whatwedid() :)
base.log(2, 'Complete!')
unlock()
sys.exit(0)
if __name__ == "__main__":
try:
main(sys.argv[1:])
except KeyboardInterrupt, e:
print >> sys.stderr, "\n\nExiting on user cancel."
sys.exit(1)
|

27th April 2005, 02:16 PM
|
 |
Registered User
|
|
Join Date: Jun 2004
Posts: 233

|
|
|
It looks like some problem with the proxy url, that make some python class used bye yum fail.
have you specified a http_proxy=<Proxy server>, and what is set to ???
Try 'echo $HTTP_PROXY'
|

27th April 2005, 03:14 PM
|
|
Registered User
|
|
Join Date: Mar 2005
Posts: 145

|
|
|
It looks like your installed python package or your libxml2-python package (and through dependencies libxml2) may be broken. Those are the only python related yum dependencies which have been officially updated for FC3.
I suggest dowloading the updated packages and reinstalling them.
Last edited by nordicart; 27th April 2005 at 06:28 PM.
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
Current GMT-time: 13:07 (Tuesday, 21-05-2013)
|
|
 |
 |
 |
 |
|
|