CodexBloom - Programming Q&A Platform

iOS 17: Issues with integrating Firebase Crashlytics in a SwiftUI app not capturing crashes

👀 Views: 0 đŸ’Ŧ Answers: 1 📅 Created: 2025-06-11
ios swiftui firebase swift

Can someone help me understand I'm currently integrating Firebase Crashlytics into my SwiftUI app, but I'm not able to capture any crashes. I've followed the setup guide meticulously, including adding the necessary Firebase pods to my Podfile: ```ruby pod 'Firebase/Core' pod 'Firebase/Crashlytics' ``` After running `pod install`, I initialized Firebase in the AppDelegate with: ```swift import Firebase @main struct MyApp: App { @UIApplicationDelegateAdaptor(AppDelegate.self) var appDelegate var body: some Scene { WindowGroup { ContentView() } } } class AppDelegate: NSObject, UIApplicationDelegate { func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { FirebaseApp.configure() return true } } ``` I also ensured that I have the correct `GoogleService-Info.plist` added to my project. However, when I force a crash in my ContentView using: ```swift Button(action: { let _ = NSException(name: .generic, reason: "Forced crash for testing", userInfo: nil) }) { Text("Crash Now") } ``` Nothing shows up in the Firebase console. I've checked my internet connection and ensured that the app has the proper permissions. I've even tried cleaning the build folder and uninstalling/reinstalling the app to reset any cached configurations, but still no luck. I'm using Xcode 15 and Swift 5.8. Is there something I'm missing or any additional configurations I need to check? Am I approaching this the right way?