-
Notifications
You must be signed in to change notification settings - Fork 11
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
chore: use UV as package manager #245
base: main
Are you sure you want to change the base?
Conversation
b2d016f
to
cc0dbad
Compare
a27faf2
to
e647868
Compare
api/Dockerfile
Outdated
COPY uv.lock uv.lock | ||
|
||
RUN mkdir -p /.cache/uv && \ | ||
chown -R 1000:1000 /.cache/uv/ |
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.
not sure if this is best practice, but uv needs read/write access to this folder. (even with --no-cache)
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.
Can undo this chown after running "uv sync". At least in the prod image
67f9a39
to
14f0c1d
Compare
pre-commit = ">=3" | ||
pytest = "^7.2.2" | ||
mongomock = "^4.1.2" | ||
requires-python = ">=3.10" |
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.
requires-python = ">=3.10" | |
requires-python = ">=3.10" |
Should probably refine this, docker uses 3.11 now, while locally/pre-commit using uv will select latest supported python version -> 3.12
825f615
to
bc7b039
Compare
bc7b039
to
d2f01b8
Compare
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.
Let's try it!
How is Snyk support? 😛
Heh! Good question. I have lost access to the Snyk team. UV follows the standard specification for dependencies in pyproject.toml (https://packaging.python.org/en/latest/specifications/pyproject-toml/), but Poetry has its own syntax. Knowing snyk I am betting they don't support it.. |
1cf5a23
to
6f29e30
Compare
04ed7b3
to
c73e069
Compare
Why is this pull request needed?
This pull request is mainly for testing out UV as an alternative for poetry
What does this pull request change?
Replace poetry with UV
Makes the CI slightly faster, and setting up a new python environment much faster.
without uv and cache:
uv with cache:
Issues related to this change: