Conversation
…publish merge The post-publish merge warning always assumed merge conflicts, even when the real cause was an expired GitHub App token (common for publishes exceeding the 1-hour token lifetime, e.g. sentry-native). Add an isAuthError() helper that pattern-matches git credential errors and use it to provide an accurate diagnosis in the warning message.
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
…or/PushError Classify errors deterministically by WHERE they occur in handleReleaseBranch, not by pattern-matching the message: - Merge fails (both ort + resolve strategies): throws MergeConflictError with the list of conflicted files from git status - Push fails after successful merge: throws PushError The caller uses instanceof to provide targeted diagnostics: - MergeConflictError: lists the conflicting files - PushError: explains the merge succeeded but push failed (likely expired token)
Capture git diff of conflicted files before aborting the failed merge. The diff shows the actual conflict markers (<<<<<<< / ======= / >>>>>>>) so operators can see exactly what conflicted without having to reproduce the merge locally.
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
isAuthError()helper that detects git authentication failures (expired tokens, credential prompting errors, HTTP 401/403) vs merge conflictsContext
The post-publish merge warning always blamed merge conflicts, even when the actual cause was an expired GitHub App token — common for publishes exceeding the 1-hour token lifetime (e.g., sentry-native's ~1h 23m publish). The misleading message made it harder to diagnose what went wrong.
The publish itself succeeds in these cases — only the housekeeping merge step fails. This change improves the diagnostic message so operators can quickly identify token expiration vs actual merge conflicts.