-
-
Notifications
You must be signed in to change notification settings - Fork 29
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
Readme Instructions do not appear to work as described #70
Comments
Simplest possible BrocFile:
This shows |
@joliss is this something you can comment on? Feels like I've built a very simple plugin but I can't for the life of me work out how to enable caching |
for avoidance of doubt I'm running with broccoli-clext |
Seems like caching only works if you leave broccoli running but if you run broccoli twice the cache doesn't work - build gets called twice. |
this is by design. broccoli-persistent-filter does have a second level of caching, which allows it to persist beyond the life of the process. But it is very tricky to get the cache keys just right, and with persistent-filter the inputs aren't opaque but with this tool... they are quite tricky. Persistent-filter largely works as expected, but it is still quite riddled with caveats and some bugs that must be fixed. TL;DR that sort of caching, done without issue will most likely (for now anyways) be a one-off solution for the specific use-case. It is possible to solve this problem, but deriving the appropriate cache key is surprisingly quite difficult, especially in the general case. |
Where are the caveats documented? |
@BryanCrotaz typical cache key problems, if something isn't included in the cache key, and it alone changes you will have a stale build. |
What needs to go in the cache key other than the last modified of the source files? |
@BryanCrotaz what other information may change between restarts? The source-code that is being executed (and their dependent files), the node version, the OS, the ENV vars etc.etc. |
Example: https://github.com/silver-curve/broccoli-archiver
build
function creates a zip file from the input treeExpected zip file is created in both output folder and cache folder
Actual zip file is created in output folder only. Cache folder is empty
Adding the following options makes no difference:
The text was updated successfully, but these errors were encountered: