Skip to content

[SPARK-57124][INFRA] Fix update_build_status.yml to map non-standard workflow run statuses#56177

Closed
dongjoon-hyun wants to merge 1 commit into
apache:masterfrom
dongjoon-hyun:SPARK-57124
Closed

[SPARK-57124][INFRA] Fix update_build_status.yml to map non-standard workflow run statuses#56177
dongjoon-hyun wants to merge 1 commit into
apache:masterfrom
dongjoon-hyun:SPARK-57124

Conversation

@dongjoon-hyun
Copy link
Copy Markdown
Member

@dongjoon-hyun dongjoon-hyun commented May 28, 2026

What changes were proposed in this pull request?

This PR fixes the update_build_status.yml so that it coerces non-standard workflow run statuses (requested, waiting, pending) to a value accepted by the PATCH /repos/{owner}/{repo}/check-runs/{check_run_id} endpoint.

The else branch now maps run.data.status to either in_progress (when it is exactly in_progress) or queued (for any other non-completed value), instead of passing the raw value through.

Why are the changes needed?

The scheduled job has been failing intermittently with HTTP 422.

Screenshot 2026-05-27 at 21 31 50

For example, run 26552065653 failed with:

Run 78216352873: set status (pending)
RequestError [HttpError]: Invalid request.
  No subschema in "anyOf" matched.
  pending is not a member of ["queued", "in_progress", "completed"].

GET /repos/{owner}/{repo}/actions/runs/{run_id} can return any of completed, in_progress, queued, requested, waiting, or pending, while PATCH /check-runs/{id} only accepts queued, in_progress, or completed. Forwarding the raw value caused the workflow to crash whenever a fork's run was in pending (or requested/waiting) state, and the corresponding PR check-runs were not synchronized for that cycle.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

Manual review of the workflow script. The change is limited to mapping a string value before passing it to the GitHub REST API; behavior for the existing completed and in_progress paths is unchanged.

Was this patch authored or co-authored using generative AI tooling?

Generated-by: Claude Opus 4.7

@dongjoon-hyun
Copy link
Copy Markdown
Member Author

cc @HyukjinKwon, @viirya , @peter-toth

Copy link
Copy Markdown
Member

@viirya viirya left a comment

Choose a reason for hiding this comment

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

Small, safe, well-explained infra fix with the right blast radius. +1.

@dongjoon-hyun
Copy link
Copy Markdown
Member Author

Thank you, @viirya .

@dongjoon-hyun
Copy link
Copy Markdown
Member Author

Merged to master to fix the infra flakiness.

@dongjoon-hyun dongjoon-hyun deleted the SPARK-57124 branch May 28, 2026 05:28
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.

2 participants