Skip to content

Conversation

@SimonMarquis
Copy link
Contributor

@SimonMarquis SimonMarquis commented Sep 14, 2025

This neat website can be used to track the current issues with AGP 9: https://agp-status.frybits.com/agp-9.0.0/


@SimonMarquis SimonMarquis marked this pull request as draft September 14, 2025 12:35
@SimonMarquis SimonMarquis force-pushed the agp-9 branch 2 times, most recently from d2767d1 to a19fcd9 Compare September 21, 2025 08:45
`error: cannot find symbol` on:

- `DataStoreModule.INSTANCE.providesUserPreferencesDataStore$datastore_demoDebug`
- `SyncModule.Companion.provideFirebaseMessaging$work_prodDebug()`
They must have been removed as they are no longer resolved by default.
Updated Android Gradle Plugin and Tools versions.
@liutikas
Copy link
Collaborator

liutikas commented Nov 6, 2025

release build type has isDebuggable forced to true, even when explicitly turned off.

Can you point me to how to repro this?

@SimonMarquis
Copy link
Contributor Author

I've not been able to reproduce it on my other projects, but on this one, simply build a release app with gradlew :app:assembleDemoRelease.

not sure if they were dropped on purpose...
@SimonMarquis SimonMarquis force-pushed the agp-9 branch 2 times, most recently from 101662a to cf6e7dd Compare November 7, 2025 20:54
…buildTypes

leading to "debuggable" release builds.
@SimonMarquis
Copy link
Contributor Author

I found the issue, fixed in 52b118a.
enableAndroidTestCoverage forces the app to be debuggable, probably because of a new logic internal to AGP.

I've refactored the code to configure only the debug buildTypes:
https://github.com/SimonMarquis/nowinandroid/blob/52b118a1e073c07c4b7843e3ca93ea70333e41a0/build-logic/convention/src/main/kotlin/com/google/samples/apps/nowinandroid/Jacoco.kt#L68-L71

@Provides
@Singleton
internal fun providesUserPreferencesDataStore(
fun providesUserPreferencesDataStore(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this change needed? Is it related to the AGP upgrade?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, see this commit: fd939d5

# https://issuetracker.google.com/issues/295039976
android.injected.androidTest.leaveApksInstalledAfterRun=true

android.newDsl=false
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a comment on why we need to opt out linking to the hilt bug.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not meant to be merged as-is, as mentioned in the PR first message.
That being said, if you really want to merge this PR before alls bugs are fixed & workarounds are removed, I can add a comment for this. Let me know.

Add comment to clarify Jacoco configuration for debug builds.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants