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

Client disconnects when buying from a playershop (JsonParseException) #353

Closed
unclesom opened this issue Sep 6, 2020 · 5 comments
Closed
Labels
server issue Issues caused by the used server (Spigot/Paper/etc.)

Comments

@unclesom
Copy link

unclesom commented Sep 6, 2020

Plugin Version

3.11 (build 213)

Plugin Config

https://pastebin.pl/view/837a4ecb

Server Version

Paper 184 (1.16.2)

What other plugins are you running?

image

What is happening?

When a player buys from a shop, the owner of the shop will be kicked from the server. This can be usually fixed with a server restart but usually reoccurs after the next restart.

The message that the owner of the shop gets when kicked:
https://cdn.discordapp.com/attachments/735489735740358727/752182816556711996/unknown.png

@Phoenix616
Copy link
Member

Phoenix616 commented Sep 6, 2020

Please test if this still happens on the latest development builds. Also please make sure to test without any plugin and when testing with plugins that all of them (especially the ones interacting with chat/packets) are updated to 1.16.2.

@unclesom
Copy link
Author

I tested the new development build and it seemed to work for a while until today when it started crashing again. Are there any chat plugins that would directly cause this crash?

@Phoenix616
Copy link
Member

Phoenix616 commented Sep 24, 2020

It is highly unlikely that this error is caused by a plugin directly. It's either a Bug in the BungeeCord-Chat API, in Gson directly or maybe caused by a plugin not relocating Gson. For more information see SpigotMC/BungeeCord#2935 and the related Spigot issue.

Remove the hover info from the transaction messages if you don't want to risk running into this issue.

@Phoenix616 Phoenix616 added the server issue Issues caused by the used server (Spigot/Paper/etc.) label Sep 24, 2020
@Phoenix616 Phoenix616 changed the title Crash issue when buying from a playershop Client disconnects when buying from a playershop (JsonParseException) Sep 24, 2020
@Phoenix616 Phoenix616 pinned this issue Nov 20, 2020
@Phoenix616
Copy link
Member

As several people have asked how to remove the hover: The messages are using the MineDown syntax to add the hover information so if you need to remove them due to this server issue then you can simply remove the [text](hover) to just say text.

E.g. the SOMEBODY_BOUGHT_FROM_YOUR_SHOP message would go from [%buyer bought %item for %price.](&7In world: &f%world\n&7At position: &f%x/%y/%z) to just %buyer bought %item for %price.. If course you could include the other information like the place in the message too.

I've also create a replacement lang.en.yml file which does not use hover messages but includes some more information in the text directly instead of the hover if you just want to drop that in directly without defining your own syntax.

Hopefully I will be able to work around this issue by moving ChestShop to the kyori adventure text library soon once they fix some issues on the latest Java version. (Which would also allow for the plugin to run on pure CraftBukkit again)

@Phoenix616
Copy link
Member

Should be fixed with 51e9d5f now.

Please re-open the ticket if this issue still occurs with the builds including that commit.

@Phoenix616 Phoenix616 unpinned this issue Jun 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
server issue Issues caused by the used server (Spigot/Paper/etc.)
Projects
None yet
Development

No branches or pull requests

2 participants