You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Issue: ClassNotFoundException: org.jetbrains.annotations.NotNull during JTE template compilation
When trying to compile kotlin JTE templates (.kte) with gradle, I'm getting a ClassNotFoundException for org.jetbrains.annotations.NotNull. This appears to be a dependency issue where JTE's Kotlin compiler can't find the annotations it needs.
Environment
JTE version: 3.1.16
Kotlin version: 1.9.10 (I also tried with 2.1.0 but downgraded thinking it might be an issue)
Gradle version: - tried both 8.8 and 8.12; same issue
Full stack trace shows the error occurs during Kotlin IR compilation of the generated template classes:
Backend Internal error: Exception during IR lowering
File being compiled: .../jte-classes/gg/jte/generated/precompiled/JteexampleGenerated.kt
The root cause java.lang.RuntimeException was thrown at: org.jetbrains.kotlin.backend.jvm.codegen.FunctionCodegen.generate(FunctionCodegen.kt:50)
Expected Behavior
The templates should compile successfully since we have the required dependencies (org.jetbrains:annotations) in the classpath.
Actual Behavior
The Kotlin compiler used by JTE cannot find the annotations classes, despite them being available in the project dependencies.
Question
Is there a way to ensure the annotations dependency is properly passed to JTE's internal Kotlin compiler? Or is there a different way we should be configuring the dependencies for JTE template compilation? I've tried including the jetbrains annotation dependency as an implementation dependency and a buildscript classpath dependency. I'm at a loss for how to solve this and would really appreciate any help :)
Issue: ClassNotFoundException: org.jetbrains.annotations.NotNull during JTE template compilation
When trying to compile kotlin JTE templates (.kte) with gradle, I'm getting a
ClassNotFoundException
fororg.jetbrains.annotations.NotNull
. This appears to be a dependency issue where JTE's Kotlin compiler can't find the annotations it needs.Environment
Configuration
build.gradle.kts
:Template File
Error
Full stack trace shows the error occurs during Kotlin IR compilation of the generated template classes:
Expected Behavior
The templates should compile successfully since we have the required dependencies (
org.jetbrains:annotations
) in the classpath.Actual Behavior
The Kotlin compiler used by JTE cannot find the annotations classes, despite them being available in the project dependencies.
Question
Is there a way to ensure the annotations dependency is properly passed to JTE's internal Kotlin compiler? Or is there a different way we should be configuring the dependencies for JTE template compilation? I've tried including the jetbrains annotation dependency as an implementation dependency and a buildscript classpath dependency. I'm at a loss for how to solve this and would really appreciate any help :)
Full stack trace for reference:
stacktrace.txt
The text was updated successfully, but these errors were encountered: