react-native: Error creating LLDB target at path

Description

When iOS app is build, it crashed on start and get this logs in XCode

Warning: Error creating LLDB target at path '/Users/damirrigo/Library/Developer/Xcode/DerivedData/loyalty-eqbitahuqdywnefiuzwugdkdjweh/Build/Products/Debug-prod-iphonesimulator/loyalty.app'- using an empty LLDB target which can cause slow memory reads from remote devices.
2023-08-28 10:38:08.771130+0200 loyalty[26420:1628391] [native] No bundle URL present.

Make sure you're running a packager server or have included a .jsbundle file in your application bundle.
2023-08-28 10:38:08.776539+0200 loyalty[26420:1628391] *** Terminating app due to uncaught exception 'RCTFatalException: No bundle URL present.

Make sure you're running a packager server or have included a .jsbundle file in your application bundle.', reason: 'No bundle URL present.

Make sure you're running a packager server or have included a .jsbundle file in your application bundle.'
*** First throw call stack:
(
	0   CoreFoundation                      0x000000010e1bc78b __exceptionPreprocess + 242
	1   libobjc.A.dylib                     0x000000010c5a3b73 objc_exception_throw + 48
	2   loyalty                             0x0000000100bb23f5 RCTGetFatalHandler + 0
	3   loyalty                             0x0000000100bcbbd5 __28-[RCTCxxBridge handleError:]_block_invoke + 581
	4   libdispatch.dylib                   0x00000001105a954f _dispatch_call_block_and_release + 12
	5   libdispatch.dylib                   0x00000001105aa7ec _dispatch_client_callout + 8
	6   libdispatch.dylib                   0x00000001105bb6e2 _dispatch_main_queue_drain + 1462
	7   libdispatch.dylib                   0x00000001105bb11e _dispatch_main_queue_callback_4CF + 31
	8   CoreFoundation                      0x000000010e11a6cc __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
	9   CoreFoundation                      0x000000010e114fbe __CFRunLoopRun + 2429
	10  CoreFoundation                      0x000000010e114264 CFRunLoopRunSpecific + 560
	11  GraphicsServices                    0x0000000114b8e24e GSEventRunModal + 139
	12  UIKitCore                           0x00000001233bd7bf -[UIApplication _run] + 994
	13  UIKitCore                           0x00000001233c25de UIApplicationMain + 123
	14  loyalty                             0x0000000100afc2b0 main + 96
	15  dyld                                0x000000010adb7384 start_sim + 10
	16  ???                                 0x0000000202854310 0x0 + 8632222480
)
libc++abi: terminating due to uncaught exception of type NSException
Message from debugger: Terminated due to signal 6

React Native Version

0.71.6

Output of npx react-native info

System: OS: macOS 13.1 CPU: (8) arm64 Apple M1 Pro Memory: 255.19 MB / 32.00 GB Shell: 5.8.1 - /bin/zsh Binaries: Node: 16.17.0 - ~/.nvm/versions/node/v16.17.0/bin/node Yarn: 1.22.18 - /opt/homebrew/bin/yarn npm: 8.15.0 - ~/.nvm/versions/node/v16.17.0/bin/npm Watchman: 2023.05.15.00 - /opt/homebrew/bin/watchman Managers: CocoaPods: 1.11.3 - /opt/homebrew/bin/pod SDKs: iOS SDK: Platforms: DriverKit 22.4, iOS 16.4, macOS 13.3, tvOS 16.4, watchOS 9.4 Android SDK: API Levels: 28, 29, 30, 31, 32, 33 Build Tools: 28.0.2, 30.0.2, 30.0.3, 31.0.0, 32.0.0, 32.1.0, 33.0.0 System Images: android-28 | Google ARM64-V8a Play ARM 64 v8a, android-30 | Google APIs Intel x86 Atom, android-32 | Google APIs ARM 64 v8a, android-32 | Google Play ARM 64 v8a Android NDK: Not Found IDEs: Android Studio: 2021.3 AI-213.7172.25.2113.9123335 Xcode: 14.3.1/14E300c - /usr/bin/xcodebuild Languages: Java: 19.0.1 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: 18.2.0 => 18.2.0 react-native: 0.71.6 => 0.71.6 react-native-macos: Not Found npmGlobalPackages: react-native: Not Found

Steps to reproduce

Install deps and pods in app then run the app inside XCode.

Snack, screenshot, or link to a repository

https://github.com/facebook/react-native/assets/11744443/cb0c70f2-6022-4ba5-bd6b-e40d8e4dbafc

About this issue

  • Original URL
  • State: open
  • Created 10 months ago
  • Reactions: 1
  • Comments: 20 (2 by maintainers)

Most upvoted comments

Any updates? I face the same error message when I upgrade to Xcode15, everything in the old Xcode(14.1) is working fine. I cleared all cache in Pods/ builds/ in iOS but it still does not work. The app was built successfully but when it started splashing the screen hung out and then forced shutdown. Note: I use MacOS Sonoma 14 with M1 Pro

Warning: Error creating LLDB target at path ‘/Debug-iphonesimulator/demo.app’- using an empty LLDB target which can cause slow memory reads from remote devices. objc[40577]: Swift class extensions and categories on Swift classes are not allowed to have +load methods Message from debugger: Terminated due to signal 6

I have the same problem here!

Note: I use MacOS Sonoma with M2 Pro

@rigodamir the “LLDB target at path” warning is not the issue here, as that warning will slow down development but not crash the app. The real issue here is the next errors in the console:

No bundle URL present.

and

Make sure you’re running a packager server or have included a .jsbundle file in your application bundle.

This happens when (for example) you have not provided a valid bundleURL to initWithBundleURL, but I’d need to see the code for your AppDelegate to help debug it more.