Unable to upload Crashlytics dSYM file during build phase due to script error
Asked Answered
B

2

7

I'm trying to add Firebase Crashlytics to my Swift 4 iOS app.

I have the SDK installed but I'm having some issues with this dSYM thing, the firebase console tells me I need to upload the dSYM file before I can see any errors.

So I have set up the debug information format to DWARF with dSYM file for both debug and release and still nothing.

So I'm trying to add this script to my build phases (as instructed by Firebase's documentation)

find dSYM_directory -name "*.dSYM" | xargs -I \{\} $PODS_ROOT/Fabric/upload-symbols -gsp /Users/jamie/Documents/CalTest/CalTest/GoogleService-Info.plist -p platform \{\}

Now I have a build error that says

find: dSYM_directory: No such file or directory

What have I done wrong? I've followed the documentation step by step.

Edit

I have found the dSYM location and I still have the error on the firebase console.

This script now looks like this:

find "/Users/jamie/Library/Developer/Xcode/DerivedData/CalTest-eijpetsowazsmsegwizzgopcdpcq/Build/Products/Debug-iphoneos" -name "*.dSYM" | xargs -I \{\} $PODS_ROOT/Fabric/upload-symbols -gsp "/Users/jamie/Documents/CalTest/CalTest/GoogleService-Info.plist" -p "ios" \{\}

Bioscope answered 22/1, 2018 at 21:50 Comment(0)
S
6

dSYM_directory is just a placeholder in the example script. You need to point the upload-symbols script to the directory where your apps dSYMs are. Replace dSYM_directory with the actual path and it will work.

Sizing answered 23/1, 2018 at 14:54 Comment(6)
how do I find this directory?Bioscope
Check out docs.fabric.io/apple/crashlytics/missing-dsyms.html for more information of where dSYMs are written to.Sizing
Okay, I've found the location of the dSYM file but it's still giving me that message about the file being missing... I've added the updated script to the bottom of the OP, can you take another look? thanksBioscope
scratch that... the file is being uploaded.... something else is going wrong... thanks :)Bioscope
Nice - I'm glad it's being uploaded now.Sizing
I am still facing issue with error Pods/Fabric/run failed to execute. Line 58: Fabric/upload-symbols: File or directory does not exist. Any solution for missing upload-symbols file?Christi
C
5

Try:

"${DWARF_DSYM_FOLDER_PATH}/${DWARF_DSYM_FILE_NAME}".

The document may already updated.

https://firebase.google.com/docs/crashlytics/get-deobfuscated-reports?platform=ios&authuser=0

Cappuccino answered 22/1, 2020 at 9:51 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.