-
Notifications
You must be signed in to change notification settings - Fork 725
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
invalidate travis cache when packrat.lock changes #7246
Comments
I am unfamiliar with the tooling, so I need some background information. How does the tool work with |
I think this can be remedied by caching only the |
OK. I guess that's an issue with user configuration and modifying the documentation, then? |
Yep |
thanks @jimhester for addressing this so quickly, amazing work as always. I'm afraid this still does not work as I had expected, I probably did not phrase the issue correctly. expected behavior: I'd like to have travis to cache So, I was hoping for something like this:
observed behavior
Only solution, for now, is to manually delete the cache, when I change the dependencies. I apologise for nagging about this thing; not a lot of people appear to use This still seems like a fairly important piece of the reproducibility puzzle, and so far, I've failed to come up with a solution that works for me and colleagues. Ps.: I have tried all of the below
|
I am not sure why the cache with only the I personally I am not sure this it is a good idea to begin with, and am not that familiar with packrat. I also cannot debug this further without a build log. If you want further assistance I would suggest opening a packrat issue. |
very sorry about the missing reproducible example @jimhester and thank you for taking the time. I've now added a new minimal repo with respective build fails. This is the failing build which should have worked, because the commit did include a changed As expected, Does that help make it more informative for you? and/or should I still open an issue over at |
Please open an issue there, I don't know enough about packrat internals to know why it is not picking up the |
To restore the packrat library given a lockfile, you need to call I assume the simplest fix is to just run:
or something similar to hydrate the library, rather than the |
thanks @kevinushey not sure why I didn't think of that myself. It appears that we actually need both bootstrap and restore, because with only This now works:
As suggested by @jimhester I'll open up an issue over at In the meantime, I'll close this issue, because it's done from the Travis end of things. Thanks so much. |
@jimhester has suggested a really cool way to cache packrat compilations, which makes the travis builds a lot faster (see #6504).
There's just one (small) problem: when the
packrat.lock
changes, the Travis cache is not automatically invalidated, resulting in build fails.Once you delete the cache, and restart the build, things work out.
This isn't a huge problem, but a bit annoying and a stumbling block for new users, with packrat already being a little complicated.
Any chance this could be added to the default travis setup?
The text was updated successfully, but these errors were encountered: