Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue opening chests after time w/ MySQL #181

Open
CraftingMagic-Skyy opened this issue Nov 10, 2021 · 4 comments
Open

Issue opening chests after time w/ MySQL #181

CraftingMagic-Skyy opened this issue Nov 10, 2021 · 4 comments
Labels
bug: unconfirmed Potential bugs that need replicating to verify. status: not enough info Issues that require more information to be provided, either by the author or through investigation.

Comments

@CraftingMagic-Skyy
Copy link

Versions
EnderContainers version: 2.2.2
Platform version: paper-1.12.2

Describe the bug
After some time idle, the enderchests do not seem to want to be opened when clicking enderchests

To Reproduce

  1. Start Server
  2. Wait 30(ish) minutes
  3. Try opening EnderChest either command or by chest click

Expected behavior
Opens GUI

Screenshots
N/A

Additional context

Using MySQL

From Log:

[21:27:55] [Craft Scheduler Thread - 383/WARN]: [EnderContainers] Plugin EnderContainers v2.2.2 generated an exception while executing task 1425886
java.lang.NullPointerException: null
at fr.utarwyn.endercontainers.storage.player.PlayerSQLData.getEnderchestContents(PlayerSQLData.java:77) ~[?:?]
at fr.utarwyn.endercontainers.enderchest.EnderChest.getContents(EnderChest.java:115) ~[?:?]
at fr.utarwyn.endercontainers.inventory.EnderChestInventory.prepare(EnderChestInventory.java:53) ~[?:?]
at fr.utarwyn.endercontainers.inventory.AbstractInventoryHolder.reloadInventory(AbstractInventoryHolder.java:132) ~[?:?]
at fr.utarwyn.endercontainers.inventory.EnderChestInventory.(EnderChestInventory.java:45) ~[?:?]
at fr.utarwyn.endercontainers.enderchest.EnderChest.(EnderChest.java:49) ~[?:?]
at fr.utarwyn.endercontainers.enderchest.VanillaEnderChest.(VanillaEnderChest.java:35) ~[?:?]
at fr.utarwyn.endercontainers.enderchest.context.PlayerContext.createEnderchest(PlayerContext.java:205) ~[?:?]
at java.util.stream.IntPipeline$4$1.accept(IntPipeline.java:250) ~[?:1.8.0_292]
at java.util.stream.Streams$RangeIntSpliterator.forEachRemaining(Streams.java:110) ~[?:1.8.0_292]
at java.util.Spliterator$OfInt.forEachRemaining(Spliterator.java:693) ~[?:1.8.0_292]
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482) ~[?:1.8.0_292]
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472) ~[?:1.8.0_292]
at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708) ~[?:1.8.0_292]
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) ~[?:1.8.0_292]
at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:566) ~[?:1.8.0_292]
at fr.utarwyn.endercontainers.enderchest.context.PlayerContext.loadEnderchests(PlayerContext.java:122) ~[?:?]
at fr.utarwyn.endercontainers.enderchest.context.LoadTask.run(LoadTask.java:63) ~[?:?]
at org.bukkit.craftbukkit.v1_12_R1.scheduler.CraftTask.run(CraftTask.java:64) ~[patched_1.12.2.jar:git-Paper-"77cce8236"]
at org.bukkit.craftbukkit.v1_12_R1.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:52) ~[patched_1.12.2.jar:git-Paper-"77cce8236"]
at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22) ~[patched_1.12.2.jar:git-Paper-"77cce8236"]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_292]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_292]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_292]

@CraftingMagic-Skyy CraftingMagic-Skyy added the bug: unconfirmed Potential bugs that need replicating to verify. label Nov 10, 2021
@CraftingMagic-Skyy
Copy link
Author

@utarwyn

@utarwyn
Copy link
Owner

utarwyn commented Nov 16, 2021

Hello @CraftingMagic-Skyy, sorry for the response delay.. It seems to be a save problem with the vanilla enderchest (because the stack mentions VanillaEnderChest file). I have an idea on how to reproduce the bug and fix it. I'll keep you informed!

Sorry for the inconvenience,
Regards

@CraftingMagic-Skyy
Copy link
Author

Just commenting to see if any updates

@utarwyn
Copy link
Owner

utarwyn commented Dec 5, 2021

I'm trying to reproduce the error on my local server but unfortunately without success.. I don't know why waiting an amount of time can cause a problem like this (this stacktrace means that player data are not loaded anymore).

Can I ask you few questions about your configuration to help me reproducing the bug?

  • What is the value of config useVanillaEnderchest?
  • Does the player has already opened one enderchest before waiting this amount of time?
  • Your database already stores some enderchest data for that player?

I'm waiting for your feedback, thank you for your time!
I'm really sorry, problems like this are often complicated to reproduce and fix.


I have discovered another bug last time, the one I notice in in my last comment. When using vanilla enderchest, it also tries to load it from database but that does not make sense, so I will fix this.

@utarwyn utarwyn added the status: not enough info Issues that require more information to be provided, either by the author or through investigation. label Jul 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug: unconfirmed Potential bugs that need replicating to verify. status: not enough info Issues that require more information to be provided, either by the author or through investigation.
Projects
None yet
Development

No branches or pull requests

2 participants