Bug 1078832 - TypeError: '_DownloadErrors' object is not iterable
TypeError: '_DownloadErrors' object is not iterable
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: dnf (Show other bugs)
20
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Tim Lauridsen
Fedora Extras Quality Assurance
:
: 1079290 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2014-03-20 07:25 EDT by Michal Schmidt
Modified: 2014-03-25 04:13 EDT (History)
6 users (show)

See Also:
Fixed In Version: dnf-0.4.19-1.fc20
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-03-25 04:13:20 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)
full output from the failed "dnf update" (56.02 KB, text/plain)
2014-03-20 07:25 EDT, Michal Schmidt
no flags Details

  None (edit)
Description Michal Schmidt 2014-03-20 07:25:35 EDT
Created attachment 876789 [details]
full output from the failed "dnf update"

Description of problem:
I received a traceback when downloading packages after encountering multiple mirror errors:

...
[MIRROR] mesa-filesystem-10.0.4-1.20140312.fc20.x86_64.rpm: Status code: 404 for http://mirror.hmc.edu/fedora/linux/updates/testing/20/x86_64/mesa-filesystem-10.0.4-1.20140312.fc20.x86_64.rpm                
[MIRROR] mesa-libEGL-10.0.4-1.20140312.fc20.x86_64.rpm: Status code: 404 for http://mirror.hmc.edu/fedora/linux/updates/testing/20/x86_64/mesa-libEGL-10.0.4-1.20140312.fc20.x86_64.rpm                        
[MIRROR] mesa-dri-drivers-10.0.4-1.20140312.fc20.x86_64.rpm: Status code: 404 for http://mirror.hmc.edu/fedora/linux/updates/testing/20/x86_64/mesa-dri-drivers-10.0.4-1.20140312.fc20.x86_64.rpm              
[MIRROR] mesa-dri-drivers-10.0.4-1.20140312.fc20.x86_64.rpm: Curl error: Failure when receiving data from the peer for ftp://lug.mtu.edu/fedora/linux/updates/testing/20/x86_64/mesa-dri-drivers-10.0.4-1.20140312.fc20.x86_64.rpm
[FAILED] mesa-dri-drivers-10.0.4-1.20140312.fc20.x86_64.rpm: Curl error: Failure when receiving data from the peer for ftp://lug.mtu.edu/fedora/linux/updates/testing/20/x86_64/mesa-dri-drivers-10.0.4-1.20140312.fc20.x86_64.rpm
Traceback (most recent call last):0140312.fc20.x86_64.rpm                            82% [=====================================================================-              ] 4.7 MB/s | 122 MB     00:05 ETA
  File "/bin/dnf", line 35, in <module>
    main.user_main(sys.argv[1:], exit_code=True)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 242, in user_main
    errcode = main(args)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 64, in main
    return _main(base, args)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 156, in _main
    return_code, resultmsgs = base.do_transaction()
  File "/usr/lib/python2.7/site-packages/dnf/cli/cli.py", line 215, in do_transaction
    specific = dnf.cli.format.indent_block(str(e))
  File "/usr/lib/python2.7/site-packages/dnf/exceptions.py", line 91, in __str__
    return self.errmap2str(self.errmap)
  File "/usr/lib/python2.7/site-packages/dnf/exceptions.py", line 84, in errmap2str
    for key in errmap:
TypeError: '_DownloadErrors' object is not iterable


Version-Release number of selected component (if applicable):
dnf-0.4.18-1.fc20.noarch

How reproducible:
It happened only once. I retried the dnf update operation and it completed successfully then.

Steps to Reproduce:
1. dnf update
2. have bad luck with stale metadata or stale mirrors (?)
3. 

Actual results:
Traceback encountered.

Expected results:
No tracebacks. At worst a human readable error is printed. Though I'm not sure why I'm having so many 404 errors in the first place. Maybe that's a bug of its own.

Additional info:
I'm attaching the complete terminal output.
Comment 1 Ales Kozumplik 2014-03-21 03:32:15 EDT
Michael, I will look at this, thanks for reporting.
Comment 2 Jiri Popelka 2014-03-21 04:55:12 EDT
In my case it happened just before dnf started to download packages.
The next try succeeded without any problems.

Is this ok [y/N]: y
Downloading Packages:
Traceback (most recent call last):
<same traceback as in comment #0>
Comment 3 Ales Kozumplik 2014-03-21 05:45:01 EDT
Moving to Tim who got a patch.

Tim, I merged your fix as 87a0b0a, thank you!
Comment 4 Ales Kozumplik 2014-03-21 08:58:54 EDT
*** Bug 1079290 has been marked as a duplicate of this bug. ***
Comment 5 Fedora Update System 2014-03-24 05:05:45 EDT
dnf-0.4.19-1.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/dnf-0.4.19-1.fc20
Comment 6 Fedora Update System 2014-03-25 04:13:20 EDT
dnf-0.4.19-1.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

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