Repository navigation
fix: make GeoLite update workflow rerun-safe and fix shell quoting - #501
Merged
abhalsod-sonata merged 1 commit intoOct 8, 2026
Merged
Conversation
- Add github.run_attempt to the generated branch name so re-running a failed run does not collide with the branch pushed by the earlier attempt. - Write the no-change summary to the real $GITHUB_STEP_SUMMARY file instead of a file literally named '$GITHUB_STEP_SUMMARY'. - Escape the backticks in the PR body so bash does not run the workflow name as a command. - Quote $PR_URL in the job summary check so an empty URL is detected. LP-1331
abhalsod-sonata
requested review from
a team,
hiteshkava,
naincy128,
rahulkanneri-2u and
vgulati-apphelix
October 6, 2026 10:54
hiteshkava
approved these changes
Oct 6, 2026
rahulkanneri-2u
approved these changes
Oct 6, 2026
abhalsod-sonata
marked this pull request as draft
October 7, 2026 10:31
Member
Author
|
Converting to draft to hold the merge until the GitHub App secrets for #508 are in place (DOS-7368). Merge order
The two PRs touch different lines and don't conflict. After both are merged, one manual run of the workflow verifies both changes. I'll mark this ready for review once DOS-7368 is done. |
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.
Description
Hardening fixes for
.github/workflows/update-geolite-database.yml. The October scheduled run (36809399679) failed, and the rerun exposed these issues:github.run_id, which stays the same across reruns. Attempt 2 failed with! [rejected] ... (fetch first)because attempt 1 had already pushed that branch. The branch name now also includesgithub.run_attempt.'$GITHUB_STEP_SUMMARY'(single-quoted), which creates a file with that literal name instead of writing to the job summary. Now uses"${GITHUB_STEP_SUMMARY}".${{ github.workflow }}were inside a double-quoted string, so bash tried to runUpdate GeoLite Databaseas a command and the name was dropped from the PR body. The backticks are now escaped.[[ -z '$PR_URL' ]]tested a literal string and was never true. Now quotes the variable so an empty URL is detected.This PR does not fix the original failure (
GraphQL: must be a collaborator (createPullRequest)). That comes from theGH_PAT_WITH_ORGpersonal access token, whose owner account was deactivated. The fix is in #508, which switches the workflow to a GitHub App token. SRE is creating the App and adding its secrets directly to this repo (DOS-7368).Impacted roles: Developer / Operator (CI only, no runtime change).
Supporting information
Testing instructions
python3 -c "import yaml; yaml.safe_load(open('.github/workflows/update-geolite-database.yml'))".bash -c 'echo "PR generated by workflow \Update GeoLite Database` on behalf of @user."'`release-ulmoand check that it opens a PR whose branch name ends in-<run_id>-<run_attempt>.