50 lines
1.0 KiB
TOML
50 lines
1.0 KiB
TOML
|
|
[build-system]
|
||
|
|
requires = ["setuptools>=75"]
|
||
|
|
build-backend = "setuptools.build_meta"
|
||
|
|
|
||
|
|
[project]
|
||
|
|
name = "election-data"
|
||
|
|
version = "0.1.0"
|
||
|
|
description = "凍蒜 2026 資料管線:政府開放資料 → 資料包、人物資料庫、AI 評分"
|
||
|
|
requires-python = ">=3.12"
|
||
|
|
dependencies = [
|
||
|
|
"pandas>=3.0",
|
||
|
|
"numpy>=2.0",
|
||
|
|
"httpx>=0.28",
|
||
|
|
"openpyxl>=3.1",
|
||
|
|
"odfpy>=1.4",
|
||
|
|
"shapely>=2.0",
|
||
|
|
"pyshp>=2.3",
|
||
|
|
"jsonschema>=4.23",
|
||
|
|
"pyyaml>=6.0",
|
||
|
|
"anthropic>=0.70",
|
||
|
|
]
|
||
|
|
|
||
|
|
[project.optional-dependencies]
|
||
|
|
dev = ["pytest>=8", "pytest-cov>=5", "ruff>=0.6", "black>=24"]
|
||
|
|
|
||
|
|
[project.scripts]
|
||
|
|
election-data = "election_data.cli:main"
|
||
|
|
|
||
|
|
[tool.setuptools.packages.find]
|
||
|
|
where = ["src"]
|
||
|
|
|
||
|
|
[tool.pytest.ini_options]
|
||
|
|
testpaths = ["tests"]
|
||
|
|
markers = [
|
||
|
|
"unit: 純函式測試,不連網",
|
||
|
|
"integration: 讀取實際下載的資料檔",
|
||
|
|
"network: 需要連網",
|
||
|
|
]
|
||
|
|
addopts = "-m 'not network'"
|
||
|
|
|
||
|
|
[tool.ruff]
|
||
|
|
line-length = 110
|
||
|
|
target-version = "py312"
|
||
|
|
|
||
|
|
[tool.ruff.lint]
|
||
|
|
select = ["E", "F", "I", "UP", "B", "SIM"]
|
||
|
|
|
||
|
|
[tool.black]
|
||
|
|
line-length = 110
|