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

Can't build xcode project & can't pod install since update from react-native 0.72.4 to 0.73.6 #43670

Closed
gorbat-o opened this issue Mar 27, 2024 · 4 comments
Labels
Resolution: Issue in another tool or repo An issue that was opened against React Native but in reality is affecting another tool or library

Comments

@gorbat-o
Copy link

gorbat-o commented Mar 27, 2024

Description

I opened a project i worked on 3 weeks ago. I had to do a small update on the UI. I was running react-native 0.72.4 and I can't run the project in xcode because I have the following issue (I tried all the clean up possible):

image

so I followed the following issue #43335 but it made it worse

Basically I tried removed all pods/node_modules and npm install + pod install and I got the error below

[!] CocoaPods could not find compatible versions for pod "RCT-Folly":
  In snapshot (Podfile.lock):
    RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)

  In Podfile:
    RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)

It seems like you've changed the version of the dependency `RCT-Folly` and it differs from the version stored in `Pods/Local Podspecs`.
You should run `pod update RCT-Folly --no-repo-update` to apply changes made locally.

The android ./gradlew clean fails too


FAILURE: Build completed with 3 failures.

1: Task failed with an exception.
-----------
* Where:
Build file '/Users/user/Work/_/_/_.react.native/node_modules/expo-modules-core/android/build.gradle' line: 372

* What went wrong:
A problem occurred evaluating project ':expo-modules-core'.
> Cannot invoke method replace() on null object

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
==============================================================================

2: Task failed with an exception.
-----------
* What went wrong:
A problem occurred configuring project ':expo'.
> compileSdkVersion is not specified. Please add it to build.gradle

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
==============================================================================

3: Task failed with an exception.
-----------
* What went wrong:
Failed to query the value of property 'buildFlowServiceProperty'.
> Could not isolate value org.jetbrains.kotlin.gradle.plugin.statistics.BuildFlowService$Parameters_Decorated@751767a7 of type BuildFlowService.Parameters
   > A problem occurred configuring project ':expo'.
      > compileSdkVersion is not specified. Please add it to build.gradle

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
==============================================================================

* Get more help at https://help.gradle.org

BUILD FAILED in 12s
5 actionable tasks: 5 executed

Steps to reproduce

npm install react-native@latest --save
then npm update
then got the new error when doing pod install

Using Expo modules
[Expo] Enabling modular headers for pod ExpoModulesCore
[Expo] Enabling modular headers for pod EXImageLoader
[Expo] Enabling modular headers for pod ZXingObjC
(node:31139) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
Auto-linking React Native modules for target `waxie`: RNCAsyncStorage, RNDeviceInfo, RNGestureHandler, RNReanimated, RNSVG, RNScreens, react-native-netinfo, and react-native-safe-area-context
get_default_flags is deprecated. Please remove the keys from the `use_react_native!` function
if you are using the default already and pass the value you need in case you don't want the default
Framework build type is static library
[Codegen] Generating ./build/generated/ios/React-Codegen.podspec.json
[Codegen] generating an empty RCTThirdPartyFabricComponentsProvider
Analyzing dependencies
Invoke detect_changes_with_podfile patched method
[Codegen] Found FBReactNativeSpec
Fetching podspec for `RCT-Folly` from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`
[Codegen] Found rncore
Fetching podspec for `boost` from `../node_modules/react-native/third-party-podspecs/boost.podspec`
Fetching podspec for `hermes-engine` from `../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec`
[Hermes] Using release tarball from URL: https://repo1.maven.org/maven2/com/facebook/react/react-native-artifacts/0.73.6/react-native-artifacts-0.73.6-hermes-ios-debug.tar.gz
[!] CocoaPods could not find compatible versions for pod "React-Mapbuffer":
  In Podfile:
    React-Mapbuffer (from `../node_modules/react-native/ReactCommon`)

Specs satisfying the `React-Mapbuffer (from `../node_modules/react-native/ReactCommon`)` dependency were found, but they required a higher minimum deployment target.

after that I bundle update
then pod install --repo-update
it gets worse lol

[!] CocoaPods could not find compatible versions for pod "RCT-Folly":
  In snapshot (Podfile.lock):
    RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)

  In Podfile:
    RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)

It seems like you've changed the version of the dependency `RCT-Folly` and it differs from the version stored in `Pods/Local Podspecs`.
You should run `pod update RCT-Folly --no-repo-update` to apply changes made locally.

this is a nightmare

then I deleted podfile.lock + /Pods
and ran the pod install --repo-update

[!] CocoaPods could not find compatible versions for pod "RCTRequired":
  In Podfile:
    RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`)

Specs satisfying the `RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`)` dependency were found, but they required a higher minimum deployment target.

and I followed this thread too #42048
doesn't help either.

image

React Native Version

0.73.6

Affected Platforms

Runtime - iOS

Output of npx react-native info

(node:29863) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
System:
  OS: macOS 14.4.1
  CPU: (14) arm64 Apple M3 Max
  Memory: 381.78 MB / 36.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 21.5.0
    path: ~/n/bin/node
  Yarn: Not Found
  npm:
    version: 10.3.0
    path: ~/n/bin/npm
  Watchman: Not Found
Managers:
  CocoaPods:
    version: 1.15.2
    path: /Users/_/.rbenv/shims/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 23.4
      - iOS 17.4
      - macOS 14.4
      - tvOS 17.4
      - visionOS 1.1
      - watchOS 10.4
  Android SDK:
    API Levels:
      - "33"
      - "34"
    Build Tools:
      - 30.0.3
      - 32.0.0
      - 33.0.2
      - 34.0.0
    System Images:
      - android-33 | Google Play ARM 64 v8a
      - android-34 | Google APIs ARM 64 v8a
    Android NDK: Not Found
IDEs:
  Android Studio: 2023.1 AI-231.9392.1.2311.11076708
  Xcode:
    version: 15.3/15E204a
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 17.0.10
    path: /opt/homebrew/opt/openjdk@17/bin/javac
  Ruby:
    version: 3.2.2
    path: /Users/_/.rbenv/shims/ruby
npmPackages:
  "@react-native-community/cli": Not Found
  react:
    installed: 18.2.0
    wanted: 18.2.0
  react-native:
    installed: 0.72.4
    wanted: 0.72.4
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: false
iOS:
  hermesEnabled: true
  newArchEnabled: false

I then ran export NO_FLIPPER=1
and then pod install again
new error for fun

[!] CocoaPods could not find compatible versions for pod "React-FabricImage":
  In Podfile:
    React-FabricImage (from `../node_modules/react-native/ReactCommon`)

Specs satisfying the `React-FabricImage (from `../node_modules/react-native/ReactCommon`)` dependency were found, but they required a higher minimum deployment target.

Stacktrace or Logs

[!] CocoaPods could not find compatible versions for pod "RCT-Folly":
  In snapshot (Podfile.lock):
    RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)

  In Podfile:
    RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`)

It seems like you've changed the version of the dependency `RCT-Folly` and it differs from the version stored in `Pods/Local Podspecs`.
You should run `pod update RCT-Folly --no-repo-update` to apply changes made locally.

Reproducer

Screenshots and Videos

No response

@github-actions github-actions bot added Needs: Author Feedback Needs: Repro This issue could be improved with a clear list of steps to reproduce the issue. labels Mar 27, 2024
Copy link

⚠️ Missing Reproducible Example
ℹ️ We could not detect a reproducible example in your issue report. Please provide either:
  • If your bug is UI related: a Snack
  • If your bug is build/update related: use our Reproducer Template. A reproducer needs to be in a GitHub repository under your username.

@github-actions github-actions bot added Needs: Attention Issues where the author has responded to feedback. and removed Needs: Author Feedback labels Mar 27, 2024
@cortinico
Copy link
Contributor

Using Expo modules

As you're on Expo, please open this issue here
https://github.com/expo/expo/issues

@cortinico cortinico added Resolution: Issue in another tool or repo An issue that was opened against React Native but in reality is affecting another tool or library and removed Needs: Triage 🔍 Needs: Repro This issue could be improved with a clear list of steps to reproduce the issue. Needs: Attention Issues where the author has responded to feedback. labels Mar 27, 2024
@jimbengtsson92
Copy link

I also have this problem. @gorbat-o did you find a solution? Have you opened an issue in expo?

@gorbat-o
Copy link
Author

gorbat-o commented Mar 28, 2024

@jimbengtsson92
I did the following, and it fixed it somehow:

  • bundle update
  • Updated expo from 49 to 50
  • Updated expo-router from 2.0.4 to 3.4.8
  • Updated react-native from 0.72.4 to 0.73.6
  • Updated react-native-reanimated from 3.3.0 to 3.8.1
  • Deleted Pods, Podfile.lock, Clean Build Xcode folder
  • Updated project iOS minimum deployment to 13.4
  • Updated Podfile
    ** Removed __apply_Xcode_12_5_M1_post_install_workaround(installer)
    ** Updated platform :ios, '13.0' to platform :ios, '13.4'
  • bundle exec pod install --repo-update

I was going off the libs that were problematic. Also, some libraries in my package.json were locked on some version, which there was no good reason for it but I didn't make that decision.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Issue in another tool or repo An issue that was opened against React Native but in reality is affecting another tool or library
Projects
None yet
Development

No branches or pull requests

3 participants