Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ar/check ml ruby #1430

Closed
wants to merge 6 commits into from
Closed

Ar/check ml ruby #1430

wants to merge 6 commits into from

Conversation

alexrisch
Copy link
Contributor

@alexrisch alexrisch commented Dec 21, 2024

Summary by CodeRabbit

  • New Features

    • Added new scripts for cleaning React Native builds and checking iOS build dependencies.
    • Introduced updated build workflows for both iOS and Android to streamline the process.
  • Updates

    • Updated Ruby version to 3.2.5 in the project configuration.
    • Specified a new macOS image for the production build environment.
    • Added new script entries for cleaning builds and checking dependencies in the package configuration.
  • Bug Fixes

    • Improved dependency management with new scripts and updated configurations.

https://docs.expo.dev/build-reference/infrastructure/#ios-server-images

iOS server images
macos-sonoma-14.6-xcode-16.1
(
latest
,
sdk-52
)
Details
macOS Sonoma 14.6
Xcode 16.1 (16B40)
Node.js 18.18.0
Bun 1.1.33
Yarn 1.22.21
pnpm 9.12.3
npm 9.8.1
fastlane 2.225.0
CocoaPods 1.16.2
Ruby 3.2
node-gyp 10.2.0
@alexrisch alexrisch requested a review from a team as a code owner December 21, 2024 13:32
Copy link
Contributor

coderabbitai bot commented Dec 21, 2024

Caution

Review failed

The pull request is closed.

Walkthrough

This pull request introduces several changes to the iOS build process and project configuration. The modifications include updating the Ruby version to 3.2.5, altering the iOS build workflow by changing the operating system to Ubuntu and removing certain steps, and adding new scripts for checking build dependencies and cleaning the project. Additionally, the eas.json configuration has been updated to specify the macOS environment for builds. The Android build workflow has been streamlined by removing unnecessary setup tasks and modifying the build command.

Changes

File Change Summary
.github/workflows/check-ios-build.yml Changed OS from macos-latest to ubuntu-latest; removed steps for freeing up disk space, cleaning Derived Data and Cache, and uploading IPA artifact; updated build profile from ios-simulator to development.
.ruby-version Updated Ruby version to 3.2.5.
eas.json Added image property for iOS development and production builds specifying macOS Sonoma 14.6 and Xcode 16.1; modified resourceClass for Android development from medium to large.
ios/Gemfile Updated Ruby version to ~> 3.2.5 and Bundler version to ~> 2.5.16.
package.json Added two new scripts: clean and ios:checkBuildDeps.
scripts/ios/checkBuildDeps.sh New script to check iOS build dependencies (Ruby, Bundler, CocoaPods).
scripts/reactNativeCleanBuild.sh New script to clean and rebuild React Native project.
.github/workflows/check-android-build.yml Removed steps for cleaning the Android device, setting up JDK 17, and setting up the Android SDK; removed --local flag from the eas build command.

Possibly related PRs

Suggested reviewers

  • thierryskoda

Poem

🐰 A Ruby hop, a workflow's dance,
Clean builds await with just one glance.
Sonoma's breeze, Xcode's might,
Dependencies checked, everything's right!
Build on, brave app, with rabbit's delight! 🚀


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 063390c and 161ee49.

📒 Files selected for processing (4)
  • .github/workflows/check-android-build.yml (1 hunks)
  • .github/workflows/check-ios-build.yml (2 hunks)
  • eas.json (2 hunks)
  • ios/Gemfile (1 hunks)

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Nitpick comments (3)
ios/Gemfile (1)

6-7: Update comment for accuracy

The comment mentions Ruby 3.3 compatibility, but the Gemfile specifies Ruby 3.2.5. This comment should be updated to reflect the current version requirement.

-# Specify bundler version that works with Ruby 3.3
+# Specify bundler version that works with Ruby 3.2
scripts/ios/checkBuildDeps.sh (2)

4-7: Remove unused color code

The YELLOW color code is defined but never used in the script.

-YELLOW='\033[1;33m'
🧰 Tools
🪛 Shellcheck (0.10.0)

[warning] 6-6: YELLOW appears unused. Verify use (or export if used externally).

(SC2034)


1-77: Consider adding exit codes for automation

The script would be more useful in automated environments if it returned meaningful exit codes based on the dependency check results.

+# Exit codes
+# 0: All dependencies found
+# 1: One or more dependencies missing
+
+EXIT_CODE=0
+
 # Function to print status
 print_status() {
     local name=$1
     local version=$2
     local path=$3
     local status=$4
     
     printf "${BOLD}%-12s${NC}" "$name"
     
     if [ "$status" = "OK" ]; then
         printf "${GREEN}✓${NC} "
     else
         printf "${RED}✗${NC} "
+        EXIT_CODE=1
     fi
     
     printf "%-45s" "$version"
     echo "$path"
 }

 # ... rest of the script ...

-echo -e "\nDone checking dependencies.\n"
+echo -e "\nDone checking dependencies.\n"
+exit $EXIT_CODE
🧰 Tools
🪛 Shellcheck (0.10.0)

[warning] 6-6: YELLOW appears unused. Verify use (or export if used externally).

(SC2034)

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 13b0666 and aead400.

⛔ Files ignored due to path filters (1)
  • ios/Gemfile.lock is excluded by !**/*.lock
📒 Files selected for processing (7)
  • .github/workflows/check-ios-build.yml (1 hunks)
  • .ruby-version (1 hunks)
  • eas.json (1 hunks)
  • ios/Gemfile (1 hunks)
  • package.json (1 hunks)
  • scripts/ios/checkBuildDeps.sh (1 hunks)
  • scripts/reactNativeCleanBuild.sh (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • .ruby-version
🧰 Additional context used
🪛 Shellcheck (0.10.0)
scripts/ios/checkBuildDeps.sh

[warning] 6-6: YELLOW appears unused. Verify use (or export if used externally).

(SC2034)

🔇 Additional comments (3)
ios/Gemfile (1)

4-4: Verify Ruby version synchronization

The comment correctly references the workflow file synchronization requirement. However, let's verify this is consistently applied across the project.

✅ Verification successful

Ruby version is correctly synchronized across the project

The verification confirms that Ruby version 3.2.5 is consistently specified across:

  • ios/Gemfile: ruby '~> 3.2.5'
  • .ruby-version file: 3.2.5
  • .github/workflows/check-ios-build.yml: ruby-version: "3.2.5"
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check Ruby version consistency across project files
echo "Checking Ruby version in .ruby-version:"
cat .ruby-version 2>/dev/null || echo "File not found"

echo -e "\nChecking Ruby version in workflow files:"
rg "ruby-version.*3\.2\.5" .github/workflows/

Length of output: 329

eas.json (1)

32-33: Verify Xcode version compatibility with project requirements

The specified Xcode version (16.1) is not the latest available. Consider upgrading to Xcode 16.2 for the latest improvements and bug fixes, unless there are specific compatibility requirements with your project dependencies.

✅ Verification successful

Using Xcode 16.1 is appropriate for this project

The project has an iOS deployment target of 16.0, and Xcode 16.1 is fully capable of building for this target. While Xcode 16.2 is available, there's no compelling reason to upgrade since:

  • The current setup meets the minimum iOS requirements
  • The extensive list of React Native dependencies suggests a stable development environment
  • No specific features from Xcode 16.2 are required for the project's dependencies
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check for any Xcode version requirements in project configuration
rg -i "xcode.*version|IPHONEOS_DEPLOYMENT_TARGET" --type xml

Length of output: 211


Script:

#!/bin/bash
# Check for any Xcode or iOS deployment target requirements in various config files
rg -i "xcode|IPHONEOS_DEPLOYMENT_TARGET" --type json --type xml --type plist --type yaml

# List iOS related configuration files
fd -e pbxproj -e plist -e xcconfig

Length of output: 495


Script:

#!/bin/bash
# Check project.pbxproj for deployment target and Xcode related settings
cat ios/Converse.xcodeproj/project.pbxproj | grep -i "IPHONEOS_DEPLOYMENT_TARGET\|DEVELOPMENT_TEAM\|PROVISIONING_PROFILE"

# Check package.json for any iOS related dependencies or requirements
cat package.json | grep -i "ios\|xcode\|react-native"

Length of output: 3588

package.json (1)

10-10: LGTM! Script additions are well-structured

The new scripts are properly integrated and follow the project's naming conventions.

Also applies to: 16-16

Comment on lines +38 to +42
echo "Running yarn install..."
yarn install

echo "Running pod install..."
cd ios && pod install && cd ..
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Add error handling for dependency operations

The yarn and pod commands lack error handling and verification.

-echo "Running yarn install..."
-yarn install
+echo "Running yarn install..."
+yarn install || {
+    echo "Error: yarn install failed"
+    exit 1
+}
 
-echo "Running pod install..."
-cd ios && pod install && cd ..
+echo "Running pod install..."
+cd ios || exit 1
+pod install || {
+    echo "Error: pod install failed"
+    cd ..
+    exit 1
+}
+cd ..
📝 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.

Suggested change
echo "Running yarn install..."
yarn install
echo "Running pod install..."
cd ios && pod install && cd ..
echo "Running yarn install..."
yarn install || {
echo "Error: yarn install failed"
exit 1
}
echo "Running pod install..."
cd ios || exit 1
pod install || {
echo "Error: pod install failed"
cd ..
exit 1
}
cd ..

Comment on lines +29 to +36
echo "Moving node_modules to trash..."
osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/node_modules\""

echo "Moving ios/build to trash..."
osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/ios/build\""

echo "Moving ios/Pods to trash..."
osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/ios/Pods\""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Add platform check and error handling

The script uses macOS-specific commands without platform verification or error handling.

 #!/bin/bash
+
+# Exit on error
+set -e
+
+# Check if running on macOS
+if [[ "$OSTYPE" != "darwin"* ]]; then
+    echo "Error: This script requires macOS"
+    exit 1
+fi
+
+# Function to safely move to trash
+move_to_trash() {
+    local path="$1"
+    local name="$2"
+    if [ -e "$path" ]; then
+        echo "Moving $name to trash..."
+        osascript -e "tell app \"Finder\" to delete POSIX file \"$path\"" || {
+            echo "Error: Failed to move $name to trash"
+            exit 1
+        }
+    else
+        echo "Skipping $name - directory not found"
+    fi
+}
 
-echo "Moving node_modules to trash..."
-osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/node_modules\""
-
-echo "Moving ios/build to trash..."
-osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/ios/build\""
-
-echo "Moving ios/Pods to trash..."
-osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/ios/Pods\""
+move_to_trash "$PWD/node_modules" "node_modules"
+move_to_trash "$PWD/ios/build" "ios/build"
+move_to_trash "$PWD/ios/Pods" "ios/Pods"
📝 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.

Suggested change
echo "Moving node_modules to trash..."
osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/node_modules\""
echo "Moving ios/build to trash..."
osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/ios/build\""
echo "Moving ios/Pods to trash..."
osascript -e "tell app \"Finder\" to delete POSIX file \"$PWD/ios/Pods\""
#!/bin/bash
# Exit on error
set -e
# Check if running on macOS
if [[ "$OSTYPE" != "darwin"* ]]; then
echo "Error: This script requires macOS"
exit 1
fi
# Function to safely move to trash
move_to_trash() {
local path="$1"
local name="$2"
if [ -e "$path" ]; then
echo "Moving $name to trash..."
osascript -e "tell app \"Finder\" to delete POSIX file \"$path\"" || {
echo "Error: Failed to move $name to trash"
exit 1
}
else
echo "Skipping $name - directory not found"
fi
}
move_to_trash "$PWD/node_modules" "node_modules"
move_to_trash "$PWD/ios/build" "ios/build"
move_to_trash "$PWD/ios/Pods" "ios/Pods"

Comment on lines 25 to 28
- name: Setup Ruby
uses: actions/setup-ruby@v1
with:
ruby-version: "3.2.5"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Update to latest Ruby setup action

The workflow is using an outdated version of actions/setup-ruby. Version 1 is deprecated and should be updated to the latest stable version.

-      - name: Setup Ruby
-        uses: actions/setup-ruby@v1
+      - name: Setup Ruby
+        uses: ruby/setup-ruby@v1
         with:
           ruby-version: "3.2.5"
+          bundler-cache: true

The ruby/setup-ruby action is the official replacement for actions/setup-ruby and includes improved caching and better platform support. Adding bundler-cache: true will automatically handle gem installation and caching.

📝 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.

Suggested change
- name: Setup Ruby
uses: actions/setup-ruby@v1
with:
ruby-version: "3.2.5"
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2.5"
bundler-cache: true

Copy link
Contributor

github-actions bot commented Dec 21, 2024

Performance Comparison Report

  • Current: 3cea963 - 2024-12-22 20:05:34Z
  • Baseline: release/3.0.0 (9119c3e) - 2024-12-22 20:04:14Z

Significant Changes To Duration

There are no entries

Meaningless Changes To Duration

Show entries
Name Type Duration Count
Avatar Image 10 runs render 1.3 ms → 1.1 ms (-0.2 ms, -15.4%) 🟢 1 → 1
Avatar Image 50 runs render 1.0 ms → 1.0 ms (+0.0 ms, +4.0%) 1 → 1
Empty Avatar 10 runs render 1.0 ms → 0.7 ms (-0.3 ms, -30.0%) 🟢 1 → 1
Empty Avatar 50 runs render 0.8 ms → 0.7 ms (-0.1 ms, -13.2%) 1 → 1
Text Component with color prop - 10 runs render 0.1 ms → 0.3 ms (+0.2 ms, +200.0%) 🔴 1 → 1
Text Component with default props - 10 runs render 0.3 ms → 0.0 ms (-0.3 ms, -100.0%) 🟢 1 → 1
Text Component with translation key - 10 runs render 0.3 ms → 0.4 ms (+0.1 ms, +33.3%) 🔴 1 → 1
Text Component with weight and size - 10 runs render 0.3 ms → 0.3 ms 1 → 1
Show details
Name Type Duration Count
Avatar Image 10 runs render Baseline
Mean: 1.3 ms
Stdev: 0.5 ms (37.2%)
Runs: 2 1 1 1 1 2 1 2 1 1
Warmup runs: 3

Current
Mean: 1.1 ms
Stdev: 0.3 ms (28.7%)
Runs: 1 2 1 1 1 1 1 1 1 1
Warmup runs: 2
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:
Avatar Image 50 runs render Baseline
Mean: 1.0 ms
Stdev: 0.0 ms (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Warmup runs: 2

Current
Mean: 1.0 ms
Stdev: 0.3 ms (27.2%)
Runs: 1 1 1 1 1 2 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1
Warmup runs: 1
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Render issues:
Empty Avatar 10 runs render Baseline
Mean: 1.0 ms
Stdev: 0.0 ms (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Warmup runs: 3

Current
Mean: 0.7 ms
Stdev: 0.5 ms (69.0%)
Runs: 0 1 1 1 1 1 1 1 0 0
Warmup runs: 3
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:
Empty Avatar 50 runs render Baseline
Mean: 0.8 ms
Stdev: 0.4 ms (56.8%)
Runs: 1 0 1 1 0 1 1 1 1 0 1 1 1 1 1 1 0 0 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 0 1 0 0 1 1 0 1 1 1 0 1 1 1 1 1 1
Warmup runs: 1

Current
Mean: 0.7 ms
Stdev: 0.5 ms (72.5%)
Runs: 1 1 1 1 1 1 0 1 1 1 0 1 1 1 0 0 1 0 0 0 0 1 1 0 1 0 1 1 0 1 1 1 1 1 1 1 0 0 0 1 0 0 1 0 1 1 1 1 1 1
Warmup runs: 1
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Render issues:
Text Component with color prop - 10 runs render Baseline
Mean: 0.1 ms
Stdev: 0.3 ms (316.2%)
Runs: 0 1 0 0 0 0 0 0 0 0
Warmup runs: 0

Current
Mean: 0.3 ms
Stdev: 0.5 ms (161.0%)
Runs: 0 0 1 1 0 0 0 1 0 0
Warmup runs: 0
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:
Text Component with default props - 10 runs render Baseline
Mean: 0.3 ms
Stdev: 0.5 ms (161.0%)
Runs: 0 1 0 1 0 0 0 0 0 1
Warmup runs: 0

Current
Mean: 0.0 ms
Stdev: 0.0 ms (NaN%)
Runs: 0 0 0 0 0 0 0 0 0 0
Warmup runs: 0
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:
Text Component with translation key - 10 runs render Baseline
Mean: 0.3 ms
Stdev: 0.5 ms (161.0%)
Runs: 0 0 0 0 1 0 1 0 0 1
Warmup runs: 1

Current
Mean: 0.4 ms
Stdev: 0.5 ms (129.1%)
Runs: 0 0 1 0 0 1 1 0 0 1
Warmup runs: 1
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:
Text Component with weight and size - 10 runs render Baseline
Mean: 0.3 ms
Stdev: 0.5 ms (161.0%)
Runs: 0 0 1 1 1 0 0 0 0 0
Warmup runs: 0

Current
Mean: 0.3 ms
Stdev: 0.5 ms (161.0%)
Runs: 0 0 0 0 0 1 0 1 0 1
Warmup runs: 0
Baseline
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:

Current
Mean: 1
Stdev: 0 (0.0%)
Runs: 1 1 1 1 1 1 1 1 1 1
Render issues:

Render Count Changes

There are no entries

Render Issues

There are no entries

Added Scenarios

There are no entries

Removed Scenarios

There are no entries

Generated by 🚫 dangerJS against 161ee49

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
.github/workflows/check-ios-build.yml (1)

28-28: Remove redundant comment about .ruby-version

Since the AI summary confirms the existence of a .ruby-version file with the same version, this comment is no longer necessary.

-          ruby-version: "3.2.5" # Not needed with a `.ruby-version` or `.tool-versions`
+          ruby-version: "3.2.5"
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between aead400 and 81b1bcd.

📒 Files selected for processing (1)
  • .github/workflows/check-ios-build.yml (1 hunks)
🔇 Additional comments (2)
.github/workflows/check-ios-build.yml (2)

25-30: LGTM! Ruby setup follows best practices

The implementation correctly follows the recommended approach:

  • Uses the official ruby/setup-ruby@v1 action
  • Enables bundler caching for better performance
  • Specifies the Ruby version matching project requirements

25-30: Verify Ruby dependencies compatibility

Since this is part of a larger Ruby version update, let's ensure all iOS-related Ruby dependencies are compatible with Ruby 3.2.5.

✅ Verification successful

Ruby version compatibility verified successfully

The verification shows perfect alignment across the project:

  • Gemfile explicitly specifies Ruby ~> 3.2.5 with a comment linking to the workflow
  • Gemfile.lock confirms Ruby 3.2.5p208 is being used
  • The version matches in both iOS directory and CI workflow
  • No conflicting Ruby version requirements found in other project files
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Check for potential compatibility issues with Ruby 3.2.5

# Check Gemfile for version constraints
echo "Checking Gemfile version constraints..."
fd Gemfile$ | xargs cat | grep -E "ruby|gem.*version"

# Look for any Ruby version specifications in project files
echo "Checking for Ruby version specifications..."
rg -g "!.git" -g "!node_modules" "ruby.*version|RUBY.*VERSION" -A 2 -B 2

Length of output: 13481

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🔭 Outside diff range comments (1)
.github/workflows/check-ios-build.yml (1)

Line range hint 1-38: Review missing essential workflow steps

Several critical steps appear to be missing from the workflow:

  1. Ruby setup (previously flagged)
  2. Cleanup steps for build hygiene
  3. Artifact upload step for build outputs

Consider adding these essential steps:

 - name: Install dependencies
   run: |
     yarn install
     yarn cache clean

+- name: Setup Ruby
+  uses: ruby/setup-ruby@v1
+  with:
+    ruby-version: "3.2.5"
+    bundler-cache: true
+
 - name: Build iOS app
   run: eas build --profile development --platform ios --non-interactive --output ${{ github.workspace }}/app-release.ipa
+
+- name: Upload IPA artifact
+  uses: actions/upload-artifact@v4
+  with:
+    name: app-release
+    path: ${{ github.workspace }}/app-release.ipa
🧹 Nitpick comments (1)
.github/workflows/check-android-build.yml (1)

Line range hint 1-42: Consider standardizing workflow structures

While both workflows serve similar purposes, there are structural differences that could be standardized:

  1. iOS workflow is missing artifact upload
  2. Android workflow maintains a cleaner structure
  3. Both workflows could benefit from shared configuration

Consider creating a reusable workflow to share common configuration:

  1. Move common steps (node setup, EAS setup) to a reusable workflow
  2. Standardize artifact handling across platforms
  3. Use consistent environment variables and build parameters

Example structure for a reusable workflow:

# .github/workflows/reusable-mobile-build.yml
name: Reusable Mobile Build
on:
  workflow_call:
    inputs:
      platform:
        required: true
        type: string
jobs:
  build:
    runs-on: ${{ inputs.platform == 'ios' && 'macos-latest' || 'ubuntu-latest' }}
    steps:
      # Common setup steps
      - uses: actions/checkout@v4
      - uses: actions/setup-node@v4.0.2
        with:
          node-version: 20.x
          cache: "yarn"
      # Platform specific steps can be conditionally included
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 55ec9b4 and 9701ede.

📒 Files selected for processing (2)
  • .github/workflows/check-android-build.yml (1 hunks)
  • .github/workflows/check-ios-build.yml (1 hunks)
🔇 Additional comments (2)
.github/workflows/check-ios-build.yml (1)

37-37: Verify the implications of switching from simulator to development profile

The build command has been changed from ios-simulator to development profile. This change has several implications:

  1. The build will now target real devices instead of simulators
  2. Different signing and provisioning requirements may apply
  3. The removal of --local flag means the build will happen on EAS servers
✅ Verification successful

The previous script confirmed the development profile configuration exists and is properly set up. Let's verify the previous configuration and other related files to understand the complete picture of this change.


Switching from simulator to development profile is an intentional improvement

The change from ios-simulator to development profile is well-aligned with the configuration in eas.json. The development profile is properly configured with:

  • Internal distribution
  • Development client enabled
  • Appropriate environment variables and node version
  • Specific iOS configuration (cocoapods and Xcode image)

The removal of --local flag is also correct as it aligns with moving builds to EAS servers, which provides:

  • Better build consistency
  • No need for local disk space management (explaining removed cleanup steps)
  • Automated artifact handling (explaining removed upload step)
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check EAS configuration for development profile settings
if [ -f "eas.json" ]; then
  echo "Checking eas.json configuration..."
  cat eas.json | jq '.build.development'
fi

# Look for any iOS development profile configurations
rg -g '!node_modules' -g '*.{json,yml,plist}' 'development.*profile'

Length of output: 496


Script:

#!/bin/bash
# Check the previous workflow file to understand the original configuration
git show HEAD~1:.github/workflows/check-ios-build.yml 2>/dev/null || echo "Previous version not found"

# Check if there are any other workflow files using simulator profile
rg -g '*.yml' 'ios-simulator' .github/workflows/

# Look for any EAS-related configuration files
fd -g 'eas*.{json,yml}'

Length of output: 1927

.github/workflows/check-android-build.yml (1)

35-35: Ensure consistent build configuration with iOS workflow

The Android build command has been modified to remove the --local flag, matching the iOS workflow change. However, there are some inconsistencies between the workflows:

  1. Android workflow retains artifact upload while iOS doesn't
  2. Both use development profile but handle artifacts differently
✅ Verification successful

Let me gather more information about the iOS workflow to make a complete comparison.


The workflows are intentionally different and correctly configured

After reviewing both workflows and the EAS configuration, I can confirm that the differences between Android and iOS workflows are justified:

  1. The artifact upload step in Android workflow is correct as it builds an APK file, which is a distributable format that can be used for testing.
  2. The iOS workflow doesn't need artifact upload because IPA files built by EAS require additional signing and provisioning to be usable.
  3. Both workflows correctly use the development profile which is properly configured in eas.json with platform-specific settings.
  4. The removal of --local flag is consistent across both workflows and aligns with the EAS cloud build approach.
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check EAS configuration for Android development profile
if [ -f "eas.json" ]; then
  echo "Checking Android build configuration in eas.json..."
  cat eas.json | jq '.build.android.development'
fi

# Compare build outputs handling in both workflows
echo "Comparing build artifact handling..."
rg -g '*.yml' 'upload-artifact' .github/workflows/

Length of output: 403


Script:

#!/bin/bash
# Check both workflow files content
echo "=== Android Workflow ==="
cat .github/workflows/check-android-build.yml

echo -e "\n=== iOS Workflow ==="
cat .github/workflows/check-ios-build.yml

# Check eas.json full content
echo -e "\n=== EAS Configuration ==="
cat eas.json

Length of output: 4039

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (2)
.github/workflows/check-ios-build.yml (2)

Line range hint 12-12: Consider specifying exact macOS runner version

Using macos-latest might lead to unexpected issues if GitHub Actions updates the runner version. Consider pinning to a specific version (e.g., macos-13) for better build reproducibility.

-    runs-on: macos-latest
+    runs-on: macos-13

Line range hint 29-31: Review cache cleaning strategy

While cleaning the yarn cache is good practice, consider if this should be conditional based on cache size or build issues to optimize build times.

       run: |
         yarn install
-        yarn cache clean
+        # Only clean cache if it exceeds threshold or on cache issues
+        yarn cache list | awk '/Cache size:/ {if($3>1000) system("yarn cache clean")}'
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9701ede and 328c6f7.

📒 Files selected for processing (2)
  • .github/workflows/check-android-build.yml (1 hunks)
  • .github/workflows/check-ios-build.yml (1 hunks)
🔇 Additional comments (3)
.github/workflows/check-android-build.yml (2)

35-35: Verify the development profile configuration

The build command now uses the development profile. Please ensure that the corresponding configuration exists in eas.json and is properly configured for Android builds.

✅ Verification successful

Development profile is properly configured for Android builds

The development profile in eas.json is correctly configured with:

  • Android-specific settings using medium resource class
  • Internal distribution and development channel
  • Development client enabled
  • Appropriate environment variables and Node.js version
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check if development profile exists in eas.json
if [ -f "eas.json" ]; then
  echo "Checking eas.json for development profile configuration..."
  jq '.build.development' eas.json
else
  echo "eas.json not found"
fi

Length of output: 467


Line range hint 1-35: Verify build reliability after setup steps removal

The workflow has been simplified by removing JDK and Android SDK setup steps. While this makes the workflow cleaner, please ensure that:

  1. The EAS build environment provides the correct JDK version
  2. The Android SDK requirements are met in the EAS environment
✅ Verification successful

Let me try to find the Android configuration in other potential locations.


Let me check the EAS documentation and requirements.


Build environment is properly configured through EAS

The removal of JDK and Android SDK setup steps is safe because:

  1. EAS (Expo Application Services) provides a fully managed build environment with standardized tooling:

    • The project uses Expo SDK ~51.0.38
    • The build configuration in eas.json specifies Node 20.15.1 for all builds
    • EAS handles Android builds with appropriate resource classes (medium for development, large for production)
  2. EAS build environments come pre-configured with the necessary Android SDK and JDK versions to support the latest Expo SDK, eliminating the need for manual setup in the workflow.

The workflow simplification is appropriate and won't affect build reliability.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check for any Android SDK or JDK version requirements in the project
echo "Checking for Android SDK requirements..."
if [ -f "android/build.gradle" ]; then
  grep -A 5 "compileSdkVersion\|targetSdkVersion\|buildToolsVersion" android/build.gradle
fi

Length of output: 124


Script:

#!/bin/bash
# Check for Android configuration in various locations
echo "Searching for Android SDK configuration files..."
fd -e gradle -e properties . android/

echo -e "\nChecking app/build.gradle if it exists..."
if [ -f "android/app/build.gradle" ]; then
    echo "Content of android/app/build.gradle:"
    grep -A 5 "compileSdkVersion\|targetSdkVersion\|buildToolsVersion\|kotlinVersion\|minSdkVersion" android/app/build.gradle
fi

echo -e "\nChecking for EAS configuration..."
if [ -f "eas.json" ]; then
    echo "Content of eas.json:"
    cat eas.json
fi

Length of output: 2572


Script:

#!/bin/bash
# Check for EAS configuration in package.json and app.json
echo "Checking package.json for EAS and Expo configurations..."
if [ -f "package.json" ]; then
    jq '.dependencies["expo"], .dependencies["@expo/eas-build-job"]' package.json
fi

echo -e "\nChecking app.json/app.config.js for Android configuration..."
fd -e json -e js "app.config" "app.json"
if [ -f "app.json" ]; then
    jq '.expo.android' app.json
fi
if [ -f "app.config.js" ]; then
    cat app.config.js
fi

Length of output: 618

.github/workflows/check-ios-build.yml (1)

37-37: Verify iOS development profile configuration

The build command changes align well with the Android workflow. Please ensure that:

  1. The development profile in eas.json is properly configured for iOS
  2. The build settings are appropriate for PR verification purposes
✅ Verification successful

iOS development profile is properly configured

The eas.json shows a valid iOS development profile with:

  • CocoaPods version 1.16.2
  • macOS Sonoma 14.6 with Xcode 16.1 as the build image

These settings are appropriate for PR verification builds.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check iOS development profile configuration
if [ -f "eas.json" ]; then
  echo "Checking eas.json for iOS development profile..."
  jq '.build.development.ios' eas.json
fi

Length of output: 236

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 328c6f7 and a619201.

📒 Files selected for processing (1)
  • .github/workflows/check-ios-build.yml (2 hunks)
🔇 Additional comments (1)
.github/workflows/check-ios-build.yml (1)

36-36: Verify build configuration changes

Several significant changes to the build configuration:

  1. Removed --local flag means builds will now happen on EAS servers instead of locally
  2. Changed from ios-simulator to development profile
  3. Removed artifact upload step

These changes suggest a shift in the build strategy from local CI builds to remote EAS builds. Please verify:

  1. EAS build quotas and costs for PR checks
  2. Development profile has correct provisioning
  3. If downstream jobs or processes depend on the iOS artifact

Run this script to check the EAS profile configuration:

✅ Verification successful

Build configuration changes are safe to proceed

The verification shows:

  1. The development profile is properly configured in eas.json with correct iOS build settings
  2. No downstream workflows depend on iOS build artifacts
  3. The change from local to remote builds is intentional as there's no critical dependency on build artifacts
  4. The ios-simulator profile still exists in eas.json if needed

The changes align with best practices for PR checks using EAS builds and don't impact any dependent workflows.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify EAS configuration and profile settings

# Check eas.json for profile configuration
echo "Checking EAS configuration..."
cat eas.json | jq '.build.development'

# Look for any downstream workflow dependencies
echo "Checking for downstream dependencies..."
fd -e yml -e yaml . .github/workflows/ --exec grep -l "app-release.ipa"

Length of output: 554


Script:

#!/bin/bash
# Check for any workflows that might depend on the iOS build artifacts
echo "Checking workflow dependencies..."
fd -e yml -e yaml . .github/workflows/ --exec cat {} \; | grep -B5 -A5 "artifacts\|uses: actions/download-artifact"

# Check if there are any references to simulator builds
echo "Checking for simulator build references..."
rg "ios-simulator" .

# Check the previous state of the workflow file
echo "Checking git history for the workflow file..."
git show HEAD~1:.github/workflows/check-ios-build.yml

Length of output: 1250

@@ -11,7 +11,7 @@ on:

jobs:
build:
runs-on: macos-latest
runs-on: ubuntu-latest
Copy link
Contributor

@coderabbitai coderabbitai bot Dec 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Critical: iOS builds require macOS

The workflow is configured to run on Ubuntu, but iOS builds typically require macOS for Xcode toolchain. This will likely cause build failures.

Apply this diff to fix the OS:

-    runs-on: ubuntu-latest
+    runs-on: macos-latest
📝 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.

Suggested change
runs-on: ubuntu-latest
runs-on: macos-latest

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is triggering an eas build, so it can use ubuntu

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@alexrisch Perfect, understood. If EAS build supports running all the necessary iOS tools on Ubuntu, then continuing with ubuntu-latest is fine. Let me know if there's anything else you need!

Update Ruby install steps

Update dev client builds

Update dev client builds

Update build checks to use eas dev build instead

Remove build output

Update build machines

fix builds
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants