RuntimeException: Failed to instantiate language adapter: kotlin
christianm20358 opened this issue ยท 1 comments
Hello,
I'm getting the following stack trace when trying to launch the debugger in vscode. I've put my environment info below, I'm new to both Java and Kotlin so it may be that there's an incompatibility there, I do get a message in vscode when in the KotlinAdapter.kt file that says FabricLauncherBase' is deprecated. Deprecated in Javakotlin(DEPRECATION)
I have not modified anything in the project, this error occurs after running genSources and vscode gradle commands, then attempting to run the auto-generated "Minecraft Client" debugger profile. Let me know if it's something happening on my end due to my setup, any guidance or direction for fixing this would be greatly appreciated.
Environment info
java -version
openjdk version "17.0.4.1" 2022-08-12
OpenJDK Runtime Environment Temurin-17.0.4.1+1 (build 17.0.4.1+1)
OpenJDK 64-Bit Server VM Temurin-17.0.4.1+1 (build 17.0.4.1+1, mixed mode, sharing)
kotlinc -version
info: kotlinc-jvm 1.7.20 (JRE 17.0.4.1+1)
OS
Windows 11
Error message
Uncaught exception in thread "main"
java.lang.RuntimeException: Failed to instantiate language adapter: kotlin
at net.fabricmc.loader.impl.FabricLoaderImpl.setupLanguageAdapters(FabricLoaderImpl.java:402)
at net.fabricmc.loader.impl.FabricLoaderImpl.finishModLoading(FabricLoaderImpl.java:310)
at net.fabricmc.loader.impl.FabricLoaderImpl.freeze(FabricLoaderImpl.java:110)
at net.fabricmc.loader.impl.launch.knot.Knot.init(Knot.java:149)
at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:68)
at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23)
at net.fabricmc.devlaunchinjector.Main.main(Main.java:86)
Caused by: java.lang.ClassNotFoundException: net.fabricmc.language.kotlin.KotlinAdapter
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
at net.fabricmc.loader.impl.launch.knot.KnotClassDelegate.loadClass(KnotClassDelegate.java:226)
at net.fabricmc.loader.impl.launch.knot.KnotClassLoader.loadClass(KnotClassLoader.java:145)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:467)
at net.fabricmc.loader.impl.FabricLoaderImpl.setupLanguageAdapters(FabricLoaderImpl.java:400)
... 6 more
launch.json
{
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Minecraft Client",
"request": "launch",
"cwd": "${workspaceFolder}/run",
"console": "internalConsole",
"stopOnEntry": false,
"mainClass": "net.fabricmc.devlaunchinjector.Main",
"vmArgs": "-Dfabric.dli.config\u003dC:\\Users\\chris\\Documents\\fabric-language-kotlin\\.gradle\\loom-cache\\launch.cfg -Dfabric.dli.env\u003dclient -Dfabric.dli.main\u003dnet.fabricmc.loader.impl.launch.knot.KnotClient",
"args": ""
},
{
"type": "java",
"name": "Minecraft Server",
"request": "launch",
"cwd": "${workspaceFolder}/run",
"console": "internalConsole",
"stopOnEntry": false,
"mainClass": "net.fabricmc.devlaunchinjector.Main",
"vmArgs": "-Dfabric.dli.config\u003dC:\\Users\\chris\\Documents\\fabric-language-kotlin\\.gradle\\loom-cache\\launch.cfg -Dfabric.dli.env\u003dserver -Dfabric.dli.main\u003dnet.fabricmc.loader.impl.launch.knot.KnotServer",
"args": "nogui"
}
]
}
๐ We use the issue tracker exclusively for final bug reports and feature requests. However, this issue appears to be better suited for either a discussion thread, or a message on our discord server. Please post your request on one of these, and the conversation can continue there.