Why do Kotlin files appear as .java is Fabric Crashlytics with Proguard enabled?

耗尽温柔 提交于 2021-02-18 22:04:19

问题


I have recently turned on Proguard minimisation for an Android app which uses Crashylics reporting on the Fabric console. The project is written mainly in Kotlin.

Crash reports are still received. The stack trace no longer lists Kotlin source files as .kt though, but as .java

eg, MyFragment.java:20 instead of MyFragment.kt:20

From the information in the traces, such as function and variable names, the line numbers in the stack match up to those in the .kt file

I have Proguard exclusions as listed in the config guide: https://docs.fabric.io/android/crashlytics/dex-and-proguard.html

Is there an extra action for Kotlin?

I'd like to see the correct file type extension in crash reports


回答1:


Fabric/Firebaser here -

We assume a .java extension by default, but we'll be looking to improve this experience for Kotlin in the future.




回答2:


The problem is that for obfuscated classes the Proguard mapping file doesn't provide any indication of what file that class came from. This is an issue the Crashlytics eng team is aware of, and will hopefully be able to find a fix for in the near future.



来源:https://stackoverflow.com/questions/57518909/why-do-kotlin-files-appear-as-java-is-fabric-crashlytics-with-proguard-enabled

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!