upgrade-support icon indicating copy to clipboard operation
upgrade-support copied to clipboard

React-RCT* error after upgrade from 0.63.4 to 0.64.0

Open albullington opened this issue 3 years ago • 2 comments

Environment

System: OS: macOS 10.15.4 CPU: (12) x64 Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz Memory: 877.97 MB / 16.00 GB Shell: 5.7.1 - /bin/zsh Binaries: Node: 12.13.0 - ~/.nvm/versions/node/v12.13.0/bin/node Yarn: Not Found npm: 6.14.10 - ~/.nvm/versions/node/v12.13.0/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman Managers: CocoaPods: 1.10.1 - /Users/amanda/.rvm/rubies/ruby-2.6.5/bin/pod SDKs: iOS SDK: Platforms: iOS 14.4, DriverKit 20.2, macOS 11.1, tvOS 14.3, watchOS 7.2 Android SDK: Not Found IDEs: Android Studio: 4.1 AI-201.8743.12.41.7042882 Xcode: 12.4/12D4e - /usr/bin/xcodebuild Languages: Java: javac 11 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: ^17.0.1 => 17.0.1 react-native: ^0.64.0 => 0.64.0 react-native-macos: Not Found npmGlobalPackages: react-native: Not Found

Things I’ve done to figure out my issue

  • [X] I used upgrade-helper to do my upgrade.
  • [X] Tried all the possible solutions (upgrading nvm, deleting podfile.lock, etc.) in issue #138
  • [X] Ran pod deintegrate && pod install
  • [X] Deleted derived data and cleaned build folder
  • [X] Googled my specific issue, which shows up as a problem for at least one other user in the "Road to v0.64" discussion on GitMemory but doesn't show a solution

Upgrading version

0.64.0 (from 0.63.4)

Description

When I try to build in XCode, I'm getting a variety of errors that say Cannot find protocol declaration for X and Use of undeclared identifier 'facebook'. Each time I try to run the build, it fails on one of three build targets (either React-RCTNetwork, React-RCTVibration, or React-RCTLinking)

Screen Shot 2021-04-07 at 11 33 08 AM Screen Shot 2021-04-07 at 11 31 49 AM Screen Shot 2021-04-07 at 11 27 02 AM

Similarly, when I try to build with react-native run-ios, I see the following error:

The following build commands failed:
        CompileC /Users/amanda/Library/Developer/Xcode/DerivedData/Seek-deslsekalxbyduderwhcyyskknmr/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/React-RCTLinking.build/Objects-normal/x86_64/RCTLinkingManager.o /Users/amanda/Desktop/Seek/node_modules/react-native/Libraries/LinkingIOS/RCTLinkingManager.mm normal x86_64 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)

Reproducible demo

Upgrade from 0.63.4 to 0.64.0 then execute react-native run-ios or try to build in XCode

albullington avatar Apr 07 '21 18:04 albullington

Check your FBReactNativeSpec.h file is generated correctly.

The facebook namespace is setup there.

This file is generated during the installation inside the node_modules dir (which makes it hard to delete).

When I deleted this file, it regenerated, and solved a bunch of issue similar.

Screen Shot 2021-04-08 at 12 07 43 pm

vjpr avatar Apr 08 '21 10:04 vjpr

@vjpr YOU ARE A LIFE SAVER

OneOfOne avatar Jun 23 '22 01:06 OneOfOne