mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-03-13 08:01:09 +00:00
If importing lpbugs fails - show the right URL if package is new or not.
This commit is contained in:
parent
4e476d4755
commit
b82069f31b
19
requestsync
19
requestsync
@ -90,6 +90,15 @@ def checkExistingReports(package, isNewPackage):
|
||||
|
||||
If found ask for confirmation on filing a request.
|
||||
"""
|
||||
# Determine if the package is new or not.
|
||||
if isNewPackage:
|
||||
# Package not in Ubuntu, check Ubuntu Archive Team's bug page for
|
||||
# possible duplicate reports.
|
||||
bugListUrl = "https://bugs.launchpad.net/~ubuntu-archive"
|
||||
else:
|
||||
# Package in Ubuntu, check the package's bug list for duplicate reports.
|
||||
bugListUrl = "https://bugs.launchpad.net/ubuntu/+source/%s" % package
|
||||
|
||||
try:
|
||||
import launchpadbugs.connector as Connector
|
||||
except:
|
||||
@ -98,20 +107,12 @@ def checkExistingReports(package, isNewPackage):
|
||||
"python-launchpad-bugs installed?"
|
||||
print >> sys.stderr, "Skipping existing report check, you should "\
|
||||
"manually check at:"
|
||||
print "- https://bugs.launchpad.net/ubuntu/+source/%s" % package
|
||||
print "-", bugListUrl
|
||||
return
|
||||
|
||||
# Connect to the bug list.
|
||||
bugList = Connector.ConnectBugList()
|
||||
|
||||
if isNewPackage:
|
||||
# Package not in Ubuntu, check Ubuntu Archive Team's bug page for
|
||||
# possible duplicate reports.
|
||||
bugListUrl = "https://bugs.launchpad.net/~ubuntu-archive"
|
||||
else:
|
||||
# Package in Ubuntu, check the package's bug list for duplicate reports.
|
||||
bugListUrl = "https://bugs.launchpad.net/ubuntu/+source/%s" % package
|
||||
|
||||
# Fetch data from Launchpad.
|
||||
pkgBugList = bugList(bugListUrl)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user