Switch to uv

This commit is contained in:
Zoe Roux 2025-05-16 19:21:33 +02:00
parent a3ae9fb64e
commit 96037447d2
No known key found for this signature in database
6 changed files with 1183 additions and 14 deletions

View File

@ -1,5 +1,5 @@
**
!/requirements.txt
!scanner/**.py
!/pyproject.toml
!/uv.lock
!/scanner/**.py
!/migrations/**.sql

View File

@ -1,8 +1,12 @@
FROM python:3.13
ENV UV_COMPILE_BYTECODE=1 UV_LINK_MODE=copy UV_PYTHON_DOWNLOADS=0
WORKDIR /app
COPY ./requirements.txt .
RUN pip3 install --no-cache-dir --upgrade -r ./requirements.txt
RUN --mount=from=ghcr.io/astral-sh/uv,source=/uv,target=/bin/uv \
--mount=type=cache,target=/root/.cache/uv \
--mount=type=bind,source=uv.lock,target=uv.lock \
--mount=type=bind,source=pyproject.toml,target=pyproject.toml \
uv sync --locked
COPY . .

View File

@ -1,3 +1,23 @@
[project]
name = "scanner"
version = "0.1.0"
description = "Register video files to kyoo"
readme = "README.md"
requires-python = ">=3.13"
dependencies = [
"aiohttp>=3.11.18",
"asyncpg>=0.30.0",
"fastapi[standard]>=0.115.12",
"guessit",
"langcodes>=3.5.0",
"pydantic>=2.11.4",
"pyjwt[crypto]>=2.10.1",
"watchfiles>=1.0.5",
]
[tool.uv.sources]
guessit = { git = "https://github.com/zoriya/guessit" }
[tool.ruff.format]
indent-style = "tab"

View File

@ -1,8 +0,0 @@
fastapi[standard]
pydantic
guessit@git+https://github.com/zoriya/guessit
aiohttp
watchfiles
langcodes
asyncpg
pyjwt[crypto]

View File

@ -14,6 +14,7 @@ in
pkgs.mkShell {
packages = with pkgs; [
python
uv
ruff
fastapi-cli
pgformatter

1152
scanner/uv.lock generated Normal file

File diff suppressed because it is too large Load Diff