From d1ec836e76461692360901f38d904016b82bda6d Mon Sep 17 00:00:00 2001 From: Jonathan Davies Date: Sat, 17 Jan 2009 14:33:29 +0000 Subject: [PATCH] * requestsync: Skip existing bug check if no credentials are found (LP: #318120). --- debian/changelog | 3 ++- requestsync | 15 ++++++++++----- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/debian/changelog b/debian/changelog index 3c226f2..72e5918 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,6 +1,7 @@ ubuntu-dev-tools (0.57) UNRELEASED; urgency=low - * Changes go here. + * requestsync: Skip existing bug check if no credentials are + found (LP: #318120). -- Jonathan Davies Sat, 17 Jan 2009 11:41:22 +0000 diff --git a/requestsync b/requestsync index 1a48f91..82c56cb 100755 --- a/requestsync +++ b/requestsync @@ -95,19 +95,24 @@ def checkExistingReports(package): If found ask for confirmation on filing a request. """ + launchpad = None + try: launchpad = common.get_launchpad("ubuntu-dev-tools") except ImportError: print >> sys.stderr, 'Importing launchpadlib failed. Is ' \ 'python-launchpadlib installed?' - print >> sys.stderr, "Skipping existing report check, you should "\ - "manually check at:" - print "- https://bugs.launchpad.net/ubuntu/+source/%s" % package - return False except IOError, msg: # No credentials found. print msg - sys.exit(1) + + # Failed to get Launchpad credentials. + if launchpad is None: + print >> sys.stderr, "Skipping existing report check, you should "\ + "manually see if there are any at:" + print "- https://bugs.launchpad.net/ubuntu/+source/%s" % package + print "" + return False # Fetch the package's bug list from Launchpad. pkg = launchpad.distributions["ubuntu"].getSourcePackage(name=package)