Closed Bug 1391417 Opened 4 years ago Closed 4 years ago
update retrigger to be like the rest of the actions
59 bytes, text/x-review-board-request
No description provided.
Comment on attachment 8898542 [details] Bug 1391417 - Make retrigger act like it does in mozilla-taskcluster https://reviewboard.mozilla.org/r/169900/#review175506 ::: taskcluster/taskgraph/actions/retrigger.py:9 (Diff revision 1) > # License, v. 2.0. If a copy of the MPL was not distributed with this > # file, You can obtain one at http://mozilla.org/MPL/2.0/. > > from __future__ import absolute_import, print_function, unicode_literals > > -from .registry import register_task_action > +from .util import (create_tasks, find_decision_task) nit, add newlines ``` from .util import ( .. ) ``` ::: taskcluster/taskgraph/actions/retrigger.py:51 (Diff revision 1) > + label = task['metadata']['name'] > + to_run = [label] > + > + if input.get('downstream'): > + to_run = full_task_graph.graph.transitive_closure(set(to_run), reverse=True).nodes > + to_run = to_run & set(target_tasks) I'm a bit confused about this. `target_tasks` is the set of targetted labels, but *without* its transitive closure. So this intersection may remove tasks that need to be re-run. I think the idea here is to limit the re-running to tasks that were actually created in the first place? Probably the easiest way to do that it is to intersect with `label_to_taskid`, which contains only labels that were created in the original decision task. More formally, you'd want to intersect `to_run` with the labels in hte optimized task graph, but I think `label_to_taskid` is close enough. ::: taskcluster/taskgraph/graph.py:62 (Diff revision 1) > + `-------> d > + > + transitive_closure([b]).nodes == set([a, b]) > + transitive_closure([c]).nodes == set([c, b, a]) > + transitive_closure([c], reverse=True).nodes == set([c]) > + transitive_closure([b], reverse=True).nodes == set([c, d]) ++ ++
Attachment #8898542 - Flags: review?(dustin) → review-
Comment on attachment 8898542 [details] Bug 1391417 - Make retrigger act like it does in mozilla-taskcluster https://reviewboard.mozilla.org/r/169900/#review175540
Attachment #8898542 - Flags: review?(dustin) → review+
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/autoland/rev/16562a4d1424 Make retrigger act like it does in mozilla-taskcluster r=dustin
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla57
You need to log in before you can comment on or make changes to this bug.