I am working on a Kotlin project and need to use javax.script.ScriptException
. However, I’m encountering an error stating that javax.script.ScriptException
is unresolved, which means there is no built-in support for this in my project.
I’ve just set up this project and I’m not sure what is causing this issue. I have searched extensively on the internet but couldn’t find a solution. Below is the content of my build.gradle(app) file and this is the gradle(plugins)!
I tried to add some dependencies like these:
implementation("org.jetbrains.kotlin:kotlin-stdlib:1.9.0")
implementation("org.jetbrains.kotlin:kotlin-scripting-common:1.9.0")
implementation("org.jetbrains.kotlin:kotlin-scripting-jvm:1.9.0")
implementation("org.jetbrains.kotlin:kotlin-scripting-jvm-host:1.9.0")
or
implementation("org.jetbrains.kotlin:kotlin-scripting-jsr223:1.9.0")
implementation("org.jetbrains.kotlin:kotlin-stdlib:1.9.0")
implementation("org.jetbrains.kotlin:kotlin-scripting-jsr223:1.9.0")
to see if they can solve my problem, but the issue persists and it still gives an “unresolved” error.
Could someone please help me understand why I can’t use javax.script.ScriptException
and how to resolve this issue?
Thank you in advance!