User tests: Successful: Unsuccessful:
Moves the libraries autoloader into the cache directory. It's been suggested as it's a more transient file and can safely be deleted - like other files in the cache. In the future we can even consider fully storing it in the cache.
It's also now documented in the README.md for those who might be cloning from github for the first time.
Check autoloader file is present in administrator/cache/autoload_psr4.php
Yes - once the page is created.
Status | New | ⇒ | Pending |
Category | ⇒ | Repository Libraries |
We shouldn’t forget to update the Patchtester accordingly when this is merged, because Patchtester after recent changes deletes the auto loader file when applying or reverting patches.
maybe we should better provide an API to that so we can all it from the "clear cache" page and the installer / updater too?
Labels |
Added:
?
|
Finally someone made it
Only minor issue here, if the cache driver not a "file" (eg APC, memcache) then a "clear cache" button will not delete this file, and it still need to be deleted manually. Maybe good idea to note it also.
What do you mean by that?
Nik suggested as it’s just a nested object we loop through and set into JavaScript JSON we can store it as a regular piece of cache potentially. Not going there quite yet but this is a logical step either way. We don’t want people randomly deleting files in library - but files in cache are just fine
This is the reason i proposed an helper / api to delete it so we can run it on any cache driver :-)
Hmm i dont get the JaceScript idea yet but i'm happy to try and learn something new when ready :-)
Forget JavaScript I mean json. I’m gonna go sleep before I write anything more on GitHub today!
This is the reason i proposed an helper / api to delete it so we can run it on any cache driver
There is an Event (new one in J4) onAfterInstall (or something like that). You can hook up the clean procedure there
We're already hooking on that https://github.com/joomla/joomla-cms/blob/4.0-dev/plugins/extension/namespacemap/namespacemap.php#L57 But it doesn't solve the issue of direct pulls from git (especially when we namespace existing extensions like we do at the moment - obviously as time goes on it will happen less - but it's still a thing for our local Joomla git work - in a real site there are no issues)
Title |
|
This is the reason i proposed an helper / api to delete it so we can run it on any cache driver :-)
This would be good too :) At the same time though it needs to be a long lived cache item (as we'll invalidate the cache entry when extensions change)
Status | Pending | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2020-03-28 19:27:25 |
Closed_By | ⇒ | wilsonge |
I was not talking about cache just that would be an API / helper for that ;)
We shouldn’t forget to update the Patchtester accordingly when this is merged, because Patchtester after recent changes deletes the auto loader file when applying or reverting patches.
I've made a PR for the Patchtester for that.
What do you mean by that?