sponsor-patch: Use syncpackage instead of subscribing ubuntu-archive for sync requests, because syncpackage supports sponsorship now.

This commit is contained in:
Benjamin Drung 2011-12-10 12:51:53 +01:00
parent 9482e7b9f9
commit 58e6dfbbdb
4 changed files with 12 additions and 11 deletions

7
debian/changelog vendored
View File

@ -1,3 +1,10 @@
ubuntu-dev-tools (0.138) UNRELEASED; urgency=low
* sponsor-patch: Use syncpackage instead of subscribing ubuntu-archive for
sync requests, because syncpackage supports sponsorship now.
-- Benjamin Drung <bdrung@debian.org> Sat, 10 Dec 2011 12:46:33 +0100
ubuntu-dev-tools (0.137) unstable; urgency=low
[ Stefano Rivera ]

View File

@ -14,9 +14,6 @@ builds it, runs
.BR lintian (1)
and, after review and confirmation, can upload it.
For syncs, sponsor\-patch will follow the usual procedure of commenting
on \fIbug\fR, marking it confirmed, and subscribing \fBubuntu-archive\fR.
\fBsponsor\-patch\fR can be used for sponsoring patches, syncs and
merges from Debian, SRUs, and creating debdiffs from patches.
If \fIbug\fR has multiple patches or branches linked, it will prompt the

View File

@ -437,14 +437,12 @@ class SourcePackage(object):
return lintian_filename
def sync(self, upload, bug_number, keyid):
def sync(self, upload, bug_number, requester):
"""Does a sync of the source package."""
if upload == "ubuntu":
cmd = ["syncpackage", self._package, "-b", str(bug_number),
"-V", str(self._version)]
if keyid is not None:
cmd += ["-k", keyid]
cmd = ["syncpackage", self._package, "-b", str(bug_number), "-f",
"-s", requester, "-V", str(self._version)]
Logger.command(cmd)
if subprocess.call(cmd) != 0:
Logger.error("Syncing of %s %s failed.", self._package,
@ -452,7 +450,7 @@ class SourcePackage(object):
sys.exit(1)
else:
# FIXME: Support this use case!
Logger.error("Uploading a synced package other than to ubuntu "
Logger.error("Uploading a synced package other than to Ubuntu "
"is not supported yet!")
sys.exit(1)
return True

View File

@ -277,8 +277,7 @@ def sponsor_patch(bug_number, build, builder, edit, keyid, lpinstance, update,
previous_version)
if successful:
#if source_package.sync(upload, bug_number, keyid):
if source_package.ack_sync(upload, task.get_lp_task(), launchpad):
if source_package.sync(upload, bug_number, bug.owner.name):
return
else:
edit = True