chore(uat): [[ ]] tests + stderr errors (Sonar S7688/S7677)#568
Closed
alichherawalla wants to merge 1 commit into
Closed
chore(uat): [[ ]] tests + stderr errors (Sonar S7688/S7677)#568alichherawalla wants to merge 1 commit into
alichherawalla wants to merge 1 commit into
Conversation
Convert all POSIX [ ... ] conditionals in scripts/uat.sh to [[ ... ]] (S7688) and redirect the error() message to stderr (S7677). All operands were already quoted, so the change is behavior-neutral for this release script. Verified with bash -n.
|
ⓘ Qodo reviews are paused because your trial has ended. Ask your workspace admin to add credits to resume reviews. Manage billing |
📝 WalkthroughWalkthroughChangesUAT script updates
Estimated code review effort: 2 (Simple) | ~10 minutes 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
scripts/uat.sh (1)
177-179: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueReuse variables for APK and AAB paths.
Since
APK_SRCandAAB_SRCwere already defined for these exact paths earlier in the script, reusing them here reduces duplication and ensures consistency.♻️ Proposed fix to reuse variables
- [[ -f android/app/build/outputs/apk/release/app-release.apk ]] && \ - { cp android/app/build/outputs/apk/release/app-release.apk "$APK_DST"; GH_ARGS+=("$APK_DST"); } - [[ -f android/app/build/outputs/bundle/release/app-release.aab ]] && \ + [[ -f "$APK_SRC" ]] && \ + { cp "$APK_SRC" "$APK_DST"; GH_ARGS+=("$APK_DST"); } + [[ -f "$AAB_SRC" ]] && \🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@scripts/uat.sh` around lines 177 - 179, Update the APK and AAB existence checks and copy operations in the release artifact handling block to reuse the existing APK_SRC and AAB_SRC variables instead of repeating their literal paths. Preserve the current destination and GH_ARGS behavior.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@scripts/uat.sh`:
- Around line 177-179: Update the APK and AAB existence checks and copy
operations in the release artifact handling block to reuse the existing APK_SRC
and AAB_SRC variables instead of repeating their literal paths. Preserve the
current destination and GH_ARGS behavior.
26 tasks
Collaborator
Author
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.
Fixes SonarCloud shell code smells in
scripts/uat.sh.What
[ ... ]test conditional to[[ ... ]].error()message to stderr (>&2).Why safe
This is the production release script and cannot be run in review (it ships a real build). Every converted conditional already had its operands quoted, so
[[ ]](which suppresses word-splitting and globbing) is behavior-neutral here. No string literals like[ERROR]/[INFO]/[WARN]were touched.Verification
bash -n scripts/uat.shpasses (syntax clean).[[/]]counts balance (21 each).[ ... ]conditionals.bash -n+ manual review only.Diff: 22 insertions, 22 deletions.
Summary by CodeRabbit