React-native: Post 0.43 upgrade: PerfMonitor has no setter or ivar for its bridge

Created on 7 Apr 2017  路  12Comments  路  Source: facebook/react-native

Description

After upgrading to React Native version 0.43, getting the red screen with error: "PerfMonitor has no setter or ivar for its bridge, which is not permitted. You must either @synthesize the bridge property, or provide your own setter method".

screen shot 2017-04-07 at 10 04 58 am

Reproduction Steps

Upgraded from version 0.42.3 using react-native-git-upgrade. There were no conflicts. Then ran "react-native link".

Additional Information

  • React Native version: 43
  • Platform: iOS
  • Development Operating System: MacOS
Locked

Most helpful comment

@Mindaugas-Jacionis That's because xcode and react-native store the built binaries in different folders. react-native stores in your-project-folder/ios/build/, but xcode stores in ~/Library/Developer/Xcode/DerivedData. You need to remove your-project-folder/ios/build/ for react-native to work

All 12 comments

It looks like this line is swallowing the original exception: https://github.com/facebook/react-native/blob/master/React/Base/RCTModuleData.mm#L149-L153

Can you comment that try-catch to find the real underlying exception?

Hi guys, I'm having the same issue, have you found a way to fix it?

Resetting the simulator (probably unnecessary) + deleting the ios/build folder worked for me.
And the usual:

watchman watch-del-all
rm -rf node_modules
yarn
npm start -- --reset-cache

Awesome, you right. That worked for me!

Thanks

The following steps worked for me.

  • clean xcode project
  • stop node package manager
  • rm -rf node_modules
  • yarn
  • restart project in simulator

Running via Xcode helped me.

After trying everything (rm node_module etc, clean, change the version of react-native (higher, lower, ....) dozen times. I can say the only thing WORKING for me is DELETING the IOS/BUILD folder.

Hope that help!.

Another solution is via Xcode menu bar : Product > Clean. Worked for me.

It is odd, because I get this error with RN 0.44.0 and only when running react-native run-ios command from terminal, if I am building using xcode - all is good.

@Mindaugas-Jacionis That's because xcode and react-native store the built binaries in different folders. react-native stores in your-project-folder/ios/build/, but xcode stores in ~/Library/Developer/Xcode/DerivedData. You need to remove your-project-folder/ios/build/ for react-native to work

@hyb175 you're awesome! Thanks! :)

@hyb175 Your suggestion worked for me. Thanks.

Was this page helpful?
0 / 5 - 0 ratings