summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJesse Keating <jkeating@redhat.com>2011-01-30 14:51:26 -0700
committerJesse Keating <jkeating@redhat.com>2011-01-30 14:51:26 -0700
commite24784f3c35149062c68f21c5b124676802c3553 (patch)
tree78c7bc46a910b9e292fe1ce6351e69318403aae0 /src
parent74cffab0516897e2056c753f5cd39d696962328c (diff)
downloadfedora-packager-e24784f3c35149062c68f21c5b124676802c3553.zip
fedora-packager-e24784f3c35149062c68f21c5b124676802c3553.tar.gz
fedora-packager-e24784f3c35149062c68f21c5b124676802c3553.tar.xz
Handle traceback if koji is down or unreachable.
Diffstat (limited to 'src')
-rw-r--r--src/pyfedpkg/__init__.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/pyfedpkg/__init__.py b/src/pyfedpkg/__init__.py
index 7577823..d79fe1b 100644
--- a/src/pyfedpkg/__init__.py
+++ b/src/pyfedpkg/__init__.py
@@ -1053,7 +1053,11 @@ class PackageModule:
if not self.anonkojisession:
self.init_koji()
# We may not have Fedoras. Find out what rawhide target does.
- rawhidetarget = self.kojisession.getBuildTarget('dist-rawhide')
+ try:
+ rawhidetarget = self.kojisession.getBuildTarget('dist-rawhide')
+ except:
+ # We couldn't hit koji, bail.
+ raise FedpkgError('Unable to query koji to find rawhide target')
desttag = rawhidetarget['dest_tag_name']
return desttag.strip('dist-f')