Merge lp:~cjwatson/britney/sru-config into lp:~ubuntu-release/britney/britney1-ubuntu

Proposed by Colin Watson
Status: Merged
Merge reported by: Steve Langasek
Merged at revision: not available
Proposed branch: lp:~cjwatson/britney/sru-config
Merge into: lp:~ubuntu-release/britney/britney1-ubuntu
Diff against target: 79 lines (+22/-7)
1 file modified
britney (+22/-7)
To merge this branch: bzr merge lp:~cjwatson/britney/sru-config
Reviewer Review Type Date Requested Status
Steve Langasek Approve
Review via email: mp+249201@code.launchpad.net

Commit message

Set up hints and blocks appropriately for runs against Ubuntu stable series.

Description of the change

Set up hints and blocks appropriately for runs against Ubuntu stable series.

To post a comment you must log in.
Revision history for this message
Steve Langasek (vorlon) wrote :

LGTM.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'britney'
--- britney 2014-12-10 14:55:57 +0000
+++ britney 2015-02-10 14:21:24 +0000
@@ -20,7 +20,8 @@
2020
21LP_SERVICE="${LP_SERVICE:-production}"21LP_SERVICE="${LP_SERVICE:-production}"
22DISTRIBUTION="${DISTRIBUTION:-ubuntu}"22DISTRIBUTION="${DISTRIBUTION:-ubuntu}"
23SERIES="${SERIES:-vivid}"23DEFAULT_SERIES=vivid
24SERIES="${SERIES:-$DEFAULT_SERIES}"
2425
25# DATE26# DATE
26NOW=`date +"%F/%T" -u`27NOW=`date +"%F/%T" -u`
@@ -162,7 +163,14 @@
162fi163fi
163164
164blocks () {165blocks () {
166 local tags
167 [ "$DISTRIBUTION" = ubuntu ] || return
165 mkdir -p "$1/$SERIES-proposed"168 mkdir -p "$1/$SERIES-proposed"
169 if [ "$SERIES" = "$DEFAULT_SERIES" ]; then
170 tags="block-proposed block-proposed-$SERIES"
171 else
172 tags="block-proposed-$SERIES"
173 fi
166 python -c '174 python -c '
167from __future__ import print_function175from __future__ import print_function
168176
@@ -190,8 +198,8 @@
190198
191launchpad = Launchpad.login_with("proposed-migration", sys.argv[1])199launchpad = Launchpad.login_with("proposed-migration", sys.argv[1])
192distro = launchpad.distributions[sys.argv[2]]200distro = launchpad.distributions[sys.argv[2]]
193tag = "block-proposed"201tags = sys.argv[3].split()
194for task in distro.searchTasks(omit_targeted=False, tags=tag):202for task in distro.searchTasks(omit_targeted=False, tags=tags):
195 target = task.target203 target = task.target
196 bug = task.bug204 bug = task.bug
197 if urlsplit(target.resource_type_link).fragment in (205 if urlsplit(target.resource_type_link).fragment in (
@@ -200,7 +208,12 @@
200 [a for a in bug.activity if a.whatchanged == "tags"]):208 [a for a in bug.activity if a.whatchanged == "tags"]):
201 oldtags = action.oldvalue.split()209 oldtags = action.oldvalue.split()
202 newtags = action.newvalue.split()210 newtags = action.newvalue.split()
203 if tag not in oldtags and tag in newtags:211 gained_block = False
212 for tag in tags:
213 if tag not in oldtags and tag in newtags:
214 gained_block = True
215 break
216 if gained_block:
204 date = action.datechanged217 date = action.datechanged
205 break218 break
206 else:219 else:
@@ -208,7 +221,7 @@
208 print("%s %d %d" %221 print("%s %d %d" %
209 (os.path.basename(target.self_link), bug.id,222 (os.path.basename(target.self_link), bug.id,
210 calendar.timegm(date.timetuple())))223 calendar.timegm(date.timetuple())))
211' "$LP_SERVICE" "$DISTRIBUTION" >"$1/$SERIES-proposed/Blocks.new"224' "$LP_SERVICE" "$DISTRIBUTION" "$tags" >"$1/$SERIES-proposed/Blocks.new"
212 mv "$1/$SERIES-proposed/Blocks.new" "$1/$SERIES-proposed/Blocks"225 mv "$1/$SERIES-proposed/Blocks.new" "$1/$SERIES-proposed/Blocks"
213}226}
214if option blocks; then227if option blocks; then
@@ -283,12 +296,14 @@
283 if [ "$DISTRIBUTION" = ubuntu ]; then296 if [ "$DISTRIBUTION" = ubuntu ]; then
284 if [ -d $DATA_B2/$SERIES-proposed/Hints ]; then297 if [ -d $DATA_B2/$SERIES-proposed/Hints ]; then
285 bzr pull -q -d $DATA_B2/$SERIES-proposed/Hints298 bzr pull -q -d $DATA_B2/$SERIES-proposed/Hints
286 else299 elif [ "$SERIES" = "$DEFAULT_SERIES" ]; then
287 bzr branch lp:~ubuntu-release/britney/hints-ubuntu $DATA_B2/$SERIES-proposed/Hints300 bzr branch lp:~ubuntu-release/britney/hints-ubuntu $DATA_B2/$SERIES-proposed/Hints
301 else
302 bzr branch lp:~ubuntu-sru/britney/hints-ubuntu-$SERIES $DATA_B2/$SERIES-proposed/Hints
288 fi303 fi
289 if [ -d $DATA_B2/$SERIES-proposed/Hints/ubuntu-touch ]; then304 if [ -d $DATA_B2/$SERIES-proposed/Hints/ubuntu-touch ]; then
290 bzr pull -q -d $DATA_B2/$SERIES-proposed/Hints/ubuntu-touch305 bzr pull -q -d $DATA_B2/$SERIES-proposed/Hints/ubuntu-touch
291 else306 elif [ "$SERIES" = "$DEFAULT_SERIES" ]; then
292 bzr branch lp:~ubuntu-touch-release/britney/hints-ubuntu-touch $DATA_B2/$SERIES-proposed/Hints/ubuntu-touch307 bzr branch lp:~ubuntu-touch-release/britney/hints-ubuntu-touch $DATA_B2/$SERIES-proposed/Hints/ubuntu-touch
293 fi308 fi
294 elif [ "$DISTRIBUTION" = ubuntu-rtm ]; then309 elif [ "$DISTRIBUTION" = ubuntu-rtm ]; then

Subscribers

People subscribed via source and target branches