👷 ci(schemastore): fix update workflow auth and PR creation#3826
Merged
gaborbernat merged 1 commit intotox-dev:mainfrom Feb 25, 2026
Merged
👷 ci(schemastore): fix update workflow auth and PR creation#3826gaborbernat merged 1 commit intotox-dev:mainfrom
gaborbernat merged 1 commit intotox-dev:mainfrom
Conversation
The GH_TOKEN env var is only used by gh CLI natively, not by raw git commands. The git push to the SchemaStore fork fails because HTTPS credentials aren't configured. Adding gh auth setup-git registers gh as a git credential helper, bridging the authentication gap.
gaborbernat
added a commit
to gaborbernat/tox
that referenced
this pull request
Feb 25, 2026
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.
The update-schemastore workflow fails in two ways when triggered by a release tag. First,
git pushcouldn't authenticate becauseGH_TOKENis only consumed byghCLI, not raw git HTTPS operations. Second,gh pr create --repo SchemaStore/schemastorefails with "you must first push the current branch to a remote, or use the --head flag" because it can't infer which fork owns the branch when targeting an upstream repo.The fix uses
gh auth setup-gitto registerghas a git credential helper (bridging the auth gap forgit push), and dynamically resolves the fork owner viagh api userto pass--head <owner>:<branch>explicitly to bothgh pr createandgh pr view/gh pr edit.