Conversation
Summary of ChangesHello @mmathieum, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request initiates the migration to the Google Mobile Ads Next-Gen SDK. The core changes involve updating the ad dependency to the new module and version, alongside implementing specific exclusion rules to manage potential conflicts with older ad service libraries. This ensures the application leverages the latest advertising platform features and improvements, streamlining the integration process for future ad-related functionalities. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
The pull request successfully migrates the project to the GMA Next-Gen SDK by updating the gps-ads version and module in gradle/libs.versions.toml and adding exclusion rules for the old play-services-ads dependencies in shared/app-android/build.gradle. The changes appear to align with the migration guide provided in the PR description. The exclusion rules are a good practice to prevent conflicts with the new SDK.
There was a problem hiding this comment.
Code Review
This pull request migrates the project from the legacy Google Play Services Ads SDK to the GMA Next-Gen SDK. Key changes include updating the dependency module to ads-mobile-sdk, adding supporting libraries like Cronet and Tink, and excluding legacy ads artifacts in the build configuration. Review feedback identifies critical concerns: the Next-Gen SDK lacks mediation support, which will cause existing mediation adapters for Facebook, AppLovin, and Vungle to fail at runtime. Furthermore, the PR lacks the necessary source code import updates for the new package, and a comment in the version catalog needs to be updated to reflect the new SDK's characteristics.
| material = { module = "com.google.android.material:material", version.ref = "material" } | ||
| # adds WRITE_EXTERNAL_STORAGE, READ_PHONE_STATE... | ||
| gps-ads = { module = "com.google.android.gms:play-services-ads", version.ref = "gps-ads" } | ||
| gps-ads = { module = "com.google.android.libraries.ads.mobile.sdk:ads-mobile-sdk", version.ref = "gps-ads" } |
There was a problem hiding this comment.
The GMA Next-Gen SDK does not currently support mediation. However, the project still includes mediation adapters for Facebook (line 211), AppLovin (line 213), and Vungle (line 215). Since the legacy play-services-ads SDK is explicitly excluded in shared/app-android/build.gradle, these adapters will fail at runtime due to missing dependencies. Additionally, this migration requires updating all source code imports to the new package (com.google.android.libraries.ads.mobile), which is not reflected in this diff. If mediation is required, you should not migrate to the Next-Gen SDK at this time.
| exclude group: "com.google.android.gms", module: "play-services-ads" | ||
| exclude group: "com.google.android.gms", module: "play-services-ads-lite" |
There was a problem hiding this comment.
This global exclusion will cause the mediation adapters (Facebook, AppLovin, Vungle) to fail at runtime because they depend on the play-services-ads artifacts being excluded here. As the Next-Gen SDK does not support mediation yet, these adapters should be removed if you intend to proceed with this migration.
| @@ -189,7 +189,7 @@ androix-webkit = { module = "androidx.webkit:webkit", version.ref = "androidx-we | |||
| androidx-workManager-runtime = { module = "androidx.work:work-runtime", version.ref = "androidx-workManager" } | |||
| material = { module = "com.google.android.material:material", version.ref = "material" } | |||
| # adds WRITE_EXTERNAL_STORAGE, READ_PHONE_STATE... | |||
https://developers.google.com/admob/android/next-gen/migration