BloodyMods / ServerStarter

MIT License
99 stars 62 forks source link

kotlin.TypeCastException #35

Closed TUBEOF closed 2 years ago

TUBEOF commented 3 years ago

Hi!

Im getting the following error, when i try to start/install a new modpack kotlin.TypeCastException: null cannot be cast to non-null type kotlin.String at atm.bloodworkxgaming.serverstarter.LoaderManager.startServer(LoaderManager.kt:169) at atm.bloodworkxgaming.serverstarter.LoaderManager.handleServer(LoaderManager.kt:43) at atm.bloodworkxgaming.serverstarter.ServerStarter.startLoading(ServerStarter.kt:190) at atm.bloodworkxgaming.serverstarter.ServerStarterKt.main(ServerStarter.kt:202)

I have already seen in another issue report that this seems to happen due to a missing option (level-type) in the server config. Is there a way to implement a fix for this so that this error does not appear in this case?

BloodWorkXGaming commented 3 years ago

Which version of the server starter are you using? Could you provide a full log please?

TUBEOF commented 3 years ago

Hey, sorry for my late response. I got the same error for a other modpack: https://www.curseforge.com/minecraft/modpacks/all-the-mods-6-to-the-sky-atm6s

Full log: `curseforge-updater@imageserver-45005-bl02:/var/imageserver/games/minecraft/curseforge-updater/442246/working$ ./startserver.sh Skipping download. Using existing serverstarter-2.0.1.jar [17:38:10] [INFO] ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: [17:38:10] [INFO] Minecraft ServerStarter install/launcher jar [17:38:10] [INFO] (Created by BloodWorkXGaming & Yoosk with the help of "Team ATM") [17:38:10] [INFO] ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: [17:38:10] [INFO] [17:38:10] [INFO] This jar will launch a Minecraft Forge/Fabric Modded server [17:38:10] [INFO] [17:38:10] [INFO] Github: https://github.com/BloodyMods/ServerStarter [17:38:10] [INFO] Github: https://github.com/Yoosk/ServerStarter [17:38:10] [INFO] Discord: https://discord.gg/K5FBPYa [17:38:10] [INFO] [17:38:10] [INFO] You are playing All the Mods 6 sky [17:38:10] [INFO] Starting to install/launch the server, lean back! [17:38:10] [INFO] ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: [17:38:10] [INFO] [17:38:10] [INFO] Pinging 8.8.8.8. [17:38:11] [INFO] Reached 8.8.8.8: false [17:38:11] [INFO] Pinging 1.0.0.1. [17:38:12] [INFO] Reached 1.0.0.1: false [17:38:12] [INFO] Reached 0 out of 2 IPs. [17:38:12] [ERROR] Not every host could be reached. There could be a problem with your internet connection!!!! [17:38:12] [INFO] Server is already installed to correct version, to force install delete the serverstarter.lock File. [17:38:12] [ERROR] Some uncaught error happened.

kotlin.TypeCastException: null cannot be cast to non-null type kotlin.String at atm.bloodworkxgaming.serverstarter.LoaderManager.startServer(LoaderManager.kt:169) at atm.bloodworkxgaming.serverstarter.LoaderManager.handleServer(LoaderManager.kt:43) at atm.bloodworkxgaming.serverstarter.ServerStarter.startLoading(ServerStarter.kt:191) at atm.bloodworkxgaming.serverstarter.ServerStarterKt.main(ServerStarter.kt:203) `

Running on Linux PRETTY_NAME="Debian GNU/Linux 10 (buster)" NAME="Debian GNU/Linux" VERSION_ID="10" VERSION="10 (buster)" VERSION_CODENAME=buster ID=debian HOME_URL="https://www.debian.org/" SUPPORT_URL="https://www.debian.org/support" BUG_REPORT_URL="https://bugs.debian.org/"

TUBEOF commented 3 years ago

Update: Adding "level-type=default" to server.properties not fixing this issue.

BloodWorkXGaming commented 2 years ago

should be fixed now