EddyVerbruggen / nativescript-plugin-firebase

:fire: NativeScript plugin for Firebase
https://firebase.google.com
MIT License
1.01k stars 446 forks source link

Crashlytics: dSYMs not uploaded #698

Open lambourn opened 6 years ago

lambourn commented 6 years ago

The automatic upload of dSYMs is not working for me. I'm using NS 4.0.0, tns-ios 4.0.1, nativescript-firebase-plugin version 5.3.1

When I cd into the directory where the .xcodeproj is located (platforms/ios) and I manually run Pods/Fabric/run I get this output:

2018-05-09 08:33:47.766 uploadDSYM[3057:27643] Fabric.framework/run 1.7.0 (208)
2018-05-09 08:33:47.770 uploadDSYM[3057:27643] Firebase mode detected.
warning: unable to find GoogleService-Info.plist in app bundle, dSYMs will not be uploaded.

@DickSmith is this supposed to "just work"?

DickSmith commented 6 years ago

@lambourn is your GoogleService-Info.plist in App_Resouces/iOS?

lambourn commented 6 years ago

yes, it is.

Firebase as such (Analytics, Crashlytics) is working for iOS. Also, I checked the xcodeproj and the "Configure Crashlytics" step is there (multiple times actually, see #711)

I'm wondering into which app bundle file the Fabric run script actually looks into.

danbockapps commented 5 years ago

Is there a workaround for this? Any way to get Crashlytics to work?

danbockapps commented 5 years ago

I successfully uploaded the dSYM manually by running the upload-symbols script from my terminal, as specified here: https://firebase.google.com/docs/crashlytics/get-deobfuscated-reports?authuser=0

grehce commented 5 years ago

Have the same issue, on upload-symbols run, "error: missing required flag a/api-key"

DickSmith commented 5 years ago

As far as I know, so long as the Fabric pod is present and the App_Resouces/iOS/GoogleService-Info.plist is present then the symbols should upload fine. In fact, the script that I added in the original PR of this may no longer be necessary even (it was how Fabric used to work, but now it might be automatic with Firebase).

Some of it may just be specific libs that are missing the symbols. It's not uncommon to always have some symbols missing on certain binaries/static-libraries that didn't include them in the framework.

Now that {N} 5.2+ has the App_Resources/iOS/Podfile you could try adding this snippet there:

post_install do |installer|
  installer.pods_project.targets.each do |nt|
    nt.build_configurations.each do |config|
      config.build_settings['EXPANDED_CODE_SIGN_IDENTITY']   = ""
      config.build_settings['CODE_SIGNING_REQUIRED']         = "NO"
      config.build_settings['CODE_SIGNING_ALLOWED']          = "NO"
      config.build_settings['ENABLE_BITCODE']                = "NO"
      config.build_settings['DEBUG_INFORMATION_FORMAT']      = "dwarf-with-dsym"
    end
  end
end

In the past (using Crashlytics with both {N} and non-{N} projects), I've found that some combination of these flags generally solve strangenesses with Xcode, Cocoapods, crash reporters, and CI build machines (and especially when using all at the same time).

dimaosa commented 4 years ago

Make sure your Crashlytics Run Script is the last one in Build Phases scripts. That fixes the problem for me.