chore(scripts): update e2e-maestro.sh#368
Conversation
WalkthroughUpdates e2e tooling to record Maestro flows instead of running tests, adds optional iOS ccache usage in scripts and CI, adjusts Maestro setup PATH handling, expands CI triggers to include scripts, bumps template dependencies, adds Bun hoisted linker configs, and includes bunfig.toml in generated packages when using Bun. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
actor Dev as Developer/CI
participant Script as e2e-maestro.sh
participant iOS as Xcode Build
participant Android as Gradle Build
participant CCache as ccache (optional)
participant Maestro as Maestro CLI
participant Artifacts as e2e-artifacts/
Dev->>Script: Invoke E2E workflow
Script->>Script: Determine project root, flow file, platform
alt iOS build
opt USE_CCACHE=1
Script->>CCache: Configure env, show status
end
Script->>iOS: Build with refined arch settings
iOS-->>Script: Build output
else Android build
Script->>Android: Build app
Android-->>Script: Build output
end
Script->>Artifacts: Ensure directories (incl. -retry)
Script->>Maestro: record flow -> output to artifacts
Maestro-->>Script: Recording results
Script-->>Dev: Exit with status
sequenceDiagram
autonumber
actor GH as GitHub Actions
participant WF as ci-packages.yml (iOS E2E)
participant Homebrew as brew
participant Cache as actions/cache
participant CCache as ccache
participant Tests as E2E run (USE_CCACHE=1)
GH->>WF: On push/PR (including scripts/**)
WF->>Homebrew: Install ccache
WF->>CCache: Zero/Configure (size, compression)
WF->>Cache: Restore ccache dir (key, restore-keys)
WF->>Tests: Run E2E with USE_CCACHE=1 and CCACHE_DIR
Tests-->>WF: Completed
WF->>CCache: Print statistics
WF->>Cache: Save updated cache
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (15)
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 |
| recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --local" | ||
| echo "🎯 Recording test video: $recordCmd" | ||
| echo "📱 APP_ID: $APP_ID" | ||
|
|
||
|
|
||
| if ! eval "$testCmd --debug-output e2e-artifacts/$PACKAGE_TYPE"; then | ||
| echo "Test ${test_file} failed. Retrying in 30 seconds..." | ||
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE.mp4"; then | ||
| echo "Recording ${test_file} failed. Retrying in 30 seconds..." | ||
| sleep 30 | ||
| if ! eval "$testCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-1"; then | ||
| echo "Test ${test_file} failed again. Retrying for the last time in 120 seconds..." | ||
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE-retry-1.mp4"; then | ||
| echo "Recording ${test_file} failed again. Retrying for the last time in 120 seconds..." | ||
| sleep 120 | ||
| if ! eval "$testCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-2"; then | ||
| echo "Test ${test_file} failed again. Exiting..." | ||
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE-retry-2.mp4"; then | ||
| echo "Recording ${test_file} failed again. Exiting..." |
There was a problem hiding this comment.
Include Maestro’s --output flag so the recording runs
maestro record expects the target file to be provided via --output. Passing a bare path (e.g. e2e-artifacts/module.mp4) is interpreted as an unexpected positional argument, so the command exits immediately and every attempt falls into the retry branches without ever producing a video. Add the flag before appending the path so the CLI accepts the argument and writes the MP4.
-recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --local"
+recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --local --output"📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --local" | |
| echo "🎯 Recording test video: $recordCmd" | |
| echo "📱 APP_ID: $APP_ID" | |
| if ! eval "$testCmd --debug-output e2e-artifacts/$PACKAGE_TYPE"; then | |
| echo "Test ${test_file} failed. Retrying in 30 seconds..." | |
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE.mp4"; then | |
| echo "Recording ${test_file} failed. Retrying in 30 seconds..." | |
| sleep 30 | |
| if ! eval "$testCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-1"; then | |
| echo "Test ${test_file} failed again. Retrying for the last time in 120 seconds..." | |
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE-retry-1.mp4"; then | |
| echo "Recording ${test_file} failed again. Retrying for the last time in 120 seconds..." | |
| sleep 120 | |
| if ! eval "$testCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-2"; then | |
| echo "Test ${test_file} failed again. Exiting..." | |
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE-retry-2.mp4"; then | |
| echo "Recording ${test_file} failed again. Exiting..." | |
| recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --local --output" | |
| echo "🎯 Recording test video: $recordCmd" | |
| echo "📱 APP_ID: $APP_ID" | |
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE.mp4"; then | |
| echo "Recording ${test_file} failed. Retrying in 30 seconds..." | |
| sleep 30 | |
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE-retry-1.mp4"; then | |
| echo "Recording ${test_file} failed again. Retrying for the last time in 120 seconds..." | |
| sleep 120 | |
| if ! eval "$recordCmd e2e-artifacts/$PACKAGE_TYPE-retry-2.mp4"; then | |
| echo "Recording ${test_file} failed again. Exiting..." |
🤖 Prompt for AI Agents
In scripts/e2e-maestro.sh around lines 135 to 147, the maestro record invocation
supplies the target MP4 path as a bare positional argument (causing the CLI to
treat it as unexpected), so update the three eval invocations to pass the path
with the --output flag (e.g. eval "$recordCmd --output
e2e-artifacts/$PACKAGE_TYPE.mp4" and likewise for the retry filenames) so
maestro accepts the destination and actually writes the recordings.
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
scripts/e2e-maestro.sh (1)
48-49: Simulator UUID grep misses lowercase hex; ID may be empty.
simctlemits lowercase UUIDs; pattern[0-9A-F-]{36}rejects them, yielding an empty$iphone16Idand failingxcodebuild/install.- iphone16Id=$(xcrun simctl list devices | grep "iPhone 16 (" | grep -E '\(Booted\)|\(Shutdown\)' | head -1 | grep -E -o '\([0-9A-F-]{36}\)' | tr -d '()') + iphone16Id=$(xcrun simctl list devices | grep "iPhone 16 (" | grep -E '\(Booted\)|\(Shutdown\)' | head -1 | grep -E -o '\([0-9A-Fa-f-]{36}\)' | tr -d '()')Also guard against empty IDs:
[[ -z "$iphone16Id" ]] && { echo "❌ No matching simulator found"; exit 1; }
♻️ Duplicate comments (1)
scripts/e2e-maestro.sh (1)
154-156: Recording never writes an MP4 — missing--outputargument.
maestro recordrequires--output <file.mp4>. Without it, no video is produced and retries loop. Add--outputand pass retry file names.# Create output directory for videos mkdir -p e2e-artifacts -recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID" -echo "🎯 Recording test video: $recordCmd" +output_base="e2e-artifacts/$PACKAGE_TYPE" +recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --output" +echo "🎯 Recording test video: $recordCmd ${output_base}.mp4" echo "📱 APP_ID: $APP_ID" -if ! eval "$recordCmd --debug-output e2e-artifacts/$PACKAGE_TYPE"; then +if ! eval "$recordCmd \"${output_base}.mp4\" --debug-output \"${output_base}\""; then echo "Recording ${test_file} failed. Retrying in 30 seconds..." sleep 30 - if ! eval "$recordCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-1"; then + if ! eval "$recordCmd \"${output_base}-retry-1.mp4\" --debug-output \"${output_base}-retry-1\""; then echo "Recording ${test_file} failed again. Retrying for the last time in 120 seconds..." sleep 120 - if ! eval "$recordCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-2"; then + if ! eval "$recordCmd \"${output_base}-retry-2.mp4\" --debug-output \"${output_base}-retry-2\""; then echo "Recording ${test_file} failed again. Exiting..." exit 1 fi fi fi#!/bin/bash # Verify Maestro supports --output and that an MP4 is actually produced maestro record --help | rg -n '\b--output\b' || { echo "--output not found in help"; exit 1; } test -f "e2e-artifacts/$PACKAGE_TYPE.mp4" && echo "✅ MP4 present" || { echo "❌ MP4 missing"; exit 1; }Also applies to: 159-166
🧹 Nitpick comments (4)
scripts/e2e-maestro.sh (4)
112-113: Harden directory changes with|| exitand quoting.Prevents silent failures per ShellCheck SC2164.
- cd "$SCRIPT_DIR" + cd "$SCRIPT_DIR" || exit 1 ... - cd "$SCRIPT_DIR" + cd "$SCRIPT_DIR" || exit 1Also applies to: 135-135
53-63: ccache block likely not effective without Xcode integration; at least surface stats.Xcode won’t use ccache just by exporting env vars. Keep the optional block, but print stats to validate usage.
echo "📦 ccache directory: $CCACHE_DIR" - ccache --max-size=2G 2>/dev/null || true + ccache --max-size=2G 2>/dev/null || true + ccache -s 2>/dev/null || trueFollow‑up: if you want real hits, consider compiler wrappers or Xcode build setting integration.
106-110: Check that a .app was built before installing.Avoids a confusing install error when the build fails or paths differ.
APP_PATH=$(find build/Build/Products/Release-iphonesimulator -name "*.app" | head -1) echo "📲 Installing app from: $APP_PATH" - xcrun simctl install $iphone16Id "$APP_PATH" + if [[ -z "$APP_PATH" ]]; then + echo "❌ Built app not found under build/Build/Products/Release-iphonesimulator" + exit 1 + fi + xcrun simctl install "$iphone16Id" "$APP_PATH"
45-46: Quote and guard directory changes to example apps.Prevents path breakage when EXAMPLE_DIR contains spaces or is unset.
- cd $EXAMPLE_DIR/ios + cd "$EXAMPLE_DIR/ios" || exit 1 ... - cd $EXAMPLE_DIR/android + cd "$EXAMPLE_DIR/android" || exit 1Also applies to: 114-116
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
.github/workflows/ci-packages.yml(3 hunks)scripts/e2e-maestro.sh(4 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
- .github/workflows/ci-packages.yml
🧰 Additional context used
🪛 Shellcheck (0.11.0)
scripts/e2e-maestro.sh
[warning] 112-112: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
(SC2164)
[warning] 135-135: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
(SC2164)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (15)
- GitHub Check: Test iOS Build - yarn - view (Debug)
- GitHub Check: Test iOS Build - bun - view (Debug)
- GitHub Check: Test iOS Build - bun - module (Release)
- GitHub Check: Test Android Build - yarn - view (Debug)
- GitHub Check: Test iOS Build - yarn - module (Debug)
- GitHub Check: Test Android Build - yarn - view (Release)
- GitHub Check: Test Android Build - yarn - module (Release)
- GitHub Check: Test Android Build - bun - view (Debug)
- GitHub Check: Android E2E Test (module, Release, bun)
- GitHub Check: Test Android Build - yarn - module (Debug)
- GitHub Check: Test Android Build - bun - view (Release)
- GitHub Check: Android E2E Test (view, Release, bun)
- GitHub Check: Test Android Build - bun - module (Debug)
- GitHub Check: Test Android Build - bun - module (Release)
- GitHub Check: iOS E2E Test (module, Release, bun)
| -configuration Release \ | ||
| -destination id=$iphone16Id \ | ||
| -parallelizeTargets \ | ||
| -derivedDataPath build \ | ||
| -jobs $(sysctl -n hw.ncpu) \ | ||
| ONLY_ACTIVE_ARCH=YES \ | ||
| ARCHS=arm64 \ | ||
| VALID_ARCHS=arm64 \ | ||
| EXCLUDED_ARCHS=x86_64 \ | ||
| CODE_SIGNING_ALLOWED=NO" |
There was a problem hiding this comment.
iOS build arch overrides are non‑portable; VALID_ARCHS is deprecated.
Hard‑forcing ARCHS=arm64 and EXCLUDED_ARCHS=x86_64 breaks Intel runners; VALID_ARCHS no longer respected in modern Xcode. Prefer letting the simulator SDK resolve archs or gate by host CPU.
- -configuration Release \
+ -configuration Release -sdk iphonesimulator \
-destination id=$iphone16Id \
-derivedDataPath build \
-jobs $(sysctl -n hw.ncpu) \
- ONLY_ACTIVE_ARCH=YES \
- ARCHS=arm64 \
- VALID_ARCHS=arm64 \
- EXCLUDED_ARCHS=x86_64 \
CODE_SIGNING_ALLOWED=NO"Optionally gate EXCLUDED_ARCHS by host:
if [[ "$(uname -m)" == "x86_64" ]]; then EXCLUDED=""; else EXCLUDED="EXCLUDED_ARCHS=x86_64"; fiThere was a problem hiding this comment.
Actionable comments posted: 2
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (7)
.github/workflows/ci-packages.yml(5 hunks).github/workflows/deploy.yml(1 hunks).github/workflows/release.yml(1 hunks)assets/template/.github/workflows/android-build.yml(1 hunks)assets/template/.github/workflows/ios-build.yml(1 hunks)assets/template/.github/workflows/release.yml(1 hunks)test-local.sh(1 hunks)
✅ Files skipped from review due to trivial changes (1)
- assets/template/.github/workflows/android-build.yml
🚧 Files skipped from review as they are similar to previous changes (1)
- .github/workflows/ci-packages.yml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (15)
- GitHub Check: Test Android Build - yarn - module (Release)
- GitHub Check: Test iOS Build - bun - view (Release)
- GitHub Check: Test iOS Build - bun - module (Debug)
- GitHub Check: Test iOS Build - yarn - module (Debug)
- GitHub Check: Test Android Build - bun - view (Release)
- GitHub Check: Test Android Build - yarn - view (Debug)
- GitHub Check: Test Android Build - yarn - view (Release)
- GitHub Check: Test Android Build - yarn - module (Debug)
- GitHub Check: Test Android Build - bun - view (Debug)
- GitHub Check: Test Android Build - bun - module (Debug)
- GitHub Check: Test Android Build - bun - module (Release)
- GitHub Check: Android E2E Test (module, Release, bun)
- GitHub Check: Android E2E Test (view, Release, bun)
- GitHub Check: iOS E2E Test (view, Release, bun)
- GitHub Check: iOS E2E Test (module, Release, bun)
| - name: Install npm dependencies (bun) | ||
| run: bun install | ||
| run: bun install --linker=hoisted | ||
|
|
There was a problem hiding this comment.
Keep --frozen-lockfile for reproducible releases
Dropping --frozen-lockfile means this release job can silently upgrade dependencies if bun.lock is stale, which undermines reproducibility and can push unvetted versions to prod. Please restore the flag while retaining the hoisted linker.
- - name: Install npm dependencies (bun)
- run: bun install --linker=hoisted
+ - name: Install npm dependencies (bun)
+ run: bun install --linker=hoisted --frozen-lockfile📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| - name: Install npm dependencies (bun) | |
| run: bun install | |
| run: bun install --linker=hoisted | |
| - name: Install npm dependencies (bun) | |
| run: bun install --linker=hoisted --frozen-lockfile |
🤖 Prompt for AI Agents
In .github/workflows/release.yml around lines 35 to 37, the bun install
invocation removed the --frozen-lockfile flag which allows silent dependency
upgrades; restore reproducible installs by adding --frozen-lockfile back to the
command while keeping --linker=hoisted (i.e., run bun install --linker=hoisted
--frozen-lockfile) so the job fails if bun.lock is out of sync.
| - name: Install npm dependencies (bun) | ||
| run: bun install | ||
| run: bun install --linker=hoisted | ||
|
|
There was a problem hiding this comment.
Restore lockfile enforcement in the template
Templates should keep --frozen-lockfile so downstream projects inherit reproducible release builds. Without it, installs may mutate bun.lock during CI.
- - name: Install npm dependencies (bun)
- run: bun install --linker=hoisted
+ - name: Install npm dependencies (bun)
+ run: bun install --linker=hoisted --frozen-lockfile📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| - name: Install npm dependencies (bun) | |
| run: bun install | |
| run: bun install --linker=hoisted | |
| - name: Install npm dependencies (bun) | |
| run: bun install --linker=hoisted --frozen-lockfile |
🤖 Prompt for AI Agents
In assets/template/.github/workflows/release.yml around lines 40 to 42, the bun
install step omits lockfile enforcement which allows bun.lock to be mutated
during CI; update the run command to include the frozen lockfile flag (e.g., add
--frozen-lockfile alongside --linker=hoisted) so installs fail if the lockfile
is out of sync and downstream projects inherit reproducible release builds.
There was a problem hiding this comment.
Actionable comments posted: 1
♻️ Duplicate comments (2)
scripts/e2e-maestro.sh (2)
68-75: Remove the hard-coded arm64 simulator arch overrides.Forcing
ONLY_ACTIVE_ARCH=YES,ARCHS=arm64,VALID_ARCHS=arm64, andEXCLUDED_ARCHS=x86_64breaks Recorder runs on Intel hosts where the simulator toolchain needs x86_64. Modern Xcode ignoresVALID_ARCHS, so this block just prevents the build from ever succeeding off Apple Silicon. Please drop these overrides (or gate them by host CPU).- -configuration Release \ - -destination id=$iphone16Id \ - -derivedDataPath build \ - -jobs $(sysctl -n hw.ncpu) \ - ONLY_ACTIVE_ARCH=YES \ - ARCHS=arm64 \ - VALID_ARCHS=arm64 \ - EXCLUDED_ARCHS=x86_64 \ + -configuration Release \ + -destination id=$iphone16Id \ + -derivedDataPath build \ + -jobs $(sysctl -n hw.ncpu) \
154-166: Pass the MP4 path with--outputon every Maestro recording.
maestro recordneeds the target file behind--output; otherwise it writes to the defaultmaestro.mp4(or exits on older CLI builds), so nothing lands ine2e-artifacts/$PACKAGE_TYPE*.mp4. Add--output <path>to the initial and retry invocations.-recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --local" +recordCmd="maestro record \"$test_file\" -e APP_ID=$APP_ID --local" +recordOutput="e2e-artifacts/$PACKAGE_TYPE.mp4" +recordDebugBase="e2e-artifacts/$PACKAGE_TYPE-debug" echo "🎯 Recording test video: $recordCmd" ... -if ! eval "$recordCmd --debug-output e2e-artifacts/$PACKAGE_TYPE"; then +if ! eval "$recordCmd --output \"$recordOutput\" --debug-output \"$recordDebugBase\""; then echo "Recording ${test_file} failed. Retrying in 30 seconds..." sleep 30 - if ! eval "$recordCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-1"; then + if ! eval "$recordCmd --output \"${recordOutput/.mp4/-retry-1.mp4}\" --debug-output \"${recordDebugBase}-retry-1\""; then echo "Recording ${test_file} failed again. Retrying for the last time in 120 seconds..." sleep 120 - if ! eval "$recordCmd --debug-output e2e-artifacts/$PACKAGE_TYPE-retry-2"; then + if ! eval "$recordCmd --output \"${recordOutput/.mp4/-retry-2.mp4}\" --debug-output \"${recordDebugBase}-retry-2\""; then echo "Recording ${test_file} failed again. Exiting..." exit 1 fi
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
scripts/e2e-maestro.sh(4 hunks)
🧰 Additional context used
🪛 Shellcheck (0.11.0)
scripts/e2e-maestro.sh
[warning] 112-112: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
(SC2164)
[warning] 135-135: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
(SC2164)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (14)
- GitHub Check: Test Android Build - yarn - view (Release)
- GitHub Check: Test Android Build - yarn - view (Debug)
- GitHub Check: Test Android Build - bun - view (Release)
- GitHub Check: Test Android Build - yarn - module (Release)
- GitHub Check: Test Android Build - bun - view (Debug)
- GitHub Check: Test Android Build - yarn - module (Debug)
- GitHub Check: Test Android Build - bun - module (Release)
- GitHub Check: Test Android Build - bun - module (Debug)
- GitHub Check: Android E2E Test (view, Release, bun)
- GitHub Check: Android E2E Test (module, Release, bun)
- GitHub Check: Test iOS Build - yarn - module (Debug)
- GitHub Check: Test iOS Build - bun - module (Debug)
- GitHub Check: Test iOS Build - bun - module (Release)
- GitHub Check: iOS E2E Test (view, Release, bun)
|
|
||
| cd ../../.. | ||
| # Return to project root | ||
| cd "$SCRIPT_DIR" |
There was a problem hiding this comment.
🛠️ Refactor suggestion | 🟠 Major
Fail fast if returning to the project root fails.
Both cd "$SCRIPT_DIR" calls should guard against failure; otherwise the script keeps running from the wrong directory and the rest of the flow breaks. Add || exit 1.
- cd "$SCRIPT_DIR"
+ cd "$SCRIPT_DIR" || exit 1- cd "$SCRIPT_DIR"
+ cd "$SCRIPT_DIR" || exit 1Also applies to: 135-135
🧰 Tools
🪛 Shellcheck (0.11.0)
[warning] 112-112: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
(SC2164)
🤖 Prompt for AI Agents
In scripts/e2e-maestro.sh around lines 112 and 135, the two cd "$SCRIPT_DIR"
invocations do not check for failure; if changing directories fails the script
will continue running from the wrong location. Update both cd commands to guard
against errors by exiting on failure (i.e., append a conditional exit such as ||
exit 1) so the script fails fast if returning to the project root fails.
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (4)
.github/workflows/ci-packages.yml(3 hunks)assets/template/bunfig.toml(1 hunks)bunfig.toml(1 hunks)src/generate-nitro-package.ts(1 hunks)
✅ Files skipped from review due to trivial changes (1)
- bunfig.toml
🚧 Files skipped from review as they are similar to previous changes (1)
- .github/workflows/ci-packages.yml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (15)
- GitHub Check: Test Android Build - yarn - view (Release)
- GitHub Check: Test iOS Build - yarn - view (Debug)
- GitHub Check: Test iOS Build - bun - view (Release)
- GitHub Check: Test iOS Build - yarn - module (Debug)
- GitHub Check: Test Android Build - yarn - module (Debug)
- GitHub Check: Test Android Build - yarn - module (Release)
- GitHub Check: Test Android Build - bun - view (Debug)
- GitHub Check: Test Android Build - bun - module (Debug)
- GitHub Check: Test Android Build - yarn - view (Debug)
- GitHub Check: Test Android Build - bun - module (Release)
- GitHub Check: Test iOS Build - bun - module (Debug)
- GitHub Check: Test Android Build - bun - view (Release)
- GitHub Check: iOS E2E Test (module, Release, bun)
- GitHub Check: Android E2E Test (module, Release, bun)
- GitHub Check: Android E2E Test (view, Release, bun)
🔇 Additional comments (1)
assets/template/bunfig.toml (1)
1-2: PR title/description doesn't match the actual changes.The PR title mentions "update e2e-maestro.sh" and the description says "Update Maestro E2E script", but the files under review add Bun configuration via
bunfig.toml. There's no e2e-maestro.sh file in this review.The configuration itself is valid for Bun's hoisted linker mode.
… on package manager
Update Maestro E2E script.
Summary by CodeRabbit
New Features
Tests
Chores