#49 wrap update sync in try-except so newer fedora releases don't blow up when syncing
Closed: Fixed Opened by tflink.

Since the f24 release was added to blockerbugs, I've been getting error messages from the sync process like:

Traceback (most recent call last):
  File "/usr/bin/blockerbugs", line 9, in <module>
    load_entry_point('blockerbugs==0.4.4.4', 'console_scripts', 'blockerbugs')()
  File "/usr/lib/python2.7/site-packages/blockerbugs/cli.py", line 210, in main
    sync_updates(fullsync=options.full)
  File "/usr/lib/python2.7/site-packages/blockerbugs/cli.py", line 169, in sync_updates
    update_sync.sync_updates(release, fullsync)
  File "/usr/lib/python2.7/site-packages/blockerbugs/util/update_sync.py", line 184, in sync_updates
    self.sync_bug_updates(release, bugs, fullsync)
  File "/usr/lib/python2.7/site-packages/blockerbugs/util/update_sync.py", line 147, in sync_bug_updates
    updates = self.search_updates(bugs_ids, release.number)
  File "/usr/lib/python2.7/site-packages/blockerbugs/util/update_sync.py", line 117, in search_updates
    result = self.bodhi_interface.query(**queries_data)
  File "/usr/lib/python2.7/site-packages/fedora/client/bodhi.py", line 107, in wrapper
    raise BodhiClientException(problems)
fedora.client.bodhi.BodhiClientException: Invalid release specified: f24

As I recall, old-bodhi just didn't return anything if you asked about a release it didn't know about but bodhi2 returns an error. Since the f24 release won't exist in bodhi for a while yet, wrap that part of the sync process in a try-except block to keep the error from propagating upwards so far


This ticket had assigned some Differential requests:
D669
D641

Strangely enough, this issue is back. I'm at a bit of a loss as to why, though. 0.4.4.5 is installed and the code in site-packages has the exception catching logic in it.

The emails I'm receiving (from production only) for every sync are:

Traceback (most recent call last):
  File "/usr/bin/blockerbugs", line 9, in <module>
    load_entry_point('blockerbugs==0.4.4.5', 'console_scripts', 'blockerbugs')()
  File "/usr/lib/python2.7/site-packages/blockerbugs/cli.py", line 210, in main
    sync_updates(fullsync=options.full)
  File "/usr/lib/python2.7/site-packages/blockerbugs/cli.py", line 169, in sync_updates
    update_sync.sync_updates(release, fullsync)
  File "/usr/lib/python2.7/site-packages/blockerbugs/util/update_sync.py", line 194, in sync_updates
    self.sync_bug_updates(release, bugs, fullsync)
  File "/usr/lib/python2.7/site-packages/blockerbugs/util/update_sync.py", line 157, in sync_bug_updates
    updates = self.search_updates(bugs_ids, release.number)
  File "/usr/lib/python2.7/site-packages/blockerbugs/util/update_sync.py", line 118, in search_updates
    result = self.bodhi_interface.query(**queries_data)
  File "/usr/lib/python2.7/site-packages/fedora/client/bodhi.py", line 104, in wrapper
    raise BodhiClientException(problems)
fedora.client.bodhi.BodhiClientException: Invalid releases specified: f24

Just thinking out loud here, could it be that it's just 'log.exception' being emailed?

Fixed (again) and deployed to both stg and prod. Re-open if the problem persists.

This issue has been migrated to Fedora Forge:
https://forge.fedoraproject.org/quality/blockerbugs/issues/49

Please continue any further discussion there.

Log in to comment on this ticket.

Metadata