fix(ci): fix workflow checkout ordering, refactor drift detection#150
Merged
Conversation
Move checkout step before create-github-app-token so the repo (and local slack-post action) is always available, even when token generation fails. Configure the git remote URL with the app token after checkout instead of passing it to the checkout action. Remove `npm install -g npm@latest` from release workflow — Node 22 ships with npm 10.x which already supports OIDC provenance publishing.
Replace the two bash steps (run + parse) with a single actions/github-script@v7 step that runs the drift detection script, parses the JSON output, and validates the report before alerting. Key changes: - Use report.hasDrift boolean instead of manual totalDrift checks - Validate report structure before sending Slack alerts - Add script error alert for non-zero exits with invalid output - Add 2-minute timeout to prevent hung runners
nastassiafulconis
approved these changes
Apr 14, 2026
Collaborator
nastassiafulconis
left a comment
There was a problem hiding this comment.
makes sense to me!
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.
Summary
Two sets of fixes for CI workflow reliability:
Workflow checkout ordering (release.yml, regenerate-schemas.yml)
The
actions/checkoutstep was dependent oncreate-github-app-token, meaning if the token step failed, checkout was skipped and the local.github/actions/slack-postcomposite action was unavailable for failure notifications. This created a silent failure mode where we'd get no Slack alert on token errors.release.ymlandregenerate-schemas.ymlgit remote set-url, preserving the app identity for pushesnpm install -g npm@latestfromrelease.yml— Node 22 ships with npm 10.x which already supports OIDC provenance publishing, and the self-update was failing with apromise-retryMODULE_NOT_FOUND errorDrift detection refactor (drift-detection.yml)
The drift detection workflow was sending empty Slack alerts when the script exited non-zero but produced no valid drift data (e.g. script error misinterpreted as drift). The bash/jq parsing logic had grown complex across two steps.
actions/github-script@v7stepreport.hasDriftboolean from the script output instead of manualtotalDriftstring comparisonsTest plan