mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-07 18:04:46 +00:00
Bug 1384729 - Move actions into taskgraph dir r=dustin
MozReview-Commit-ID: HK5MR8Xw3On --HG-- rename : taskcluster/actions/__init__.py => taskcluster/taskgraph/actions/__init__.py rename : taskcluster/actions/add-new-jobs.py => taskcluster/taskgraph/actions/add-new-jobs.py rename : taskcluster/actions/hello-action.py => taskcluster/taskgraph/actions/hello-action.py rename : taskcluster/actions/registry.py => taskcluster/taskgraph/actions/registry.py rename : taskcluster/actions/retrigger.py => taskcluster/taskgraph/actions/retrigger.py rename : taskcluster/actions/run_missing_tests.py => taskcluster/taskgraph/actions/run_missing_tests.py rename : taskcluster/actions/test-retrigger-action.py => taskcluster/taskgraph/actions/test-retrigger-action.py rename : taskcluster/actions/util.py => taskcluster/taskgraph/actions/util.py extra : source : 9368bd8045136706950cde7cf718fda5492499e8 extra : histedit_source : f52597f12cb247124ee6080241ac9c741fc53e49
This commit is contained in:
parent
6389867b7c
commit
257aa1c23c
@ -294,7 +294,7 @@ class MachCommands(MachCommandBase):
|
||||
@SubCommand('taskgraph', 'action-callback',
|
||||
description='Run action callback used by action tasks')
|
||||
def action_callback(self, **options):
|
||||
import actions
|
||||
import taskgraph.actions
|
||||
try:
|
||||
self.setup_logging()
|
||||
|
||||
@ -305,7 +305,7 @@ class MachCommands(MachCommandBase):
|
||||
callback = os.environ.get('ACTION_CALLBACK', None)
|
||||
parameters = json.loads(os.environ.get('ACTION_PARAMETERS', '{}'))
|
||||
|
||||
return actions.trigger_action_callback(
|
||||
return taskgraph.actions.trigger_action_callback(
|
||||
task_group_id=task_group_id,
|
||||
task_id=task_id,
|
||||
task=task,
|
||||
@ -336,7 +336,7 @@ class MachCommands(MachCommandBase):
|
||||
def test_action_callback(self, **options):
|
||||
import taskgraph.parameters
|
||||
from taskgraph.util.taskcluster import get_task_definition
|
||||
import actions
|
||||
import taskgraph.actions
|
||||
import yaml
|
||||
|
||||
def load_data(filename):
|
||||
@ -366,7 +366,7 @@ class MachCommands(MachCommandBase):
|
||||
parameters = taskgraph.parameters.load_parameters_file(options['parameters'])
|
||||
parameters.check()
|
||||
|
||||
return actions.trigger_action_callback(
|
||||
return taskgraph.actions.trigger_action_callback(
|
||||
task_group_id=options['task_group_id'],
|
||||
task_id=task_id,
|
||||
task=task,
|
||||
|
@ -7,9 +7,6 @@
|
||||
with Files('**'):
|
||||
BUG_COMPONENT = ('Taskcluster', 'General')
|
||||
|
||||
with Files('actions/**'):
|
||||
BUG_COMPONENT = ('Taskcluster', 'Task Configuration')
|
||||
|
||||
with Files('ci/**'):
|
||||
BUG_COMPONENT = ('Taskcluster', 'Task Configuration')
|
||||
|
||||
|
@ -1,7 +1,15 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# 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_callback_action
|
||||
from slugid import nice as slugid
|
||||
|
||||
from actions.util import create_task
|
||||
from .util import create_task
|
||||
from taskgraph.util.taskcluster import get_artifact
|
||||
from taskgraph.util.parameterization import resolve_task_references
|
||||
from taskgraph.taskgraph import TaskGraph
|
@ -15,7 +15,7 @@ from types import FunctionType
|
||||
from collections import namedtuple
|
||||
from taskgraph.util.docker import docker_image
|
||||
from taskgraph.parameters import Parameters
|
||||
from actions import util
|
||||
from . import util
|
||||
|
||||
|
||||
GECKO = os.path.realpath(os.path.join(__file__, '..', '..', '..'))
|
||||
@ -318,8 +318,8 @@ def _load():
|
||||
# Load all modules from this folder, relying on the side-effects of register_
|
||||
# functions to populate the action registry.
|
||||
for f in os.listdir(os.path.dirname(__file__)):
|
||||
if f.endswith('.py') and f not in ('__init__.py', 'registry.py'):
|
||||
__import__('actions.' + f[:-3])
|
||||
if f.endswith('.py') and f not in ('__init__.py', 'registry.py', 'util.py'):
|
||||
__import__('taskgraph.actions.' + f[:-3])
|
||||
return callbacks, actions
|
||||
|
||||
|
@ -1,4 +1,12 @@
|
||||
from registry import register_task_action
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# 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
|
||||
|
||||
|
||||
@register_task_action(
|
@ -10,7 +10,7 @@ import logging
|
||||
from slugid import nice as slugid
|
||||
|
||||
from .registry import register_callback_action
|
||||
from actions.util import create_task, find_decision_task
|
||||
from .util import create_task, find_decision_task
|
||||
from taskgraph.util.taskcluster import get_artifact
|
||||
from taskgraph.util.parameterization import resolve_task_references
|
||||
from taskgraph.taskgraph import TaskGraph
|
@ -1,3 +1,11 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# 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
|
||||
|
||||
import copy
|
||||
import json
|
||||
import logging
|
@ -1,3 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# 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/.
|
@ -17,7 +17,7 @@ from .generator import TaskGraphGenerator
|
||||
from .create import create_tasks
|
||||
from .parameters import Parameters
|
||||
from .taskgraph import TaskGraph
|
||||
from actions import render_actions_json
|
||||
from .actions import render_actions_json
|
||||
from . import GECKO
|
||||
|
||||
from taskgraph.util.templates import Templates
|
||||
|
Loading…
Reference in New Issue
Block a user