Skip to content

Commit

Permalink
Rollup merge of rust-lang#128227 - Kobzol:ci-unrolled-perf-build-matr…
Browse files Browse the repository at this point in the history
…ix, r=tgross35

CI: do not respect custom try jobs for unrolled perf builds

Before this PR, if a pull request merged in a rollup had some `try-job` annotations, the unrolled perf builds were running the custom try jobs instead of the default job, which was wrong.

Found out [here](https://rust-lang.zulipchat.com/#narrow/stream/242791-t-infra/topic/try-perf.20jobs.20respect.20try-job.20annotations).
  • Loading branch information
tgross35 authored Jul 26, 2024
2 parents 436d6aa + 114e0dc commit caa64a5
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/ci/github-actions/calculate-job-matrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,15 @@ def find_run_type(ctx: GitHubCtx) -> Optional[WorkflowRunType]:
"refs/heads/automation/bors/try"
)

# Unrolled branch from a rollup for testing perf
# This should **not** allow custom try jobs
is_unrolled_perf_build = ctx.ref == "refs/heads/try-perf"

if try_build:
jobs = get_custom_jobs(ctx)
return TryRunType(custom_jobs=jobs)
custom_jobs = []
if not is_unrolled_perf_build:
custom_jobs = get_custom_jobs(ctx)
return TryRunType(custom_jobs=custom_jobs)

if ctx.ref == "refs/heads/auto":
return AutoRunType()
Expand Down

0 comments on commit caa64a5

Please sign in to comment.