allegro / allegro/axion-release-plugin
VersionProperties.Incrementer in Kotlin != groovy.lang.Closure
- Dominant language
- Groovy
- Stars
- 641
- Forks
- 165
- Avg merge
- 49m
- Merged PRs (30d)
- 9
Description
Hallo All,
working with the just fixed #590 issue. I run into the next problem using kotlin dsl.
Have a look at the failing test here:
https://github.com/duschata/axion-release-plugin/blob/mcve_kotlin_closure/src/integration/groovy/pl/allegro/tech/build/axion/release/KotlinDslCompatibilityTests.groovy#L89
Kotlin needs a strong typed VersionProperties.Incrementer here, but the condition in the VersionPropertiesFactory
https://github.com/duschata/axion-release-plugin/blob/mcve_kotlin_closure/src/main/groovy/pl/allegro/tech/build/axion/release/infrastructure/config/VersionPropertiesFactory.groovy#L68-L74
evaluates a (!)Closure and the kotlin lambda runs always into the wrong condition.
What can we do there,
* using a kind of closureOf function in the kotlin script?
* fix the (!(value instanceof Closure))?
what do you think?
kind regards, Tom
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.