Debugging notes

Top of the callstack, matches Delphine's original error:

*** First throw call stack:
(
	0   CoreFoundation                      0x00000001804b70ec __exceptionPreprocess + 172
	1   libobjc.A.dylib                     0x000000018008ede8 objc_exception_throw + 72
	2   CoreFoundation                      0x00000001804b6c80 -[NSException init] + 0
	3   Foundation                          0x0000000180eaa40c -[NSObject(NSKeyValueCoding) valueForUndefinedKey:] + 188
	4   Foundation                          0x0000000180ea92f0 -[NSObject(NSKeyValueCoding) valueForKey:] + 260

From ChatGPT:

This is the critical line:

You (or system code you're using) tried to access a property using valueForKey:@"someKey" on an object that does not have a matching property or method.

valueForUndefinedKey: is called when the key doesn’t exist, and it throws an exception by default.

Which somewhat matches this comment from Reanimated about React Native linking not working: https://github.com/software-mansion/react-native-screens/issues/2718#issuecomment-2670743681

please notice that the method is not executed on RNSScreenView instancebut rather on regularRCTView`. This indicates that the native dependencies of the project are not linked properly.

Trying this fix: https://github.com/software-mansion/react-native-screens/issues/2718#issuecomment-2671677160. Manually include a dependency provider for RN 0.77: https://reactnative.dev/blog/2025/01/21/version-0.77#rctappdependencyprovider

If this works, then we need to figure out a way to get that to happen in the Expo Prebuild step.

That didn't work. Same error.

Ok, so let's see if I can find RNIBaseView in Xcode.

I found it, and it's definitely symlinked. See here:

Screenshot 2025-05-31 at 7.38.11 PM.png

Ok, now I’m gonna try setting a breakpoint early on in the app lifecycle to see if I can get in before the crash and inspect some values. I’m hoping to more visibly see how the RNIBaseView implementation is (or likely is not) being found.

Putting a breakpoint on apps/example/ios/expomonorepo/AppDelegate.mm:11 and running.

The breakpoint hit before a crash.

I wanted to see if I could get at that value from here, but maybe not. I found this link about using expr instead: https://stackoverflow.com/questions/26493356/xcode-6-1-swift-repl-built-into-the-xcode-debugger-can-inspect-and-manipulate-y/26495479#26495479, so I’ll put that right above that line and see what happens.

Nope, syntax error.

Ah, I see. Use the breakpoint and then (lldb) is at the bottom. So I want to write expr as a prefix to commands there.

Yup, RNIBaseView is not found at this level. See me finding RCTView: