04 Jul 2024 12:38 PM
Hi everyone.
I am following the instrumentation steps for Dynatrace Mobile App Rum and I encountered the following error.
Failed to apply plugin 'com.dynatrace.instrumentation'.
> The Dynatrace Android Gradle plugin must be applied in the top-level build.gradle (or build.gradle.kts) file. If you are sure that the plugin is applied correctly, you can deactivate the build checks with the Gradle project property '-Pdynatrace.ignoreBuildWarning=true'.
kotlin version 1.9.
Does anyone have any comments for a solution?
Thanks.
Solved! Go to Solution.
04 Jul 2024 01:06 PM
Hey
Most likely you copied the configuration script into the wrong file. There are multiple build.gradle files in an Android project. You have to copy the snippet into the top-level build.gradle file and not into the build.gradle file of your "app" module.
Maybe an example is more helpful than the description. The correct file is the one in line 5 -> the build.gradle file in the folder "MyApp" folder, where you will find the settings.gradle file too.