Skip GitHub release creation when existing release is already latest#809
Conversation
Done in commit |
There was a problem hiding this comment.
Code Review
This pull request introduces a helper function shouldCreateGitHubRelease to conditionally skip creating a GitHub release if it already exists and is the latest release. The review feedback correctly identifies a critical bug where calling this function inside a command substitution $(...) executes it in a subshell, preventing exit 1 from terminating the parent script. Refactoring the function and its callers to rely on the function's exit status directly in the if conditions is recommended to ensure correct execution flow.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
Addressed in commit |
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces a helper function shouldCreateGitHubRelease in shared/publish_app_release.sh to check if a GitHub release already exists before attempting to create it, skipping creation if it is already the latest release. The reviewer suggested improving the robustness of this helper function by handling potential failures when retrieving the latest release tag name and using a cleaner, more idiomatic gh release view command instead of raw API calls.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces a helper function shouldCreateGitHubRelease in shared/publish_app_release.sh to check if a GitHub release already exists before attempting to create it. If the release exists and is the latest, the script now skips the creation step instead of failing. There are no review comments, and I have no feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
…ing release is already latest mtransitapps/commons#809
…ing release is already latest mtransitapps/commons#809
…ing release is already latest mtransitapps/commons#809
…ing release is already latest mtransitapps/commons#809
…ing release is already latest mtransitapps/commons#809
…ing release is already latest mtransitapps/commons#809
…ing release is already latest mtransitapps/commons#809
…er': - commons: Skip GitHub release creation when existing release is already latest mtransitapps/commons#809 - commons: runall.sh > print current directory on failure - commons: Build(deps): Bump com.google.android.libraries.places:places from 5.2.0 to 5.3.0 mtransitapps/commons#808 - commons: Improve GTFS input logging with optional CSV-aware previews after archive preparation mtransitapps/commons#805 - commons: Try fixing download timeout issue #Brandon mtransitapps/commons#806 - commons: Add conditional retry for flaky GTFS download step in mt-download-data workflow mtransitapps/commons#807 - commons-android: #isAndroidApp cleanup - commons-android: cleanup - commons-android: Filter `inFocus` cleanup & POI status `validity` (& `useful`) mtransitapps/commons-android#166 - commons-android: Delete `TimeExt.kt` mtransitapps/commons-android#169 - commons-android: Handle Twitter/X ISO-8601 millisecond timestamps in legacy date parsing mtransitapps/commons-android#167 - commons-java: Add build-time `MT_DEBUG_DEFAULT` support for `Constants.DEBUG` mtransitapps/commons-java#45 - commons-java: Replace `(?U)` (no compat /w Android) with Unicode Property Classes like `\p{L}`. - commons-java: CRASH fix created 5 hours ago in 478717d - commons-java: regex scratch++ - commons-java: String cleaner > compat w/ `Les É/Î / Abc` - commons-java: String cleaner > compat w/ `Les / Abc` - commons-java: Regex scratch > + expected result - commons-java: cleanup - parser: Use GTFS directions file when provided #lio mtransitapps/parser#77 - parser: `JSON` > + `service_id_avoid_merge`... mtransitapps/parser#76
Summary
Verify whether a GitHub release for the app version already exists and is the latest before attempting to create it.
Changes
/home/runner/work/commons/commons/shared/publish_app_release.sh.gh release createand continue to Play Store publishing.-gradle/app-androidpaths.Validation
bash -n /home/runner/work/commons/commons/shared/publish_app_release.shshared/publish_app_release.shparallel_validation(no actionable review findings; no CodeQL-analyzable language changes)shared/project_name.propertiesmissing).