Skip to content

CI: Upgrade "actions/(checkout|cache)" to version 2 #41336

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

Merged
merged 4 commits into from
May 24, 2021

Conversation

ShaharNaveh
Copy link
Member

According to the change log of both "checkout" and "cache" this should increase performance.


Fell free to close this PR if this was already discussed, I haven't saw any discussion about this topic.

@ShaharNaveh ShaharNaveh changed the title CI: Upgrade "actions/(checkout|cache)" to version 2 CI: Upgrade "actions/(checkout|cache)" to version 2 May 5, 2021
@ShaharNaveh ShaharNaveh added the CI Continuous Integration label May 5, 2021
Copy link
Member

@fangchenli fangchenli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To get all the tags, you need

    - uses: actions/checkout@v2
      with:
        fetch-depth: 0

@datapythonista
Copy link
Member

@ShaharNaveh do you have time to have a look at the comment and leave the CI green?

@ShaharNaveh
Copy link
Member Author

@ShaharNaveh do you have time to have a look at the comment and leave the CI green?

OFC:)

@datapythonista
Copy link
Member

Checked quickly, and this does seem to speed up the checkout a bit, from around 28 second to around 22 (not sure if very significant, but nice to use the latest version of the action regardless).

What I see is that if we don't fetch all tags and branches the checkout is almost immediate (like 2 seconds). I think we need them for the release notes, but I'm not aware of anything else that should require them. @ShaharNaveh would you mind having a look and see if the fetch-depth is required for all builds. I don't think anything other than the docs build should need them.

Also, if you want to have a better look at timings, including the ones of the cache action (I didn't check those), that would be great.

@ShaharNaveh
Copy link
Member Author

ShaharNaveh commented May 12, 2021

Checked quickly, and this does seem to speed up the checkout a bit, from around 28 second to around 22 (not sure if very significant, but nice to use the latest version of the action regardless).

What I see is that if we don't fetch all tags and branches the checkout is almost immediate (like 2 seconds). I think we need them for the release notes, but I'm not aware of anything else that should require them. @ShaharNaveh would you mind having a look and see if the fetch-depth is required for all builds. I don't think anything other than the docs build should need them.

@datapythonista The way I decided where each fetch-depth: 0 , was to look at the failed tests in e35cc1b and I added the fetch-depth: 0 wherever there was a failing test.

Also, if you want to have a better look at timings, including the ones of the cache action (I didn't check those), that would be great.

I did see an improvement with the cache, but the difference is 1s.
But the v2 of the cache action is handling the cache with the zstd compression, which means that the cache size can be larger, so I do expect to get an improvement overtime, as the cache will get larger and larger.

Copy link
Member

@datapythonista datapythonista left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the info @ShaharNaveh. Sounds good. I'd like to understand why we need tags or branches for so many builds, but that's unrelated to this PR.

Thanks for working on this!

@mroeschke mroeschke merged commit 55e5854 into pandas-dev:master May 24, 2021
@mroeschke
Copy link
Member

Thanks @ShaharNaveh

@mroeschke mroeschke added this to the 1.3 milestone May 24, 2021
@simonjayhawkins
Copy link
Member

We've had several failures in the last couple of days, could there be a compatibility issue with conda-incubator/setup-miniconda@v2 or maybe this was failing before and I didn't notice.

@datapythonista
Copy link
Member

We've had several failures in the last couple of days, could there be a compatibility issue with conda-incubator/setup-miniconda@v2 or maybe this was failing before and I didn't notice.

I saw a connection error on conda, are those the failures you are referring to? We can revert, but probably better to try to understand the problem better first.

TLouf pushed a commit to TLouf/pandas that referenced this pull request Jun 1, 2021
* CI: Upgraded version of "actions/checkout"

* CI: Upgraded version of "actions/cache"

* Added fetch-depth: 0

Co-authored-by: ShaharNaveh <>
JulianWgs pushed a commit to JulianWgs/pandas that referenced this pull request Jul 3, 2021
* CI: Upgraded version of "actions/checkout"

* CI: Upgraded version of "actions/cache"

* Added fetch-depth: 0

Co-authored-by: ShaharNaveh <>
@ShaharNaveh ShaharNaveh deleted the CI-checkout-cache-V2 branch August 26, 2021 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants