-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Cache dependencies on github actions (#1296) #1337
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm learning everyday 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So that was impressive! 🤯
9ecf9b9
☂️ Python Coverage
Overall Coverage
New FilesNo new covered files... Modified FilesNo covered modified files...
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR only covers partial tests. Why not the overall tests as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤯🤯🤯
The overall tests uses the install/action.yml file for installation of the dependencies. The cache is already implemented in that file. |
We can also remove the python setup within overall-tests.yml file since it will be setup in the install/action.yml file. @florian-vuillemot can you confirm this |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍👍
Caching the frontend build is also added! |
LGTM! Great job @dinhlongviolin1 |
@dinhlongviolin1 Let's merge it if that's fine for everyone so we can finally benefit from it. |
97cad62
Resolve #1296
Caching for both npm and pipenv (for tests only). Deployment/build will still do everything from scratch.
Caching was also added for frontend build.
For npm, the dependency was declared and those will be used to hash as the cache name.
For pipenv, the recommended file is
Pipfile.lock
. But since we don't usePipfile.lock
(mainly due to multiple os support),Pipfile
will be used. We might have to manually delete the cache from here if any dev packages get a major/breaking update. Pipenv caching will work both for the min Pipfile and max Pipfile as those will be produce 2 different caches due to the different file hashes.The cache will be removed automatically after 7 days if not used in any action. There is no limit on the number of cache, but there is a hard limit of 10 GB of cache per repo.