-
Notifications
You must be signed in to change notification settings - Fork 274
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fail to apply ksp before android #2174
Milestone
Comments
This is caused by this Gradle bug. There is a workaround that should work, so I'll work on a implementing that. |
scott-pollom
added a commit
to scott-pollom/ksp
that referenced
this issue
Oct 31, 2024
Previously, when the KSP plugin was applied before AGP and AGP's built-in Kotlin support for test fixtures or screenshot tests was enabled, there would be an error when building. The underlying cause for this error is gradle/gradle#31092, which caused the KSP plugin to try to access the android extension before AGP's apply method had completed. This change fixes the problem by using the "com.android.base" plugin as the indicator that a module is an Android module. The "com.android.base" plugin is applied after the android extension has been added, so it works around the Gradle bug. Bug: google#2174 Test: GradleCompilationTest
scott-pollom
added a commit
to scott-pollom/ksp
that referenced
this issue
Oct 31, 2024
Previously, when the KSP plugin was applied before AGP and AGP's built-in Kotlin support for test fixtures or screenshot tests was enabled, there would be an error when building. The underlying cause for this error is gradle/gradle#31092, which caused the KSP plugin to try to access the android extension before AGP's apply method had completed. This change fixes the problem by using the "com.android.base" plugin as the indicator that a module is an Android module. The "com.android.base" plugin is applied after the android extension has been added, so it works around the Gradle bug. Bug: google#2174 Test: GradleCompilationTest
ting-yuan
pushed a commit
that referenced
this issue
Nov 1, 2024
Previously, when the KSP plugin was applied before AGP and AGP's built-in Kotlin support for test fixtures or screenshot tests was enabled, there would be an error when building. The underlying cause for this error is gradle/gradle#31092, which caused the KSP plugin to try to access the android extension before AGP's apply method had completed. This change fixes the problem by using the "com.android.base" plugin as the indicator that a module is an Android module. The "com.android.base" plugin is applied after the android extension has been added, so it works around the Gradle bug. Bug: #2174 Test: GradleCompilationTest
github-actions bot
pushed a commit
that referenced
this issue
Nov 1, 2024
Previously, when the KSP plugin was applied before AGP and AGP's built-in Kotlin support for test fixtures or screenshot tests was enabled, there would be an error when building. The underlying cause for this error is gradle/gradle#31092, which caused the KSP plugin to try to access the android extension before AGP's apply method had completed. This change fixes the problem by using the "com.android.base" plugin as the indicator that a module is an Android module. The "com.android.base" plugin is applied after the android extension has been added, so it works around the Gradle bug. Bug: #2174 Test: GradleCompilationTest (cherry picked from commit 5b1cd4a)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Discussion on Slack: https://kotlinlang.slack.com/archives/C013BA8EQSE/p1729789842772099
People reporting that after updating to ksp 1.0.26 they got the following error in all the modules that have the ksp line before the android one. Was not the case for as far as this project existed and the first versions of ksp.
The text was updated successfully, but these errors were encountered: