Ktor: Crash with Firebase Performance in iOS

Created on 25 Mar 2019  路  7Comments  路  Source: ktorio/ktor

Ktor Version

1.1.3

Ktor Engine Used(client or server and name)

Client iOS with default engine

Feedback (Bug)

When adding Firebase Performance to an iOS application, the app crashes when making a request with Ktor.

I've forked the sample mmp project and added the Firebase Performance library. The application crashes due to Firebase Performance. It might be because Firebase intercepts all network requests and it might be incompatible with Ktor.

You can find the sample mmp client crashing with Firebase Performance here https://github.com/eduardbosch/ktor-samples/commit/35bb435b4138ef966eeb9c44cbaf632bfaaeb305
Remember to add the GoogleServices-Info.plist to prevent Firebase to crash when it is initialised.

I hope this can help Ktor! 馃帀

bug

All 7 comments

Hi @eduardbosch, thanks for the report. I'll investigate the problem.

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.

I have this problem reproduced on the version "1.3.2-1.4.0-rc"

It still happening in 1.4.2

We are experiencing this crash after we upgraded from Kotlin 1.3.72 to 1.4.10.

Unfortunately the issue on Firebase side was closed due to inactivity without a proper fix: https://github.com/firebase/firebase-ios-sdk/issues/2626

Is there any workaround available, beside removing Firebase?

EDIT
Just tested with kotlin 1.4.21, ktor 1.5.0' and coroutines 1.4.1-native-mt: still crashes.

Good News:

With kotlin 1.4.30, ktor 1.5.0 and coroutines 1.4.2-native-mt NOT CRASHING anymore.

Seems to be this kotlin-native PR that solves it: https://github.com/JetBrains/kotlin-native/pull/4569

Hey @corbella83, Thanks for the notice! Closed

Was this page helpful?
0 / 5 - 0 ratings