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

Updating a plugin "outside" the plugin manager appears to break the plugin state cache #23

Open
sylae opened this issue Feb 19, 2023 · 4 comments
Labels
bug Something isn't working

Comments

@sylae
Copy link
Member

sylae commented Feb 19, 2023

This could be a factor of having two Plugin Managers running (one being the one shipped with openplanet, the other being my dev copy), but just in case this is indicative of a possible issue with the plugin cache i thought i'd report this.

I updated Editor Trails to 1.1 using my "dev" version of the plugin manager, and this appears to have messed up the "normal" manager's state and it remains convinced that v1.0 is installed. This persists through trackmania restarts as well as when just the "normal" manager is installed.

anyway obviously this is a bit of an edge case, but like i said, idk if it's just a symptom of something that Might Actually Be An Issue For Normal People, yknow?

image

@codecat codecat added the bug Something isn't working label Feb 20, 2023
@skybaks
Copy link
Contributor

skybaks commented May 19, 2023

I just ran into this issue. I have a plugin folder, but I briefly tested with a zipped version of the plugin. After I was done testing I deleted the zipped version.
Now, the plugin manager is notifying me of updates even though my plugin folder is up to date with the published version.
This is because updating the PluginCache.json file is skipped for non-zipped plugins so the old version I briefly tested with is stuck in the cache file with no way of getting updated or removed.
As part of a potential solution to this it would be nice if there were more checks about what the plugin source was for any given loaded plugin before notifying of an update.

@skybaks
Copy link
Contributor

skybaks commented May 21, 2023

I fixed my issue by manually deleting the PluginCache.json file when the game was closed. What is the purpose of saving plugin versions to this file? Wouldn't it be easy enough to read all the plugin version into memory once when the game starts up?

@skybaks
Copy link
Contributor

skybaks commented Aug 6, 2023

I'm still seeing this issue. I would happily open a pull request to delete the cache file but I don't want to do that without understanding why it existed to begin with.

@codecat
Copy link
Member

codecat commented Aug 6, 2023

What is the purpose of saving plugin versions to this file? Wouldn't it be easy enough to read all the plugin version into memory once when the game starts up?

No, because plugins won't exist in memory if they are unloaded (for example, they are blocked by the server).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants