I had the same issue. I debugged it and found it to be caused by what I assume is a version mismatch between class net.minecraftforge.fml.common.network.NetworkRegistry and enum net.minecraftforge.fml.relauncher.Side.

Side has 3 values but the NetworkRegistry code appears to assume there are only 2, CLIENT and SERVER.

I fixed this by taking a copy of the NetworkRegistry class, and editing it as follows:

In the private, parameterless constructor, add the following line:

channels.put(Side.BUKKIT, Maps.<String,FMLEmbeddedChannel>newConcurrentMap());

Code change

Then you just need to make sure that your version of the class in on the classpath before the original version (if you're using eclipse then it will be automatically). You also need to make sure that you use the exact same package name for your version of the class.

Answer from winstar on Stack Overflow
🌐
Forge Forums
forums.minecraftforge.net › home › minecraft forge › support & bug reports › unexpected error error: java.lang.nullpointerexception
Unexpected error Error: java.lang.NullPointerException - Support & Bug Reports - Forge Forums
November 11, 2018 - You need another version scala-library.jar. Download it here https://web.archive.org/web/20130627152147/http://files.minecraftforge.net/fmllibs/scala-library.jar
🌐
Forge Forums
forums.minecraftforge.net › home › minecraft forge › support & bug reports › cant get into my server due to java.lang.nullpointerexception [1.19.2]
Cant get into my server due to java.lang.NullPointerException [1.19.2] - Support & Bug Reports - Forge Forums
March 23, 2023 - singleplayer works normal and doesnt crash server debug: https://gist.github.com/Xplodin/3ec81a8128191b8e3c5ca3be2316dd83 client debug: https://gist.github.com/Xplodin/15f5e00f435ad1893baddc07067fc241 Currently in the process of removing mods that seem to add the same functions, but any help woul...
🌐
Minecraft Forum
minecraftforum.net › home › minecraft forum › support › java edition support › java.lang.nullpointerexception, need fix please help
java.lang.NullPointerException, need fix please help - Java Edition Support - Support - Minecraft Forum - Minecraft Forum
Memory: 499447576 bytes (476 MB) / 581435392 bytes (554 MB) up to 1065025536 bytes (1015 MB) JVM Flags: 3 total; -Xbootclasspath/a:/System/Library/PrivateFrameworks/JavaApplicationLauncher.framework/Resources/LauncherSupport.jar -Xms512M -Xmx1024M AABB Pool Size: 10817 (605752 bytes; 0 MB) allocated, 10817 (605752 bytes; 0 MB) used Suspicious classes: FML and Forge are installed IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0 FML: MCP v7.23 FML v4.5.11.470 Minecraft Forge 6.4.1.413 31 mods loaded, 31 mods active mcp [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-i
🌐
GitHub
github.com › Creators-of-Create › Create › issues › 5135
[1.20.1][Forge] java.lang.NullPointerException: Cannot invoke "net.minecraft.client.multiplayer.ClientLevel.m_9598_()" because "world" is null · Issue #5135 · Creators-of-Create/Create
July 15, 2023 - [1.20.1][Forge] java.lang.NullPointerException: Cannot invoke "net.minecraft.client.multiplayer.ClientLevel.m_9598_()" because "world" is null#5135
Author   Creators-of-Create
🌐
Reddit
reddit.com › r/moddedmc › internal exception java.lang.nullpointerexception can not invoke "net.minecraft.nbt.compoundtag.m_128459_(string) | forge 1.20.1 server
r/ModdedMC on Reddit: internal exception java.lang.nullpointerexception can not invoke "net.minecraft.nbt.compoundtag.m_128459_(string) | Forge 1.20.1 Server
April 17, 2024 -

when people try to connect to my server, they receive this error message
internal exception java.lang.nullpointerexception can not invoke "net.minecraft.nbt.compoundtag.m_128459_(string)

i also received this error message as well but during this test for some reason it let me join the server, i've tested this out on singleplayer as well and the world works fine nothing seems to be corrupted it just doesn't work for the server.
we've also made multiple worlds for this specific pack i've made and they all have had this problem, randomly sometimes people will be able to join and play normally but other times they get this error and they cant play.
friends latest.log: https://mclo.gs/mHmks83
servers lastest.log: https://mclo.gs/si9AJk2

🌐
Reddit
reddit.com › r/feedthebeast › java.lang.nullpointerexception
r/feedthebeast on Reddit: java.lang.NullPointerException
December 4, 2021 -

I'm using Minecraft Forge, and the game freezes when I try to play a singleplayer world.

Part of the log where it freezes (not the entire thing because has 52000+ infos):

17:25:34.375

game

at appeng.core.AppEng.serverStopped(AppEng.java:218) 17:25:34.375 game

at appeng.core.AppEng$$Lambda$42439/1674748790.accept(Unknown Source) 17:25:34.375 game

at net.minecraftforge.eventbus.EventBus.doCastFilter(EventBus.java:247) 17:25:34.375 game

at net.minecraftforge.eventbus.EventBus.lambda$addListener$11(EventBus.java:239) 17:25:34.375 game

at net.minecraftforge.eventbus.EventBus$$Lambda$3053/743588298.invoke(Unknown Source) 17:25:34.375 game

at net.minecraftforge.eventbus.EventBus$$Lambda$4178/1865052252.invoke(Unknown Source) 17:25:34.375 game

at net.minecraftforge.eventbus.EventBus.post(EventBus.java:302) 17:25:34.375 game

at net.minecraftforge.eventbus.EventBus.post(EventBus.java:283) 17:25:34.375 game

at net.minecraftforge.fml.server.ServerLifecycleHooks.handleServerStopped(ServerLifecycleHooks.java:124) 17:25:34.375 game

at net.minecraft.server.MinecraftServer.func_240802_v_(MinecraftServer.java:683) 17:25:34.375 game

at net.minecraft.server.MinecraftServer.func_240783_a_(MinecraftServer.java:232) 17:25:34.375 game

at net.minecraft.server.MinecraftServer$$Lambda$79982/1441080155.run(Unknown Source) 17:25:34.375 game

at java.lang.Thread.run(Thread.java:745) 17:25:34.375 game

17:25:34.375

game

[17:25:34] [Server thread/ERROR] [minecraft/MinecraftServer]: java.lang.NullPointerException

It freezes at java.lang.nullpointerexception. Why does it freeze there when i try to load into a singleplayer world?

🌐
Fossils and Archeology Mod Revival Wiki
fossils-archeology.fandom.com › f › p › 3320054632415559970 › r › 3587255587307848309
I keep getting the "Error: java.lang.NullPointerException: Initializing game" and i cannot fix it | Fandom
July 17, 2018 - </p><p> </p><p> I'm currently have Fossils_Archeology_Revival-1.7.10_Build-7.3 and llibrary-1.7.14-1.12.2 and used forge-1.7.10-10.13.4.1558-1.7.10-installer-win I have Java version 8 update 181 (build 1.8.0_181-b13), the crash I keep getting is: Error: java.lang.NullPointerException: Initializing game and it will not let me view the crash report. </p><p> </p><p> I'm not the best with this stuff so If anyone can help me I would be very greatful! ;-; </p> ... <p>Your llibrary is the wrong version. You're using llibrary-1.7.14-1.12.2, which is for Minecraft 1.12, not 1.7.10 (which this mod is for.)
Find elsewhere
🌐
Forge Forums
forums.minecraftforge.net › home › minecraft forge › support & bug reports › java.lang.nullpointerexception: initializing game
java.lang.NullPointerException: Initializing game - Support & Bug Reports - Forge Forums
June 4, 2020 - Here is my path to the file that cannot be found: "src\main\resources\assets\liskamod\geo\liska.geo.json" And here's the damn mistake itself: Caused by: java.lang.IllegalArgumentException: Unable to find model file: liskamod:geo/liska If anyone knows what the error is, please tell me! I will be very grateful. ... To Replicate: use "summon minecraft:snowball ~1 ~ ~ {Motion:[1.0d,1.0d,0.0d]}" in a command block followed by "execute as @e[type=minecraft:snowball] run data modify entity @s Motion[1] set value 0.5d" even the slow speeds have issues.
🌐
GitHub
github.com › MinecraftForge › MinecraftForge › issues › 6911
[1.16.1] NullPointerException when spawning mod-registered entity · Issue #6911 · MinecraftForge/MinecraftForge
July 3, 2020 - Setup fresh Forge MDK · Create and register entity · Launch and summon entity · Description of issue: [22:11:56] [Server thread/WARN] [minecraft/EntityType]: Exception loading entity: java.lang.NullPointerException: null at net.minecraft.entity.ai.attributes.AttributeModifierManager.func_233795_c_(AttributeModifierManager.java:67) ~[forge-1.16.1-32.0.47_mapped_snapshot_20200514-1.16-recomp.jar:?] {re:classloading} at net.minecraft.entity.LivingEntity.func_233637_b_(LivingEntity.java:1848) ~[forge-1.16.1-32.0.47_mapped_snapshot_20200514-1.16-recomp.jar:?] {re:classloading} at net.minecraft.e
Author   MinecraftForge
🌐
GitHub
github.com › Railcraft › Railcraft › issues › 1915
java.lang.NullPointerException when loading railcraft with forge 14.23.5.2838 · Issue #1915 · Railcraft/Railcraft
January 25, 2020 - Description of the Bug minecraft 1.12.2 using forge 14.23.5.2838 crashes an reports the following error while loading net.minecraftforge.fml.common.LoaderExceptionModCrash: Caught exception from Railcraft (railcraft) Caused by: java.lang.NullPointerException ·
Author   Railcraft
🌐
Forge Forums
forums.minecraftforge.net › minecraft forge › support & bug reports
java.lang.NullPointerException - Support & Bug Reports - Forge Forums
August 9, 2021 - there is an error with minecraft forge 1.8.9 when changing servers on Hypixel. it is not a mod error as i ran forge without mods and still had the error. Here is the error: 10:50:55.484 Error executing task java.util.concurrent.ExecutionException: java.lang.NullPointerException at java.util.concu...
🌐
Forge Forums
forums.minecraftforge.net › home › mod developer central › modder support › internal exception java.lang.nullpointerexception how to fix
internal exception java.lang.nullpointerexception How to Fix - Modder Support - Forge Forums
May 26, 2023 - English is not my first language,so sorry for any mistakes some time ago i created a modpack to play with my friends(on aternos), it was all going well, but last week, as I was attempting to enter the server this error ocurred(all of my friends already were on the server), then the next day i cou...
🌐
Fossils and Archeology Mod Revival Wiki
fossils-archeology.fandom.com › f › p › 3869894282051912385
I'm getting error: java.lang.NullPointerException: Initializing game Would anyone be willing to help me fix it? | Fandom
Redeem at your nearest Mojangsta: [~~HUG~~] <p>Time: 8/14/20 11:26 AM Description: Initializing game </p><p>java.lang.NullPointerException: Initializing game at net.minecraft.client.renderer.color.BlockColors.func_186722_a(BlockColors.java:97) ~[?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at knightminer.inspirations.building.BuildingClientProxy.registerBlockColors(BuildingClientProxy.java:100) ~[?:1.15.2-1.1.0] {re:classloading} at net.minecraftforge.eventbus.ASMEventHandler_128_BuildingClientProxy_registerBlockColors_Block.invoke(.dynamic) ~[?:?] {} at net.minecraftf
🌐
Minecraft Forum
minecraftforum.net › home › minecraft forum › support › java edition support › keep getting error: java.lang.nullpointerexception on my modded game profile.
Keep getting error: java.lang.NullPointerException on my modded game profile. - Java Edition Support - Support - Minecraft Forum - Minecraft Forum
WARNING: coremods are present: CTMCorePlugin (CTM-MC1.12.2-0.3.3.22.jar) Contact their authors BEFORE contacting forge ... java.lang.NullPointerException: Initializing game at net.minecraftforge.fml.common.versioning.ComparableVersion.parseVersion(ComparableVersion.java:371) at net.minecraftforge.fml.common.versioning.ComparableVersion.<init>(ComparableVersion.java:362) at net.minecraftforge.fml.common.versioning.DefaultArtifactVersion.<init>(DefaultArtifactVersion.java:31) at net.minecraftforge.fml.common.versioning.DefaultArtifactVersion.<init>(DefaultArtifactVersion.java:42) at net.minecraf
🌐
Hypixel Forums
hypixel.net › home › forums › games › skyblock › skyblock community help
1.8.9 forge crashes (Error: java.lang.NullPointerException: Initializing game Exit Code: -1) | Hypixel Forums
February 2, 2022 - This is the error i get: --- Minecraft Crash Report ---- WARNING: coremods are present: FMLLoadingPlugin (TNT Time-1.1 (1.8.9).jar) Skytils On Top (!Skytils-1.1.2.jar) ModTweaker (Patcher-1.7.0 (1.8.9) (1).jar) PlayerAPIPlugin (PlayerAPI-1.8.9-1.0.jar) SkyblockAddonsLoadingPlugin (SkyblockAddons-1.7.0-beta.16915-for-MC-1.8.9.jar) FMLLoadingPlugin (Scrollable Tooltips-1.4 (1.8.9) (1).jar) AutoCorrectTweaker (Autocorrect-1.1 (1.8.9) (1).jar) AsmHelperLoadingPlugin (ctjs-2.0.0-1.8.9.jar) PatcherTweaker (Patcher-1.7.0 (1.8.9) (1).jar) Contact their authors BEFORE contacting forge // Don't do that.
🌐
Minecraft Forum
minecraftforum.net › home › minecraft forum › mapping and modding: java edition › minecraft mods › modification development › java.lang.nullpointerexception in the first compile of forge
java.lang.NullPointerException in the first compile of Forge - Modification Development - Minecraft Mods - Mapping and Modding: Java Edition - Minecraft Forum - Minecraft Forum
Exception in thread "main" java.lang.NullPointerException at GradleStart.attemptLogin(Unknown Source) at GradleStart.preLaunch(Unknown Source) at net.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source) at GradleStart.main(Unknown Source) I've looked over that code and it doesn't seem to have errors (I'm using a stable version of Forge).