firebase-ios-sdk: 177930107: Dynamic links trowing error

Step 1: Environment details

  • Xcode version: 12.3 (12C33)
  • Firebase SDK version: - Firebase/Analytics (7.4.0): - Firebase/Core - Firebase/Auth (7.4.0): - Firebase/CoreOnly - FirebaseAuth (~> 7.4.0) - Firebase/Core (7.4.0): - Firebase/CoreOnly - FirebaseAnalytics (= 7.4.0)
  • Installation method: `CocoaPods
  • Firebase Component: Dinamic Links

[REQUIRED] Step 2: Problem details

There is an error appearing with the text: Thread 1: EXC_BAD_ACCESS (code-1, address=0x40925bac0) after integrating the Google Dinamic links into our project. We’ve tried different versions of Dinamic Links SDK, for example: v.7.4.0, 7.3.1, 4.0.0, 3.1.1, they are all showing the same error.

We’ve also tried to switch the FirebaseDeepLinkAutomaticRetrievalEnabled parameter to NO, after that the error is not appearing, however the feature stop work after that.

Screenshot attached: image

NOTE: The same problem has been opened in the link https://github.com/firebase/firebase-ios-sdk/issues/3945 before, however no-one resolved it after, due to the lack of the details the issue were closed.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 3
  • Comments: 18 (4 by maintainers)

Most upvoted comments

I’ve been having this same issue for weeks as well, and it’s held us from releasing an implementation of DynamicLinks because we also absolutely need NewRelic.

We are using

pod 'Firebase/DynamicLinks', '~> 8.1'
pod 'NewRelicAgent', '7.3.2'

I tried adding the FirebaseDeepLinkAutomaticRetrievalEnabled = NO but even though this did prevent the crash, it also prevented the DynamicLinks from opening.

The solution that worked for us

Believe it or not, placing the NewRelic.start() call at the very top of didFinishLaunchingWithOptions made it work for me. It seems that somehow NewRelic and Firebase are competing for resources and NewRelic being initialized first makes them both work well.

This breaks

FirebaseApp.configure()
NewRelic.start("key")

This works

NewRelic.start("key")
FirebaseApp.configure()

Ironically, the NewRelic setup guide does warn that we absolutely must place their init code in the first line of didFinishLaunchingWithOptions unless we want bad things to happen. Apparently these are the bad things?

image

If you try this, i’d love to know if it works for you

@nmalancea tagging you because you seem to still be running into this!

Hi Ryan, first of all thank you very much for quick respond.

1 The exact reproducing steps are simple, we used Cocoa to integrate FirebaseDynamicLinks, right after it we press on RUN and it shows Thread and Crashing, project cannot proceed at this step.

2 This happening right in the Xcode with connected Simulator Device and Real Phone, both cases are showing this thread.

Additional info: We’ve found out other people have this problem also, and we found out that if we disable FirebaseDeepLinkAutomaticRetrievalEnabled with a value NO to the Info.plist the error is disappearing, unfortunately the whole feature stops working. The link for this method is https://github.com/firebase/firebase-ios-sdk/issues/4308

Screenshot: image

3 We would like to know for which features FirebaseDeepLinkAutomaticRetrievalEnabled is responsible exactly, it seems after we disable it it do not pass any data for Firebase. And there is no any additional information or guide to get whole explanation for this online.

Hope you can help us with this problem, it is very important for us to have this feature in our application.

Just to share that I had the same issue/crash when adding the Firebase/DynamicLinks through Cocoapods, and the above suggestion about initialising the NewRelic Before Firebase fixes the issue 🤷‍♂️

I have a similar issue, same kind of exception but on the line 79 _wkWebView = [[WKWebView alloc] init]; of the file FIRDLJavaScriptExecutor.m.

This issue only happens when I compile with Xcode 12 for an iOS 11.X simulator. It works properly with an iOS 14.X simulator.

@VladislavShergin are you using an M1 mac ? Just tried on an Intel based mac and can’t seem to reproduce.

Dear Ryan, we also have additional question.

The main reason we’ve integrated Google Dynamic links is to get Source/Medium for tracking orders through the dynamic link. We would like to saw conversion of each order with Source/Medium in Google Analytics associated project. The project is directly connected to ur Firebase.

We’ve integrated Dynamic links in Android and it works perfectly, example screenshot: image And for the IOS we did the same, but data of the source and medium is not showing in any case, example screenshot: image As you can see from a screenshot for IOS, and as a result the source showing as (direct), we’ve followed all procedure explained on official site and youtube guide.

Our main goal is not to resolve a Thread for SDK, but to have the main source and medium regarding to the order in GA - conversions.

Please tell us is there any way to check or trace the medium/source for dynamic links or is there is something what we did wrong while implementing the feature.

Thank you.