#94 Handle IOError from kojihub
Closed: Fixed Opened by ralph.

From the rida logs::

2016-10-18 14:12:01,565 - rida - ERROR - Failed while handling u'2016-7a0cc0b9-97d7-4856-8ded-5d927a43349f'
Traceback (most recent call last):
  File "/home/fedora/rida-repos/fm-orchestrator/rida/scheduler/main.py", line 138, in run
    self.process_message(msg)
  File "/home/fedora/rida-repos/fm-orchestrator/rida/scheduler/main.py", line 167, in process_message
    handler(conf, db.session, msg)
  File "/home/fedora/rida-repos/fm-orchestrator/rida/scheduler/handlers/repos.py", line 84, in done
    if not builder.buildroot_ready(artifacts):
  File "/home/fedora/rida-repos/fm-orchestrator/rida/utils.py", line 45, in inner
    return function(*args, **kwargs)
  File "/home/fedora/rida-repos/fm-orchestrator/rida/builder.py", line 293, in buildroot_ready
    latest=True,
  File "/usr/lib/python2.7/site-packages/koji/util.py", line 88, in checkForBuilds
    tagged_list = session.getLatestBuilds(tag, event=event, package=build['name'])
  File "/usr/lib/python2.7/site-packages/koji/__init__.py", line 1736, in __call__
    return self.__func(self.__name,args,opts)
  File "/usr/lib/python2.7/site-packages/koji/__init__.py", line 2118, in _callMethod
    raise err
Fault: <Fault 1: "<type 'exceptions.IOError'>: request data read error">
2016-10-18 14:12:01,576 - rida - INFO - {u'crypto': u'x509',
 u'i': 3,
 u'msg': {u'instance': u'primary',
          u'repo_id': 9000141,
          u'tag': u'module-base-runtime-0.25-9-build',
          u'tag_id': 401},
 u'msg_id': u'2016-7a0cc0b9-97d7-4856-8ded-5d927a43349f',
 u'timestamp': 1476799863,
 u'topic': u'org.fedoraproject.stg.buildsys.repo.done',
 u'username': u'apache'}

First thing's first, we should write a test that duplicates this failure and then write the fix for it afterwards.

Writing the test will involve mocking checkForBuilds to raise an IOError the first time it is called.

Fixed in PR#196

@fivaldi changed the status to Closed

This issue has been migrated to Fedora Forge:
https://forge.fedoraproject.org/koji/mbs/issues/94

Please continue any further discussion there.

Metadata