#340 "ValueError: Value out of range" in python-progressbar for openh264 package
Closed: Fixed Opened by kparal.

python-progressbar crashes:

[libtaskotron] 02:25:16 INFO    Querying Koji for a list of RPMS for: openh264-1.5.2-0.4.git21e44bd.fc24
[libtaskotron] 02:25:16 INFO    Fetching 13 RPMs for: openh264-1.5.2-0.4.git21e44bd.fc24 (into /var/tmp/taskotron/root/task-yrCS9l)
  0%|                                                |ETA:  --:--:--  0.00  B/s
[libtaskotron] 02:25:16 CRITICAL Traceback (most recent call last):
  File "/usr/bin/runtask", line 9, in <module>
    load_entry_point('libtaskotron==0.4.8', 'console_scripts', 'runtask')()
  File "/usr/lib/python2.7/site-packages/libtaskotron/main.py", line 151, in main
    overlord.start()
  File "/usr/lib/python2.7/site-packages/libtaskotron/overlord.py", line 95, in start
    runner.execute()
  File "/usr/lib/python2.7/site-packages/libtaskotron/executor.py", line 56, in execute
    self._run()
  File "/usr/lib/python2.7/site-packages/libtaskotron/executor.py", line 93, in _run
    self._do_actions()
  File "/usr/lib/python2.7/site-packages/libtaskotron/executor.py", line 131, in _do_actions
    self._do_single_action(action)
  File "/usr/lib/python2.7/site-packages/libtaskotron/executor.py", line 152, in _do_single_action
    self.arg_data)
  File "/usr/lib/python2.7/site-packages/libtaskotron/directives/koji_directive.py", line 165, in process
    src=self.src)
  File "/usr/lib/python2.7/site-packages/libtaskotron/ext/fedora/koji_utils.py", line 228, in get_nvr_rpms
    rpm_file = file_utils.download(url, dest, cachedir=cachedir)
  File "/usr/lib/python2.7/site-packages/libtaskotron/file_utils.py", line 122, in download
    _download(url, dl_dest)
  File "/usr/lib/python2.7/site-packages/libtaskotron/file_utils.py", line 179, in _download
    pbar.update(read)
  File "/usr/lib/python2.7/site-packages/progressbar/__init__.py", line 272, in update
    raise ValueError('Value out of range')
ValueError: Value out of range

This crashed on all dev, stg and prod on the exactly same two packages openh264-1.5.2-0.4.git21e44bd.fc24 and openh264-1.5.2-0.4.git21e44bd.fc25:
https://taskotron.fedoraproject.org/taskmaster/builders/x86_64/builds/199142/steps/runtask/logs/stdio
https://taskotron.fedoraproject.org/taskmaster/builders/x86_64/builds/199135/steps/runtask/logs/stdio

Find out why, and fix.
(Hint: Maybe we just need to update python-progressbar?)


This ticket had assigned some Differential requests:
D866

It fails on this http://kojipkgs.fedoraproject.org/packages/openh264/1.5.2/0.4.git21e44bd.fc24/armv7hl/gstreamer1-plugin-openh264-1.6.1-2.fc24.armv7hl.rpm. If you follow the link, it will redirect you to https://fedoraproject.org/wiki/Non-distributable-rpms. So our code takes Content-Length of the rpm and then downloads content of redirected link which length is different and progress bar fails. In other words we don't handle http redirects.

In this case though we should skip the rpm since it cannot be downloaded at all.

Fixed in D866, and the remaining issues with openh264 described in #803.

Metadata Update from @kparal:
- Issue tagged with: easyfix

Metadata