Skip to content

prevent stale PR events from overwriting deploy state - #236

Merged
vmelikyan merged 1 commit into
mainfrom
gh-webhook-deploy-state-race
Aug 18, 2026
Merged

prevent stale PR events from overwriting deploy state#236
vmelikyan merged 1 commit into
mainfrom
gh-webhook-deploy-state-race

Conversation

@vmelikyan

Copy link
Copy Markdown
Contributor

A delayed synchronize webhook could arrive after a label event and overwrite the PR’s current labels and deployOnUpdate state using stale payload data. This incorrectly disabled subsequent deployments.
This change limits deploy-state updates to PR open, reopen, and close events. Label changes remain owned by the labeled/unlabeled webhook handler, while synchronize and other generic PR events only update metadata.
Regression tests cover delayed synchronize/edited events and preserve reopen and close behavior.

@vmelikyan
vmelikyan requested a review from a team as a code owner August 14, 2026 15:33
@vmelikyan
vmelikyan merged commit 42cffcd into main Aug 18, 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.

1 participant