Skip to content

Download and cache pip packages as part of easyinstall#779

Merged
rdmark merged 1 commit intodevelopfrom
akuker-precache-pip
Jul 31, 2022
Merged

Download and cache pip packages as part of easyinstall#779
rdmark merged 1 commit intodevelopfrom
akuker-precache-pip

Conversation

@akuker
Copy link
Copy Markdown
Member

@akuker akuker commented Jul 31, 2022

When the pre-made RaSCSI disk image is created, it will download all of the pip packages the first time it boots. Especially on a Pi zero, this can take a long time. Several users have thought the web interface was broken because it took so long for it to start up the first time.

This change is an attempt to cache the python packages at install/build time. The expectation is that the venv will be created with the pre-downloaded pip packages.

@akuker akuker requested a review from rdmark July 31, 2022 02:04
@akuker akuker requested a review from erichelgeson as a code owner July 31, 2022 02:04
Copy link
Copy Markdown
Member

@rdmark rdmark left a comment

Choose a reason for hiding this comment

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

While I'm not familiar with pip caching, some googling suggests that it does indeed cache packages globally unless you use the --no-cache-dir argument.

I ran some tests, doing a few incremental commits that modified requirements.txt. It seems to retain cached packages better with this change.

@rdmark rdmark merged commit 4b874ab into develop Jul 31, 2022
@rdmark rdmark deleted the akuker-precache-pip branch July 31, 2022 06:38
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