Skip to content

Move pull request dashboard rendering to publish#58

Merged
trask merged 1 commit into
open-telemetry:mainfrom
trask:pull-request-dashboard-render-on-publish
Jul 9, 2026
Merged

Move pull request dashboard rendering to publish#58
trask merged 1 commit into
open-telemetry:mainfrom
trask:pull-request-dashboard-render-on-publish

Conversation

@trask

@trask trask commented Jul 8, 2026

Copy link
Copy Markdown
Member

Addressing some sporadic failures, e.g. https://github.com/open-telemetry/shared-workflows/actions/runs/28976742994/job/85990708996

Move pull request dashboard markdown rendering out of state update jobs and into the publish job. Dashboard updates now push structured state only, while publishing renders from accepted dashboard state plus the current open PR list, reducing targeted refresh work under state-branch CAS retries.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR restructures the pull-request-dashboard workflow so that markdown rendering happens in the publish-dashboard job rather than in the state-update jobs. State-update jobs now push only structured state (dashboard-state.json), while the publish job re-derives the issue body from accepted state plus the target repository's current open PR list. This makes state-branch compare-and-swap (CAS) retries cheaper: targeted PR retries reuse the already-computed PR result and only re-run the latest-state merge and save, instead of re-rendering the whole dashboard.

Changes:

  • Moved rendering (render_pr_tables, dashboard_markdown_path writing, and the LARGE_REPO_MAX_ROWS_PER_SECTION/--large-repo preset) out of dashboard.py into publish_dashboard.py's new render_dashboard_markdown.
  • Refactored dashboard.py update paths to save state only, splitting the old render_and_save_dashboard into save_dashboard_update_state + reject_failed_dashboard_result, and hoisting the expensive targeted-PR computation out of the CAS retry loop (build_targeted_dashboard_update / apply_targeted_dashboard_update).
  • Updated the workflow: --large-repo and permission-pull-requests: read moved to the publish job, and the publish job's cancel-in-progress set to true so newer publishes supersede older ones.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
.github/workflows/pull-request-dashboard-repo.yml Moves --large-repo to publish, adds permission-pull-requests: read for PR listing at publish, sets publish cancel-in-progress: true.
.github/scripts/pull-request-dashboard/publish_dashboard.py Adds render_dashboard_markdown and --large-repo; publish now renders from accepted state + open PRs before editing the issue.
.github/scripts/pull-request-dashboard/dashboard.py Removes in-update rendering; refactors save/failure logic and moves targeted-PR computation outside the CAS retry loop.
.github/scripts/pull-request-dashboard/RATIONALE.md Documents the render-at-publish model and cheaper CAS retry semantics.

I reviewed the refactor closely, including the equivalence of the new reject_failed_dashboard_result (trigger-only) check versus the previous all-results check, the preserved draft/closed-PR removal behavior via merge_dashboard_update_with_latest_state, the removal of now-unused imports/parameters, and the new concurrency semantics. I did not find blocking correctness issues, and there are no automated Python tests in this directory, so no test-coverage feedback applies. However, the change alters production workflow concurrency behavior (cancel-in-progress: true) and non-trivial CAS retry/state-management control flow across coordinated jobs, which is operationally sensitive and warrants human verification.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@trask trask marked this pull request as ready for review July 8, 2026 23:13
@trask trask requested a review from a team as a code owner July 8, 2026 23:13
@trask trask merged commit 5513404 into open-telemetry:main Jul 9, 2026
5 checks passed
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.

3 participants