IntellectualSites / IntellectualSites/PlotSquared
Persistent meta is not reused
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 653
- Forks
- 975
- Avg merge
- 2m
- Merged PRs (30d)
- 6
Description
Server Implementation
Purpur
Server Version
1.17.1
Describe the bug
Normally in ps 5.x you only had to set the flags chatspy and worldedit once. From that time forward you could join the server whenever you want and those flags would still be present.
Nowadays. every time you join, you have to enter plot toggle worldedit and plot toggle chatspy in order to make use of these flags.
I think this is managed by this setting:
# Stores user metadata in a database
persistent-meta: true
I checked my database. There are now 9 entries for my uuid. 7 Of them contain attrib_worldedit and 2 contains attrib_chatspy
Setting the flags again adds more entries. And they work during that session. So the flags are properly set and saved to the database.
PlotSquared just doesn't retrieves the saved flags to use them.
To Reproduce
- join
- execute plot toggle worledit
- see that it confirms that it's set
- check database
- rejoin and check again
Expected behaviour
Worldedit and chatspy to be persistent and set once, until you actively set it off (or if the permission to set this flag is taken away).
Screenshots / Videos
No response
Error log (if applicable)
No response
Plot Debugpaste
https://athion.net/ISPaster/paste/view/5774a12c3f7f41d7a988159a896993af
PlotSquared Version
PlotSquared version 6.1.2-Premium
Checklist
- I have included a Plot debugpaste.
- I am using the newest build from https://www.spigotmc.org/resources/77506/ and the issue still persists.
Anything else?
When this is solved, I (or PS) should de-double the database to contain only 1 flag per uuid to keep the database sane.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the persistent-meta behavior on PlotSquared 6.1.2-Premium with the provided steps, then inspect how database entries for attrib_worldedit and attrib_chatspy are loaded when a player rejoins. Done means saved flags are restored across sessions and repeated toggles do not create duplicate entries for the same UUID.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100