Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/test_poetry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:

strategy:
matrix:
python-version: [3.12]
python-version: [3.13]

steps:
- name: Checkout repository
Expand Down
56 changes: 30 additions & 26 deletions docker/cpu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM ubuntu:24.04 AS base

ARG PYTHON_VERSION=3.12
ARG PYTHON_VERSION=3.13

ENV DEBIAN_FRONTEND=noninteractive
ENV WORKDIR /app/
Expand All @@ -9,15 +9,15 @@ WORKDIR /opt

# install dev tools
RUN apt-get update && apt-get install -y \
vim neovim nano \
git git-lfs \
zip unzip \
curl wget make build-essential xz-utils file tree \
sudo \
dnsutils \
tzdata language-pack-ja \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
vim neovim nano \
git git-lfs \
zip unzip \
curl wget make build-essential xz-utils file tree \
sudo \
dnsutils \
tzdata language-pack-ja \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

# for Japanese settings
# ENV TZ Asia/Tokyo
Expand All @@ -29,22 +29,26 @@ ENV LANGUAGE en_US

# install Python
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
software-properties-common \
&& add-apt-repository ppa:deadsnakes/ppa -y \
&& apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential libssl-dev libffi-dev \
python${PYTHON_VERSION} \
python${PYTHON_VERSION}-dev \
python3-pip \
# python${PYTHON_VERSION}-distutils \ # for python3.12
&& ln -s /usr/bin/python${PYTHON_VERSION} /usr/local/bin/python3 \
&& ln -s /usr/bin/python${PYTHON_VERSION} /usr/local/bin/python \
&& apt-get purge -y --auto-remove software-properties-common \
&& rm -rf /var/lib/apt/lists/*

## install Poetry
&& apt-get install -y --no-install-recommends \
software-properties-common \
&& add-apt-repository ppa:deadsnakes/ppa -y \
&& apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
build-essential libssl-dev libffi-dev \
python${PYTHON_VERSION} \
python${PYTHON_VERSION}-dev \
python3-pip \
# python${PYTHON_VERSION}-distutils \ # for python3.13 if required
&& ln -s /usr/bin/python${PYTHON_VERSION} /usr/local/bin/python3 \
&& ln -s /usr/bin/python${PYTHON_VERSION} /usr/local/bin/python \
&& apt-get purge -y --auto-remove software-properties-common \
&& rm -rf /var/lib/apt/lists/*

# install rust
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/root/.cargo/bin:$PATH"

## install uv
COPY --from=ghcr.io/astral-sh/uv:latest /uv /bin/uv

WORKDIR ${WORKDIR}
Expand Down
72 changes: 38 additions & 34 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,51 +3,38 @@ name = "project"
version = "0.1.0"
description = ""
authors = [{ name = "Tatsuki Okada", email = "tatsukio0522@gmali.com" }]
requires-python = ">=3.12"
requires-python = ">=3.13"
dependencies = [
"python-dotenv>=1.0.0",
"setuptools>=69.0.3",
"fire>=0.5.0",
"pydantic>=2.5.3",
"beautifulsoup4>=4.12.2",
"selenium>=4.16.0",
"fastapi>=0.108.0",
"uvicorn>=0.25.0",
"matplotlib>=3.9.0",
"pandas>=1.4.2",
"seaborn>=0.11.2",
"japanize-matplotlib>=1.1.3",
"numpy>=2.2.0",
"tqdm>=4.64.0",
"scikit-learn>=1.6.0",
"setuptools>=80.9.0",
"fire>=0.7.1",
"pydantic>=2.12.4",
"beautifulsoup4>=4.14.0",
"selenium>=4.38.0",
"playwright>=1.56.0",
"fastapi>=0.121.0",
"uvicorn>=0.38.0",
"polars>=1.35.2",
"pandas>=2.3.3",
"openpyxl>=3.1.2",
"polars>=0.20.31",
"matplotlib>=3.10.7",
"seaborn>=0.13.2",
"japanize-matplotlib>=1.1.3",
"matplotlib-fontja>=1.1.0",
"numpy>=2.3.4",
"tqdm>=4.67.1",
"scikit-learn>=1.7.2",
"aiohttp>=3.9.5",
"tenacity>=8.4.1",
"playwright>=1.44.0",
"tenacity>=9.1.2",
"toml>=0.10.2",
]

[tool.hatch.build.targets.wheel]
packages = ["src/project", "src"]

[tool.uv]
dev-dependencies = [
"jupyterlab>=3.3.4",
"marimo>=0.13.3",
"mypy>=1.11.2",
"nbstripout>=0.7.1",
"pre-commit>=4.0.1",
"pytest>=8.3.3",
"ruff>=0.6.9",
"tox>=4.21.2",
"types-pyyaml>=6.0.12.20250402",
"types-toml>=0.10.8.20240310",
]

[tool.ruff]
line-length = 119
target-version = "py312"
target-version = "py313"
exclude = [".git", ".venv", "__pycache__", "data", "dist", "misc", "notebooks", "prof", "tmp", "workspacea", ".tox"]

[tool.ruff.format]
Expand All @@ -72,7 +59,7 @@ split-on-trailing-comma = true
keep-runtime-typing = true

[tool.mypy]
python_version="3.12"
python_version="3.13"
files = "src"
ignore_missing_imports = true
disallow_untyped_defs = true
Expand All @@ -88,3 +75,20 @@ filterwarnings = ["ignore::DeprecationWarning",]
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[dependency-groups]
dev = [
"jupyterlab>=4.1.0",
"marimo>=0.17.0",
"tox>=4.30.0",
"pytest>=9.0.0",
"pytest-xdist>=3.8.0",
"pytest-asyncio>=1.3.0",
"ruff>=0.14.4",
"mypy>=1.18.0",
"ty>=0.0.1a26",
"nbstripout>=0.8.0",
"pre-commit>=4.3.0",
"types-pyyaml>=6.0.12.20250402",
"types-toml>=0.10.8.20240310",
]
6 changes: 3 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
[tox]
envlist = py312, lint
envlist = py313, lint

[gh-actions]
python =
3.12: py312, lint
3.13: py313, lint

[testenv]
allowlist_externals =
pytest
skip_install = true
commands =
pytest tests/
pytest tests/ -n auto

[testenv:lint]
allowlist_externals =
Expand Down
Loading