Handling of `uv` cache for "big" packages
Maintainers usually reply within 3 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- docker, python
- Domain
- build-system, devops
Research direction
Start with python-pytorch/Dockerfile around line 10 and review issue #279 for the cache-directory context. Build a torch image while checking uv cache placement, cache reuse, and symlink behavior; done means the proposed settings avoid the /work space problem and preserve reuse of the preinstalled torch package, with the image-size tradeoff understood.
Written by the indexing model from the issue text.
Description
When installing torch (or other big package) in python image, we force uv to not use the cache (see https://github.com/InseeFrLab/images-datascience/blob/main/python-pytorch/Dockerfile#L10C33-L10C43). This means users who use uv for their project will have to download those packages again (even if there are already installed in the System python environment).
Moreover, the path of the cache directory in /work means that a lot of space is used for that cache, leading to "No space left" error (just installing torch occupies ~5Gb in cache).
One way to mitigate those issues would be :
- For torch images, remove the
--no-cacheflag onuv pip installcommands - Set cache directory for
uvoutside of/work - Set link-mode as
symlinkinstead of default
This should improve the experience for users using uv and the torch version installed when building the image, without degrading it for others.
One caveat is that the image size will increase significantly (+50%), leading to slower start time.
- Dominant language
- Shell
- Stars
- 43
- Forks
- 37
- Avg merge
- 4d 12h
- Merged PRs (30d)
- 10
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from InseeFrLab/images-datascience
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
InseeFrLab/images-datascience#438 · 3 comments ·
Maintainers usually reply within 3 days
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
InseeFrLab/images-datascience#407 ·
Maintainers usually reply within 3 days
-
migrate to aws config and credentials filesMay be free again @ihiverlet claimed this 548 days ago, and no pull request is open. Open
InseeFrLab/images-datascience#262 · 2 comments · 1 assignee ·
Maintainers usually reply within 3 days
-
Dependency DashboardOpen
Difficulty 5/5 Over a week Newbie friendliness 10/100
InseeFrLab/images-datascience#14 ·
Maintainers usually reply within 3 days
All issues in InseeFrLab/images-datascience
Similar issues
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 78/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
chapel-lang/chapel-vscode#144 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
tsukumogami/tsuku#2804 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
obra/superpowers#2651 ·
Maintainers usually reply within 1 day