Skip to content
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

[CI] don't download cache if contexts have not changed #1058

Merged

Conversation

zacharyburnett
Copy link
Collaborator

@zacharyburnett zacharyburnett commented Aug 2, 2024

Since the cache is defined by the context, if the combined cache exists with the given name then there is no need to download it, only check its existence with lookup-only. If it doesn't exist, then save it at the end with the dedicated actions/cache/save action.

This is a transparent change to the user, but should decrease the CI run time because the workflow is not needlessly downloading the cache every time.

@zacharyburnett
Copy link
Collaborator Author

zacharyburnett commented Aug 2, 2024

This reduces the workflow execution by 3 seconds and 204 MB:

  • existing workflow:
    Screenshot 2024-08-02 at 9 29 21 AM
  • this change: image

@zacharyburnett zacharyburnett marked this pull request as ready for review August 2, 2024 13:31
@zacharyburnett zacharyburnett requested a review from a team as a code owner August 2, 2024 13:31
@zacharyburnett zacharyburnett merged commit f9a836d into spacetelescope:master Aug 2, 2024
12 of 13 checks passed
@zacharyburnett zacharyburnett deleted the ci/optimize_cache branch August 2, 2024 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants