chore: upgrade react native to 0.81.5#142
Conversation
|
Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. WalkthroughRemoves the debug Android manifest, adds a configurable cleartext traffic placeholder to the main Android manifest, bumps React Native from 0.81.0 → 0.81.5 in project and example, raises the example Node engine requirement to >=20, and consolidates and reworks the iOS CI workflow into a matrix build with Ruby update and conditional Podfile tweak. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant GH as GitHub Actions
participant Runner as Runner
participant Shell as Shell/Steps
participant Xcode as xcodebuild
note over GH,Runner `#DDEBF7`: Trigger (push / workflow_dispatch)
GH->>Runner: start workflow
Runner->>Runner: strategy.matrix.arch => [new, old]
alt arch == "old"
Shell->>Shell: modify Podfile to disable new arch
else arch == "new"
Shell->>Shell: leave Podfile unchanged
end
Shell->>Shell: install dependencies (bun)
Shell->>Shell: run pod install (no cache restore)
Shell->>Xcode: run xcodebuild on NitroTextExample workspace & scheme
Xcode-->>Runner: build result
Runner-->>GH: workflow outcome
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 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 ignored due to path filters (1)
📒 Files selected for processing (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). (4)
🔇 Additional comments (8)
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.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (2)
bun.lockis excluded by!**/*.lockexample/ios/Podfile.lockis excluded by!**/*.lock
📒 Files selected for processing (4)
example/android/app/src/debug/AndroidManifest.xml(0 hunks)example/android/app/src/main/AndroidManifest.xml(1 hunks)example/package.json(3 hunks)package.json(1 hunks)
💤 Files with no reviewable changes (1)
- example/android/app/src/debug/AndroidManifest.xml
⏰ 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). (2)
- GitHub Check: Build Android Example App (new architecture)
- GitHub Check: Build Android Example App (old architecture)
🔇 Additional comments (2)
package.json (1)
63-63: Verify Node.js engine requirement for consistency.React Native 0.81 requires Node.js version 20.19.4 or higher. The root
package.jsonupgrades to React Native 0.81.5 but lacks anengines.nodefield, unlike the example app'spackage.json. While this distinction may be intentional for a library (to avoid constraining consuming projects), consider whether explicitly documenting the Node requirement would improve clarity for contributors and CI pipelines.example/package.json (1)
15-15: Good alignment of React Native dependencies and Node engine upgrade.The updates correctly bump React Native to 0.81.5 across the runtime and all @react-native/* devDependencies, and the Node engine requirement is appropriately raised to >=20, which aligns with React Native 0.81's requirement for Node.js version 20.19.4 or higher. The React 19.1.0 version is compatible with this toolchain.
Verify that your CI pipelines and development setup documentation are also updated to enforce Node.js >=20 for builds and developer machines.
Also applies to: 27-30, 42-42
| android:roundIcon="@mipmap/ic_launcher_round" | ||
| android:allowBackup="false" | ||
| android:theme="@style/AppTheme" | ||
| android:usesCleartextTraffic="${usesCleartextTraffic}" |
There was a problem hiding this comment.
🧩 Analysis chain
Verify Gradle placeholder is configured in build scripts.
The manifest placeholder ${usesCleartextTraffic} requires corresponding build configuration to resolve this value at build time. Without proper Gradle configuration, the build may fail or the placeholder may remain unresolved.
Please verify that example/android/app/build.gradle (or similar Gradle configuration) defines the usesCleartextTraffic placeholder with an appropriate value (e.g., true for development, false for production).
Run the following script to check for the property definition:
🏁 Script executed:
#!/bin/bash
# Description: Search for usesCleartextTraffic property in Android build configuration files
echo "Checking for usesCleartextTraffic in gradle files..."
rg -n "usesCleartextTraffic" example/android/app/build.gradle* example/android/gradle.properties --type gradle --type properties
echo ""
echo "Checking for manifestPlaceholders in gradle files..."
rg -n "manifestPlaceholders" example/android/app/build.gradle* --type gradle
echo ""
echo "Checking for resValue definitions in gradle files..."
rg -n "resValue" example/android/app/build.gradle* --type gradleLength of output: 195
I'll explore the Android build structure to verify the Gradle configuration:
Now let me search the repository for gradle files and their contents:
---
🏁 Script executed:
```shell
#!/bin/bash
# Find all gradle files in the Android app directory
echo "Finding gradle files in example/android/app/..."
fd -e gradle -e properties example/android/app/
echo ""
echo "Listing all files in example/android/app/ directory:"
ls -la example/android/app/ 2>/dev/null || echo "Directory not found"
Length of output: 846
Now let me examine the build.gradle file to check for the manifestPlaceholders configuration:
---
🏁 Script executed:
```shell
#!/bin/bash
# Examine the build.gradle file content
echo "Contents of example/android/app/build.gradle:"
cat example/android/app/build.gradle
echo ""
echo "Searching for manifestPlaceholders or usesCleartextTraffic in build.gradle:"
rg -n "manifestPlaceholders|usesCleartextTraffic" example/android/app/build.gradle
Length of output: 4816
Add manifestPlaceholders configuration to build.gradle to resolve the ${usesCleartextTraffic} placeholder.
The build.gradle file does not contain any manifestPlaceholders configuration. The android:usesCleartextTraffic="${usesCleartextTraffic}" placeholder in AndroidManifest.xml will remain unresolved at build time, causing the build to fail. Add the following to example/android/app/build.gradle in the defaultConfig block (or appropriate buildType/productFlavor):
manifestPlaceholders = [usesCleartextTraffic: "false"]Adjust the value (true for development, false for production) as appropriate for your build configuration.
🤖 Prompt for AI Agents
In example/android/app/src/main/AndroidManifest.xml around line 12 the attribute
android:usesCleartextTraffic="${usesCleartextTraffic}" uses an unresolved
manifest placeholder; update example/android/app/build.gradle (app module) to
add a manifestPlaceholders entry (inside defaultConfig or the appropriate
buildType/productFlavor) that defines usesCleartextTraffic with the desired
value (e.g., "false" for production or "true" for development) so the
placeholder is resolved at build time.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| android:allowBackup="false" | ||
| android:theme="@style/AppTheme" | ||
| android:usesCleartextTraffic="${usesCleartextTraffic}" |
There was a problem hiding this comment.
Define usesCleartextTraffic manifest placeholder
The Android manifest now sets android:usesCleartextTraffic="${usesCleartextTraffic}", but the app’s Gradle config does not declare any manifestPlaceholders value for usesCleartextTraffic (nothing in example/android/app/build.gradle and rg "manifestPlaceholders" example/android returns empty). The manifest merger treats unresolved placeholders as errors, so every Android build will fail during manifest processing until a default value is provided or the substitution is removed.
Useful? React with 👍 / 👎.
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 (1)
.github/workflows/ios-build.yml(2 hunks)
🔇 Additional comments (4)
.github/workflows/ios-build.yml (4)
81-87: Clarify why CocoaPods caching has been disabled.The CocoaPods cache section (lines 81–87) is now commented out. This may impact build performance and reliability. Please clarify:
- Was caching disabled intentionally due to cache invalidation or environment issues?
- Is this temporary until cache issues are resolved, or a permanent change?
- Are there any known issues with CocoaPods caching on macOS-15 or Ruby 3.2?
49-55: Matrix build consolidation improves maintainability.The migration from dual separate jobs to a single matrix-based job with
arch: [new, old]is a good refactoring that eliminates duplication and centralizes the build logic. Thefail-fast: falsesetting ensures both architecture variants are tested even if one fails.
3-4: Permissions and workflow_dispatch additions are reasonable.Adding minimal
contents: readpermissions andworkflow_dispatchtrigger follows best practices for GitHub Actions security and manual workflow invocation.Also applies to: 39-39
74-74: Ruby version upgrade to 3.2 is appropriate and gem compatibility is confirmed.Verification confirms all bundled gems in Gemfile.lock are compatible with Ruby 3.2. The Gemfile specifies
ruby ">= 2.6.10"(allowing Ruby 3.2), and the current lock file is pinned to Ruby 3.3.6, which is newer than 3.2 and demonstrates compatibility. All gem constraints (activesupport 7.2.3, cocoapods, xcodeproj, concurrent-ruby) are satisfied for Ruby 3.2.
Description
This PR upgrades React Native from 0.81.0 to 0.81.5.
Changes
>=18to>=20Testing
Related
Upgrades React Native to the latest patch version 0.81.5.
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.