LuckPerms Fabric Null Pointers in Offline Mode Upon Login
CoolMineman opened this issue ยท 2 comments
Description
LuckPerms fabric null pointers in offline mode upon login
[ForkJoinPool-4-worker-53/ERROR] (luckperms) Exception occurred whilst loading data for null - [My Player's Username]
java.lang.NullPointerException: null
at java.util.Objects.requireNonNull(Objects.java:221) ~[?:?]
at me.lucko.luckperms.lib.caffeine.cache.BoundedLocalCache.put(BoundedLocalCache.java:1981) ~[?:?]
at me.lucko.luckperms.lib.caffeine.cache.BoundedLocalCache.put(BoundedLocalCache.java:1956) ~[?:?]
at java.util.Collections$SetFromMap.add(Collections.java:5566) ~[?:?]
at com.google.common.collect.ForwardingCollection.add(ForwardingCollection.java:89) ~[guava-21.0.jar:?]
at me.lucko.luckperms.common.model.manager.user.UserHousekeeper.registerUsage(UserHousekeeper.java:57) ~[?:?]
at me.lucko.luckperms.common.plugin.util.AbstractConnectionListener.loadUser(AbstractConnectionListener.java:67) ~[?:?]
at me.lucko.luckperms.fabric.listeners.FabricConnectionListener.onPreLoginAsync(FabricConnectionListener.java:92) ~[?:?]
at me.lucko.luckperms.fabric.listeners.FabricConnectionListener.lambda$onPreLogin$0(FabricConnectionListener.java:74) ~[?:?]
at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1736) [?:?]
at java.util.concurrent.CompletableFuture$AsyncRun.exec(CompletableFuture.java:1728) [?:?]
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290) [?:?]
at java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020) [?:?]
at java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656) [?:?]
at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594) [?:?]
at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183) [?:?]
Reproduction steps
- Set server to offline mode
- Try to login
Expected behaviour
You should be able to login
Environment details
- Server type/version: Fabric
- LuckPerms version: LuckPerms-Fabric-5.2.75.jar
Investigation:
Issue occurs here:
https://github.com/lucko/LuckPerms/blob/master/fabric/src/main/java/me/lucko/luckperms/fabric/listeners/FabricConnectionListener.java#L92
My educated guess is the game profile on ServerLoginNetworkHandler
is null for some reason?
However I don't see a typical way this would end up as null.