Skip to content

ci(caching): restore package cache#60

Open
kwk wants to merge 1 commit into
py-pkgs:mainfrom
kwk:ci-caching
Open

ci(caching): restore package cache#60
kwk wants to merge 1 commit into
py-pkgs:mainfrom
kwk:ci-caching

Conversation

@kwk
Copy link
Copy Markdown

@kwk kwk commented Nov 18, 2022

This adds a Restore cached dependencies step to the ci and cd jobs that tries to restored a cache of python packages (the ones stored in ~/.cache/pypoetry).

I've added it to my own small project and it resulted in a 26x performance boost when fetching python dependency packages (from 3:05minutes to 7seconds).

This will only work when people commit the poetry.lock file to their repo as described here.

Without caching:

Bildschirmfoto vom 2022-11-18 17-41-20

With caching:

Bildschirmfoto vom 2022-11-18 17-40-20

This adds a step to the ci and cd jobs that tries to restored a cache of
python packages (the ones stored in `~/.cache/poetry`).

I've added it to my own small project and it resulted in a 26x
performance boost when fetching python dependency packages (from
3:05minutes to 7seconds).

See kwk/ghgql#11 (comment)
@TomasBeuzen
Copy link
Copy Markdown
Collaborator

Hi @kwk - thanks very much for the PR! Just letting you know I've seen it. It's a good change and a small one - but I need to double check if I'll need to change anything in the py-pkgs book when merging this (I probably will want to add some text about this). I just went on parental leave, and may not get to this until the end of the year - but just wanted to jump on and say thanks, it's on my radar :)

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants