Skip to content
This repository has been archived by the owner on Dec 15, 2018. It is now read-only.

Commit

Permalink
Pass in debug config for all auto-bazel jobsteps.
Browse files Browse the repository at this point in the history
Reviewers: kylec, naphat

Reviewed By: naphat

Subscribers: changesbot, wwu, naphat

Differential Revision: https://tails.corp.dropbox.com/D231924
  • Loading branch information
Anup Chenthamarakshan committed Sep 27, 2016
1 parent d01ccbc commit 99e9085
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions changes/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -462,6 +462,9 @@ def create_app(_read_config=True, **config):

app.config['SELECTIVE_TESTING_PROPAGATION_LIMIT'] = 30

# Debug config entries passed to every autobazel jobstep
app.config['BAZEL_DEBUG_CONFIG'] = {}

# Jobsteps go from 'pending_allocation' to 'allocated' once an external scheduler claims them, and
# once they begin running they're updated to 'in_progress'. If the scheduler somehow fails or drops
# the task, this value is used to time out the 'allocated' status and revert back to 'pending_allocation'.
Expand Down
4 changes: 4 additions & 0 deletions changes/models/jobplan.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,9 @@ def get_build_step_for_job(cls, job_id):
bazel_test_flags = current_app.config['BAZEL_MANDATORY_TEST_FLAGS'] + additional_test_flags
bazel_test_flags = list(OrderedDict([(b, None) for b in bazel_test_flags])) # ensure uniqueness, preserve order

# TODO(anupc): Does it make sense to expose this in project config?
bazel_debug_config = current_app.config['BAZEL_DEBUG_CONFIG']

vcs = job.project.repository.get_vcs()
implementation = LXCBuildStep(
cluster=current_app.config['DEFAULT_CLUSTER'],
Expand Down Expand Up @@ -259,6 +262,7 @@ def get_build_step_for_job(cls, job_id):
cpus=bazel_cpus,
memory=bazel_memory,
max_executors=bazel_max_executors,
debug_config=bazel_debug_config,
)
return jobplan, implementation

Expand Down

0 comments on commit 99e9085

Please sign in to comment.