Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
The cache is not always updated when a plugin is installed or updated #143
I stumbled upon this issue which occurs with plugins that have custom routes defined in their routing.yml file. The behavior is that after the plugin is installed, navigating to the custom route produces in "Not Found" message. After a while the route starts working.
I tested with Mibew 2.1.0 using the Wurrd Authorization API plugin. This issue is intermittent as I couldn't consistently reproduce it. I also couldn't determine how long the "while" is before it starts working. However, a workaround is to delete the "stash" directory under /cache. Navigating to the custom route will cause the cache to be regenerated this time with containing the route information.
As I haven't been able to consistently reproduce it, this is more of a question to you guys.
I've been able to reproduce consistently now. Here are the steps:
If this issue exists, the route will still be returned as "Not found"
The issue here is that if the plugin is not properly configured, the plugin enable logic doesn't get to clear the cache. When the config properties are entered, the plugin starts working without the cache being cleared. A fix would be either to force the user to enable the plugin again, or to clear the cache if the plugin's state is changing from not initialized to working.