Use travis native cache #6822

Merged
merged 1 commit into from Aug 3, 2016

Conversation

Projects
None yet
4 participants

mdboom added the needs_review label Jul 24, 2016

@jenshnielsen jenshnielsen commented on an outdated diff Jul 24, 2016

sudo: false
cache:
- directories:
- - $HOME/.ccache
- - $HOME/.cache/pip
- - $HOME/.cache/matplotlib
- - $HOME/Library/Caches/pip
+ - ccache
@jenshnielsen

jenshnielsen Jul 24, 2016

Owner

It's not clear from the travis docs that pip caches $HOME/Library/Caches/pip which is the pip cache directory on OSX.

Member

Kojoley commented Jul 24, 2016

As per travis-ci/travis-ci#4011 it is now support OSX too.

Owner

jenshnielsen commented Jul 24, 2016

I know that caching is supported on OSX that's why I added $HOME/Library/Caches/pip to the list of cached directories. But the documentation that you link to says that doing

cache:
  - pip

only adds

~/.cache/pip

to the cache and not $HOME/Library/Caches/pip

I can't see anything in the docs or the issue that you are linking to that indicates otherwise.

If you compare the OSX build of your PR to one of the Linux ones it seems to confirm that.
Linux:
https://s3.amazonaws.com/archive.travis-ci.org/jobs/146969225/log.txt
OSX:
https://api.travis-ci.org/jobs/146969231/log.txt?deansi=true

In the osx build all the dependencies are redownloaded.

Member

Kojoley commented Jul 24, 2016 edited

Hmm. Even ccache was not used and stored on OSX

Edit: on Linux ccache does not work too (it requires language: c, see travis-ci/travis-ci#5853)

Member

Kojoley commented Jul 24, 2016

I have found that apt-get and brew currently is not cached. Should I reuse this PR or open a new one? (this seems can be done with cache: apt)

Owner

jenshnielsen commented Jul 24, 2016

Good catch. I think it's fine to use this one you can always change the title in the github web interface

Member

Kojoley commented Jul 24, 2016

Sigh. It is not possible now travis-ci/travis-ci#5876

@Kojoley Kojoley Use travis native cache
121d0fc
Member

Kojoley commented Jul 24, 2016

Summary:

  • There is no way to cache apt-get and brew packages with cache: apt
    (it is no longer exists travis-ci/travis-ci#5876)

  • apt-get is fast as is Fetched 158 MB in 3s (46.5 MB/s) (sometimes it slowdowns to 15 sec)

  • Storing brew cache gives no or insignificant speed up (even makes cache store phase much longer)

  • cache: ccache is not supported with language: python (travis-ci/travis-ci#5853)

  • cache: pip does not work on OSX

  • global cannot be used in cache (like in env) (workarounded with copy-paste):

    cache:
      global:
        pip: true
        directories:
          - $HOME/.cache/matplotlib
    
    matrix:
      include:
        - os: osx
          osx_image: xcode7.3
          cache:
            pip: false
            directories:
              - $HOME/Library/Caches/pip

I have updated appveyor.yml with comments about results above.

tacaswell added this to the 2.1 (next point release) milestone Jul 26, 2016

@tacaswell tacaswell merged commit f078b24 into matplotlib:master Aug 3, 2016

2 of 3 checks passed

continuous-integration/appveyor/pr AppVeyor build failed
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
coverage/coveralls Coverage increased (+0.002%) to 70.351%
Details

tacaswell removed the needs_review label Aug 3, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment