[FIX] Android: Custom Datadog upload options not set correctly and Gradle error#879
Conversation
|
Hey @marco-saia-datadog 👋 I believe this change doesn't play well with the expo plugin (v52.0.1 at least). Given the following expo plugin config (in an expo project's [
'expo-datadog',
{
errorTracking: {
serviceName: 'custom-service-name',
iosSourcemaps: true,
androidSourcemaps: true,
},
},
]The When the Bit of a niche regression, but I would expect the expo-plugin to align with this change, too. Keen to hear your thoughts whether I'm missing something here! |
|
@FrikkieSnyman Thank you for reaching out! You are absolutely right 🙏 I have created an issue on expo-datadog to keep track of progress: DataDog/expo-datadog#62. We will take care of this and keep you posted 🙌 |
What does this PR do?
Fixes upload options not being extracted correctly from
project.exton Android, and Gradle error triggered when usingdd-sdk-android-gradle-plugin.Explanation
We currently try to access the upload options from the
projectobject, instead ofproject.ext, leading to properties not being parsed properly, but failing silently.Furthermore, a build error is triggered when
dd-sdk-android-gradle-pluginis used, by including the plugin in theapp/build.gradle, as shown below:plugins { id("com.datadoghq.dd-sdk-android-gradle-plugin") version "<version>" }The reason is that the plugin defines a custom extension of type
com.datadog.gradle.plugin.DdExtension, accessible throughproject.datadog, leading to the following error:Reported in #878.
Review checklist (to be filled by reviewers)