Skip to content

Commit e8e35dd

Browse files
committed
upgrade Python version and Docker dependencies
1 parent 83deb86 commit e8e35dd

13 files changed

Lines changed: 4161 additions & 77 deletions

File tree

docker_containers/shabti_api/.gitignore

Lines changed: 0 additions & 2 deletions
This file was deleted.

docker_containers/shabti_api/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
ARG ACCELERATION_TYPE=cpu
22

3-
FROM astral/uv:0.10-python3.13-trixie-slim AS base
3+
FROM astral/uv:0.11.1-python3.14-trixie-slim AS base
44

55
RUN rm -f /etc/apt/apt.conf.d/docker-clean; echo 'Binary::apt::APT::Keep-Downloaded-Packages "true";' > /etc/apt/apt.conf.d/keep-cache
66
RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
@@ -17,10 +17,10 @@ CMD [ "uv", "run", "docker_run.py" ]
1717
EXPOSE 15131
1818

1919
FROM base AS cpu
20-
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml uv sync --no-install-project --no-sources --no-dev --extra cpu
20+
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml --mount=type=bind,source=uv.lock,target=uv.lock uv sync --no-install-project --no-sources --no-dev --extra cpu
2121

2222
FROM base AS cuda
23-
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml uv sync --no-install-project --no-sources --no-dev --extra cu126
23+
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml --mount=type=bind,source=uv.lock,target=uv.lock uv sync --no-install-project --no-sources --no-dev --extra cu126
2424

2525
FROM ${ACCELERATION_TYPE} AS final
2626
COPY . /app/shabti/

docker_containers/shabti_api/Dockerfile.local

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
ARG ACCELERATION_TYPE=cpu
22

3-
FROM astral/uv:0.10-python3.13-trixie-slim AS base
3+
FROM astral/uv:0.11.1-python3.14-trixie-slim AS base
44

55
COPY --from=python_packages ./isi_util /app/python_packages/isi_util/
66
COPY --from=python_packages ./shabti_util /app/python_packages/shabti_util/
@@ -22,10 +22,10 @@ ENV UV_HTTP_TIMEOUT=500
2222
CMD [ "uv", "run", "docker_run.py", "--development" ]
2323

2424
FROM base AS cpu
25-
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml uv sync --no-install-project --extra cpu
25+
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml --mount=type=bind,source=uv.lock,target=uv.lock uv sync --no-install-project --extra cpu
2626

2727
FROM base AS cuda
28-
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml uv sync --no-install-project --extra cu126
28+
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml --mount=type=bind,source=uv.lock,target=uv.lock uv sync --no-install-project --extra cu126
2929

3030
FROM ${ACCELERATION_TYPE} AS final
3131
COPY . /app/shabti/

docker_containers/shabti_api/pyproject.toml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[project]
22
name = "shabti-api"
33
version = "0.1.0"
4-
requires-python = ">=3.13, <3.14"
4+
requires-python = ">=3.14, <3.15"
55
dependencies = [
66
"beautifulsoup4~=4.14.3",
77
"configobj~=5.0.9",
@@ -20,14 +20,12 @@ dependencies = [
2020
]
2121
[project.optional-dependencies]
2222
cu126 = [
23-
"torch==2.7.1; sys_platform == 'linux' and platform_machine == 'x86_64'",
24-
"torchvision==0.22.1; sys_platform == 'linux' and platform_machine == 'x86_64'",
25-
"torchaudio==2.7.1; sys_platform == 'linux' and platform_machine == 'x86_64'"
23+
"torch==2.11.0; sys_platform == 'linux' and platform_machine == 'x86_64'",
24+
"torchvision==0.26.0; sys_platform == 'linux' and platform_machine == 'x86_64'"
2625
]
2726
cpu = [
28-
"torch==2.7.1; sys_platform == 'linux' and platform_machine == 'x86_64'",
29-
"torchvision==0.22.1; sys_platform == 'linux' and platform_machine == 'x86_64'",
30-
"torchaudio==2.7.1; sys_platform == 'linux' and platform_machine == 'x86_64'"
27+
"torch==2.11.0; sys_platform == 'linux' and platform_machine == 'x86_64'",
28+
"torchvision==0.26.0; sys_platform == 'linux' and platform_machine == 'x86_64'"
3129
]
3230
[tool.uv]
3331
required-environments = [
@@ -50,9 +48,6 @@ torch = [
5048
torchvision = [
5149
{ index = "pytorch-cu126", extra = "cu126" },
5250
]
53-
torchaudio = [
54-
{ index = "pytorch-cu126", extra = "cu126" },
55-
]
5651

5752
[[tool.uv.index]]
5853
name = "pytorch-cu126"

docker_containers/shabti_api/uv.lock

Lines changed: 4083 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docker_containers/shabti_web/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
FROM astral/uv:0.10-python3.13-trixie-slim
1+
FROM astral/uv:0.11.1-python3.14-trixie-slim
22

33
ENV PYTHONUNBUFFERED=1
44
ENV PYTHONPATH=/
55
WORKDIR /app/shabti_web/
66
ENV UV_LINK_MODE=copy
7-
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml uv sync --no-install-project
7+
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml --mount=type=bind,source=uv.lock,target=uv.lock uv sync --no-install-project
88
COPY . /app/shabti_web/
99
RUN --mount=type=cache,target=/root/.cache/uv uv sync --locked
1010
RUN --mount=type=cache,target=/root/.cache uv pip install -r requirements.txt

docker_containers/shabti_web/Dockerfile.local

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM astral/uv:0.10-python3.13-trixie-slim
1+
FROM astral/uv:0.11.1-python3.14-trixie-slim
22

33
COPY --from=python_packages ./shabti_util /app/python_packages/shabti_util/
44
COPY --from=python_packages ./shabti_types /app/python_packages/shabti_types/
@@ -9,7 +9,7 @@ ENV PYTHONUNBUFFERED=1
99
ENV PYTHONPATH=/
1010
WORKDIR /app/shabti_web/
1111
ENV UV_LINK_MODE=copy
12-
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml uv sync --no-install-project
12+
RUN --mount=type=cache,target=/root/.cache/uv --mount=type=bind,source=pyproject.toml,target=pyproject.toml --mount=type=bind,source=uv.lock,target=uv.lock uv sync --no-install-project
1313
COPY . /app/shabti_web/
1414
RUN --mount=type=cache,target=/root/.cache/uv uv sync --locked
1515
RUN --mount=type=cache,target=/root/.cache uv pip install -r local_requirements.txt

docker_containers/shabti_web/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[project]
22
name = "shabti-web"
33
version = "0.1.0"
4-
requires-python = ">=3.13, <3.14"
4+
requires-python = ">=3.14, <3.15"
55
dependencies = [
66
"htmltools==0.6.0",
77
"humanize==4.15.0",

0 commit comments

Comments
 (0)