Skip to content

Skip benchmark job on fork PRs#1094

Open
keyboardDrummer-bot wants to merge 1 commit intostrata-org:mainfrom
keyboardDrummer-bot:fix/skip-benchmarks-on-forks
Open

Skip benchmark job on fork PRs#1094
keyboardDrummer-bot wants to merge 1 commit intostrata-org:mainfrom
keyboardDrummer-bot:fix/skip-benchmarks-on-forks

Conversation

@keyboardDrummer-bot
Copy link
Copy Markdown
Collaborator

Summary

Skip the strata-benchmarks CI job on pull requests from forks.

Problem

The benchmark job uses secrets.AWS_BENCHMARK_ACCOUNT to assume an IAM role and trigger AWS CodeBuild. This secret is not available to workflows running on fork PRs, causing the job to always fail for external contributors.

Fix

Add a job-level if condition that skips the benchmark job when the PR comes from a fork:

if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository

This means:

  • push to main: runs (secrets available)
  • merge_group: runs (secrets available)
  • Same-repo PR: runs (secrets available)
  • Fork PR: skipped (secrets unavailable)

Requested in keyboardDrummer#7 (comment)

The strata-benchmarks job requires secrets.AWS_BENCHMARK_ACCOUNT which
is not available on pull requests from forks. Add a condition to skip
the job when the PR originates from a different repository.
@keyboardDrummer keyboardDrummer requested a review from aqjune-aws May 1, 2026 10:37
@keyboardDrummer keyboardDrummer marked this pull request as ready for review May 1, 2026 10:37
@keyboardDrummer keyboardDrummer requested a review from a team May 1, 2026 10:37
Copy link
Copy Markdown
Contributor

@robin-aws robin-aws left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to ensure the benchmark job is run before anything's merged. We're documenting the process for contributors in https://github.com/strata-org/Strata/pull/1086/changes instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github_actions Pull requests that update GitHub Actions code Has 1 approval

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants