coala / coala

coala provides a unified command-line interface for linting and fixing all your code, regardless of the programming languages you use.
https://coala.io/
GNU Affero General Public License v3.0
3.55k stars 1.31k forks source link

Travis docs cache invalidated #5614

Open jayvdb opened 6 years ago

jayvdb commented 6 years ago

Each master travis job ends with

change detected (content changed, file is created, or file is deleted):
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.abstractions.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.aspects.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.languages.definitions.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.languages.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.languages.documentation.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.naming_conventions.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bearlib.spacing.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.bears.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.collecting.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.core.doctree
/home/travis/build/coala/coala/docs/_build/doctrees/coalib.doctree
...

This is happening even when the job doesnt modify the source for the docs, like https://travis-ci.org/coala/coala/builds/401439163

One reason is these are binary files (pickles?), and they include the full path of each file, which on travis means that the masters catch entry includes /home/travis/build/coala/coala/ while the fork contains /home/travis/build/jayvdb/coala/. As this is happening on master builds also, there is also something else in these files causing it to be invalidated.

In that directory is also a environment.pickle and index.doctree, and they are not being invalidated. They should be cached, especially environment.pickle which is very large.

jayvdb commented 6 years ago

After removing all doctrees, docs/_build/doctrees/environment.pickle is shown as modified.

Also lots of changes in /home/travis/.cache/pip/http, so this issue alone wont stop the cache from being invalidated by every build of master.

jayvdb commented 6 years ago

Caching only /home/travis/.cache/wheels/ works well. The files in /home/travis/.cache/pip/http are of unrecognised format. Need to investigate what pip is using. Also need to re-test caching immediately after a few build of master, as the pip cache may be invalidated atm due to new released versions of packages since the last build.