Skip to content

[CI] Parity: include PR head SHA in run name for PR-triggered runs#3389

Open
ethanwee1 wants to merge 1 commit into
ROCm:developfrom
ethanwee1:ethanwee/parity-pr-runname-sha
Open

[CI] Parity: include PR head SHA in run name for PR-triggered runs#3389
ethanwee1 wants to merge 1 commit into
ROCm:developfrom
ethanwee1:ethanwee/parity-pr-runname-sha

Conversation

@ethanwee1

Copy link
Copy Markdown

Summary

PR-triggered parity runs currently show only PR <id> · <archs> in the Actions run list (e.g. this run reads PR 187011 · mi200), which makes it hard to tell which upstream commit was actually tested. This adds the resolved PR head SHA so the run name reads:

PR 187011 · 99cb7e843ec2c2afd680b3804dbf7d9c4498e4f5 · mi200

How

run-name is evaluated once when the run starts and can only read the inputs/github contexts, so it cannot include the SHA that download_testlogs resolves later from --pr_id. Instead, setup-matrix now resolves the PR head SHA (repos/pytorch/pytorch/pulls/<id>) and PATCHes the run name via the REST API (PATCH /repos/{owner}/{repo}/actions/runs/{run_id}).

  • Only applies to PR-triggered runs (inputs.pr_id set, no baseline_sha/csv_name); other run names are unchanged.
  • The pr_id → sha lookup is intentionally duplicated here — download_testlogs keeps its own get_latest_commit_sha so it can still be run standalone with just --pr_id.
  • Adds actions: write to the setup-matrix job (required for the run-name PATCH).
  • No-ops gracefully (leaves the run name unchanged) if the SHA can't be resolved.

Test plan

  • Dispatch a PR-triggered parity run and confirm the run name updates to PR <id> · <sha> · <archs> shortly after start.
  • Dispatch a SHA-triggered / autoparity run and confirm its run name is unchanged.
  • Validation run: to be linked

run-name is evaluated once when the run starts, so it cannot include the
commit SHA that download_testlogs resolves later from --pr_id. For
PR-triggered runs, resolve the PR head SHA in setup-matrix and PATCH the
run name via the REST API so it reads "PR <id> . <sha> . <archs>".

The PR->SHA lookup is intentionally duplicated here (download_testlogs
keeps get_latest_commit_sha so the script can still run standalone with
just --pr_id). Adds actions:write to the setup-matrix job for the PATCH.
@ethanwee1 ethanwee1 force-pushed the ethanwee/parity-pr-runname-sha branch from b4abdec to 8ddc477 Compare July 1, 2026 21:55
@rocm-repo-management-api

rocm-repo-management-api Bot commented Jul 1, 2026

Copy link
Copy Markdown

Jenkins build for 8ddc477e7a3d750f828cdc1f7468b2f054aa626e commit finished as FAILURE
Links: Pipeline Overview / Build artifacts / Test Results

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant