Closed bitspittle closed 11 months ago
If you want to repro this for yourself....
git clone https://github.com/varabyte/kobweb-site.git
./gradlew build
@ bitspittle Thank you for your bug report. I could reproduce it and your suggested change fixed the issue.
Version 0.6.2 is in the pipeline...
I'm the author of a project called Kobweb, which uses KSP. One of my users reported a callstack that came from this plugin.
with this error:
They said they saw a similar error when using ktorfit with your plugin, and that is another project that uses ksp.
After some investigation, we think this line is the culprit, forcing eager evaluation before other plugins are ready :
https://github.com/comahe-de/i18n4k/blob/c8516196097279dd58411c2b7b34c703dfddb1a6/i18n4k-gradle-plugin/src/main/kotlin/de/comahe/i18n4k/gradle/plugin/I18n4kPlugin.kt#L121C20-L121C20
It should probably be rewritten as
You should probably also change the
withType.forEach
calls towithType.configureEach
and thefindByName
calls also to usematching
.I'm not a Gradle expert, nor am I sure if you fix this it will fix the issues I'm seeing with the error linked above, but making these changes are, to my understanding, modern Gradle best practices. See also: https://docs.gradle.org/current/userguide/task_configuration_avoidance.html