[project]
name = "osdc"
version = "0.0.0"
description = "Open Source Dev Cloud — modular Kubernetes infrastructure platform"
requires-python = ">=3.12"
dependencies = [
  "pyyaml>=6.0",
  "requests>=2.31",
  "yamllint>=1.35",
  "lightkube==0.15.5",
  "prometheus_client>=0.21.0",
]

[dependency-groups]
dev = ["pytest>=8.0", "pytest-cov>=5.0", "pytest-xdist>=3.5"]

[tool.pytest.ini_options]
# Each testpath directory is added to sys.path, so all modules are imported
# by bare filename (no packages). Avoid generic filenames (models.py, utils.py)
# across directories — they will shadow each other. If a collision occurs,
# prefix the filename with the component name (e.g., compactor_models.py).
testpaths = [
  "scripts/python",
  "base/node-compactor/scripts/python",
  "base/kubernetes/image-cache-janitor/scripts/python",
  "base/kubernetes/node-taint-remover/lib",
  "base/kubernetes/node-taint-remover/tests",
  "modules/nodepools/scripts/python",
  "modules/arc-runners/scripts/python",
  "modules/buildkit/scripts/python",
  "modules/zombie-cleanup/scripts/python",
  "modules/harbor-cache-recovery/scripts/python",
  "integration-tests/scripts/python",
  "integration-tests/load-test/scripts/python",
  "integration-tests/workload-test/scripts/python",
  "actions/setup-pypi-cache",
]
addopts = "--tb=short -q"
filterwarnings = [
  "ignore:`verify=<str>` is deprecated:DeprecationWarning:httpx._config",
]
markers = [
  "live: requires live cluster access (kubectl/helm)",
  "aws: requires AWS CLI access",
  "offline: no cluster needed",
]

[tool.coverage.run]
omit = ["test_*.py", "conftest.py"]

[tool.coverage.report]
fail_under = 95
show_missing = true
skip_covered = true
exclude_lines = ["if __name__", "pragma: no cover"]
