feat(quartz): notify_quartz reusable workflow + dispatcher#75
Closed
cgoea wants to merge 1 commit into
Closed
Conversation
# Summary First step of porting the Quartz CI-reporting scripts from ROCm/Quartz-Tester into TheRock. This adds the self-report bridge that lets a TheRock workflow push its run status to Quartz for ingestion. - **`.github/workflows/notify_quartz.yml`** (new): reusable `workflow_call` workflow. Mints a Quartz Hauly GitHub App token and invokes the dispatcher. `continue-on-error: true` so reporting never fails the calling workflow. - **`build_tools/github_actions/notify_quartz.py`** (new): stdlib-only dispatcher. Builds a payload for the current run (resolved via `GITHUB_RUN_ID` + the Actions API) and dispatches it to a Quartz ingest workflow via `workflow_dispatch`, at run start (`run_phase=started`) and end (`run_phase=completed`). Derives the run conclusion from a `toJSON(needs)` blob when no explicit conclusion is passed, and strips the inline `jobs` array (setting `fetch_jobs`) when the payload would exceed GitHub's 65,535-char dispatch-inputs cap. Targets `ROCm/Quartz` by default (override with `--quartz-repo` / `QUARTZ_REPO`). - **`build_tools/github_actions/tests/notify_quartz_test.py`** (new): stdlib `unittest` coverage for the dispatcher's pure logic: reporting-path normalization (`_normalize_reporting_path`) and payload path overrides (`_build_payload`). Runs standalone, no network or GitHub API needed. Copied from Quartz-Tester `main` except the pinned action SHAs, which were bumped to match TheRock's current pins (`actions/checkout` v6.0.3, `actions/create-github-app-token` v3.2.0), and the default ingest target, which was switched from ROCm/Quartz-Tester to ROCm/Quartz. ## References - ROCm/Quartz#17 - RFC: [RFC0011-Quartz-CICD-Datahub.md](https://github.com/ROCm/TheRock/blob/main/docs/rfcs/RFC0011-Quartz-CICD-Datahub.md), background on what Quartz is and why we report CI/CD data to it. - [Quartz Implementation Plan](https://github.com/orgs/ROCm/projects/156), the issue tracker. Note: it's not fully up to date. ## Notes - These files are **standalone**; they only become active once `notify_quartz` jobs are actually added to the workflows (a follow-up). - Requires repo secrets `GH_APP_HAULY_ID` / `GH_APP_HAULY_PRIVATE_KEY` (Quartz Hauly GitHub App), already installed in TheRock. --------- Co-authored-by: Ciprian Goea <ciprian.goea@amd.com>
HereThereBeDragons
force-pushed
the
users/cgoea/notify_quartz
branch
from
July 16, 2026 10:07
b08c4b0 to
7497277
Compare
Contributor
|
just a plain cherry pick of ROCm/TheRock@60c2a4f |
marbre
reviewed
Jul 16, 2026
| ): | ||
| return _build_payload( | ||
| token="t", | ||
| repo="ROCm/rockrel", |
Member
There was a problem hiding this comment.
Should this have been ROCm/TheRock in our TheRock repository? Here rockrel is fine for sure, just noticed as you said it is a 1:1 port.
Member
There was a problem hiding this comment.
If this is a copy and also duplicates notify_quartz.py as well as the test, why don't we call into ROCm/TheRock/.github/workflows/notify_quartz.yml@main instead of duplicating?
Contributor
There was a problem hiding this comment.
right let me rework. might have been too naive to just cherry pick it
Member
There was a problem hiding this comment.
Okay, please re-request a review once you have it. Should be a quite little PR in the end.
Contributor
|
closing. will reuse the notify_quartz code from therock |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cherry-pick of ROCm/TheRock@60c2a4f
Summary
First step of porting the Quartz CI-reporting scripts from ROCm/Quartz-Tester
into TheRock. This adds the self-report bridge that lets a TheRock workflow
push its run status to Quartz for ingestion.
.github/workflows/notify_quartz.yml(new): reusableworkflow_callworkflow. Mints a Quartz Hauly GitHub App token and invokes the dispatcher.
continue-on-error: trueso reporting never fails the calling workflow.build_tools/github_actions/notify_quartz.py(new): stdlib-onlydispatcher. Builds a payload for the current run (resolved via
GITHUB_RUN_ID+ the Actions API) and dispatches it to a Quartz ingestworkflow via
workflow_dispatch, at run start (run_phase=started) andend (
run_phase=completed). Derives the run conclusion from atoJSON(needs)blob when no explicit conclusion is passed, and strips theinline
jobsarray (settingfetch_jobs) when the payload would exceedGitHub's 65,535-char dispatch-inputs cap. Targets
ROCm/Quartzby default(override with
--quartz-repo/QUARTZ_REPO).build_tools/github_actions/tests/notify_quartz_test.py(new): stdlibunittestcoverage for the dispatcher's pure logic: reporting-pathnormalization (
_normalize_reporting_path) and payload path overrides(
_build_payload). Runs standalone, no network or GitHub API needed.Copied from Quartz-Tester
mainexcept the pinned action SHAs, which werebumped to match TheRock's current pins (
actions/checkoutv6.0.3,actions/create-github-app-tokenv3.2.0), and the default ingest target,which was switched from ROCm/Quartz-Tester to ROCm/Quartz.
References
background on what Quartz is and why we report CI/CD data to it.
date.
Notes
notify_quartzjobs are actually added to the workflows (a follow-up).GH_APP_HAULY_ID/GH_APP_HAULY_PRIVATE_KEY(Quartz Hauly GitHub App), already installed in TheRock.
Co-authored-by: Laura Promberger Laura.Promberger@amd.com