Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
DescriptionGennadii Altukhov
2017-08-21 10:52:01 UTC
Description of problem:
If no space left on device urlgrabber raises a KeyboardInterrupt exception with no error message and print some traceback on stderr instead.
Version-Release number of selected component (if applicable):
python-urlgrabber-3.9.1-11.el6.noarch
How reproducible:
100%
Steps to Reproduce:
1) create a lo device with 10 MB available:
# dd if=/dev/zero of=/disk bs=1M count=10
# losetup /dev/loop0 /disk
# mkfs.ext4 /dev/loop0
2) mount this dist to some directory, I'm using /var/satellite
# umount /var/satellite/
# mount /dev/loop0 /var/satellite/
# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/vda1 40G 13G 25G 35% /
tmpfs 1,9G 4,0K 1,9G 1% /dev/shm
/dev/loop0 976M 1,3M 924M 1% /var/satellite
3) execute the script below:
from urlgrabber import grabber
grabber.urlgrab("https://download.fedoraproject.org/pub/fedora/linux/releases/26/Server/x86_64/iso/Fedora-Server-netinst-x86_64-26-1.5.iso", "/var/satellite/fedora.iso")
Actual results:
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1107, in _retrieve
self.fo.write(buf)
IOError: [Errno 28] No space left on device
Traceback (most recent call last):
File "/tmp/url.py", line 4, in <module>
grabber.urlgrab("https://download.fedoraproject.org/pub/fedora/linux/releases/26/Server/x86_64/iso/Fedora-Server-netinst-x86_64-26-1.5.iso", "/var/satellite/fedora.iso")
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 626, in urlgrab
return default_grabber.urlgrab(url, filename, **kwargs)
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 994, in urlgrab
return self._retry(opts, retryfunc, url, filename)
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 895, in _retry
r = apply(func, (opts,) + args, {})
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 980, in retryfunc
fo = PyCurlFileObject(url, filename, opts)
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1075, in __init__
self._do_open()
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1378, in _do_open
self._do_grab()
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1508, in _do_grab
self._do_perform()
File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1301, in _do_perform
raise KeyboardInterrupt
KeyboardInterrupt
Expected results:
No error message "IOError: [Errno 28] No space left on device" printed on STDERR, a different type of an exception.
Additional info:
On Fedora 25 this bug is fixed in version python-urlgrabber-3.10.1-9.fc25.noarch
Comment 2Gennadii Altukhov
2017-08-21 11:00:27 UTC
As you can see above in the description there are two tracebacks. First of them is printed from within library directly on STDERR, the second one is from my script and it is OK. I'm complaining only about the first one of course.
The same exception is raised when a network interruption (send() or recv()) occurs.
I'm on python-urlgrabber-3.10-4.el7.noarch here.
In grabber.py
elif errcode in (42, 55, 56):
# this is probably wrong but ultimately this is what happens
# we have a legit http code and a pycurl 'writer failed' code
# which almost always means something aborted it from outside
# since we cannot know what it is -I'm banking on it being
# a ctrl-c. XXXX - if there's a way of going back two raises to
# figure out what aborted the pycurl process FIXME
raise KeyboardInterrupt
It is not probably wrong, it is definitely wrong.
Just below that, we have:
55 : _("Network error send()"),
56 : _("Network error recv()"),
Why not define a meaningful exception and raise that instead?
Cheers
Red Hat Enterprise Linux 6 is in the Production 3 Phase. During the Production 3 Phase, Critical impact Security Advisories (RHSAs) and selected Urgent Priority Bug Fix Advisories (RHBAs) may be released as they become available.
The official life cycle policy can be reviewed here:
http://redhat.com/rhel/lifecycle
This issue does not meet the inclusion criteria for the Production 3 Phase and will be marked as CLOSED/WONTFIX. If this remains a critical requirement, please contact Red Hat Customer Support to request a re-evaluation of the issue, citing a clear business justification. Note that a strong business justification will be required for re-evaluation. Red Hat Customer Support can be contacted via the Red Hat Customer Portal at the following URL:
https://access.redhat.com/
Description of problem: If no space left on device urlgrabber raises a KeyboardInterrupt exception with no error message and print some traceback on stderr instead. Version-Release number of selected component (if applicable): python-urlgrabber-3.9.1-11.el6.noarch How reproducible: 100% Steps to Reproduce: 1) create a lo device with 10 MB available: # dd if=/dev/zero of=/disk bs=1M count=10 # losetup /dev/loop0 /disk # mkfs.ext4 /dev/loop0 2) mount this dist to some directory, I'm using /var/satellite # umount /var/satellite/ # mount /dev/loop0 /var/satellite/ # df -h Filesystem Size Used Avail Use% Mounted on /dev/vda1 40G 13G 25G 35% / tmpfs 1,9G 4,0K 1,9G 1% /dev/shm /dev/loop0 976M 1,3M 924M 1% /var/satellite 3) execute the script below: from urlgrabber import grabber grabber.urlgrab("https://download.fedoraproject.org/pub/fedora/linux/releases/26/Server/x86_64/iso/Fedora-Server-netinst-x86_64-26-1.5.iso", "/var/satellite/fedora.iso") Actual results: Traceback (most recent call last): File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1107, in _retrieve self.fo.write(buf) IOError: [Errno 28] No space left on device Traceback (most recent call last): File "/tmp/url.py", line 4, in <module> grabber.urlgrab("https://download.fedoraproject.org/pub/fedora/linux/releases/26/Server/x86_64/iso/Fedora-Server-netinst-x86_64-26-1.5.iso", "/var/satellite/fedora.iso") File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 626, in urlgrab return default_grabber.urlgrab(url, filename, **kwargs) File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 994, in urlgrab return self._retry(opts, retryfunc, url, filename) File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 895, in _retry r = apply(func, (opts,) + args, {}) File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 980, in retryfunc fo = PyCurlFileObject(url, filename, opts) File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1075, in __init__ self._do_open() File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1378, in _do_open self._do_grab() File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1508, in _do_grab self._do_perform() File "/usr/lib/python2.6/site-packages/urlgrabber/grabber.py", line 1301, in _do_perform raise KeyboardInterrupt KeyboardInterrupt Expected results: No error message "IOError: [Errno 28] No space left on device" printed on STDERR, a different type of an exception. Additional info: On Fedora 25 this bug is fixed in version python-urlgrabber-3.10.1-9.fc25.noarch