# see documentation, e.g.
# - https://packaging.python.org/en/latest/specifications/declaring-project-metadata/#declaring-project-metadata
# - https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html
# - https://www.python.org/dev/peps/pep-0621/

[build-system]
requires = ["setuptools>=64.0.0", "setuptools-scm", "wheel"]
build-backend = "setuptools.build_meta"

[project]
authors = [
    { name = "Alan Nardo", email = "alan.nardo@mrc-bsu.cam.ac.uk" },
    { name = "Paul Kirk", email = "paul.kirk@mrc-bsu.cam.ac.uk" },
    { name = "Emma Prevot", email = "prevot.emma@icloud.com" },
    { name = "Rory Toogood", email = "iiauthor@gmail.com" },
    { name = "Filippo Pagani", email = "filippo.pagani@mrc-bsu.cam.ac.uk" }
]
classifiers = [
    "Development Status :: 2 - Pre-Alpha",
    "Intended Audience :: Developers",
    "Intended Audience :: Science/Research",
    "Natural Language :: English",
    "Programming Language :: Python :: 3",
    "Programming Language :: Python :: 3.10",
    "Programming Language :: Python :: 3.11",
    "Programming Language :: Python :: 3.12",
]
dependencies = [
    "asttokens==2.4.1",
    "black==24.8.0",
    "click==8.1.7",
    "colorama==0.4.6",
    "comm==0.2.2",
    "contourpy==1.2.1",
    "cycler==0.12.1",
    "debugpy==1.8.5",
    "decorator==5.1.1",
    "executing==2.0.1",
    "fonttools==4.53.1",
    "ipykernel==6.29.5",
    "ipython==8.26.0",
    "jedi==0.19.1",
    "joblib==1.4.2",
    "jupyter_client==8.6.2",
    "jupyter_core==5.7.2",
    "kiwisolver==1.4.5",
    "matplotlib==3.9.1",
    "matplotlib-inline==0.1.7",
    "mypy-extensions==1.0.0",
    "nest-asyncio==1.6.0",
    "numpy==2.0.1",
    "packaging==24.1",
    "pandas==2.2.2",
    "parso==0.8.4",
    "pathspec==0.12.1",
    "pillow==10.4.0",
    "platformdirs==4.2.2",
    "prompt_toolkit==3.0.47",
    "psutil==6.0.0",
    "pure_eval==0.2.3",
    "Pygments==2.18.0",
    "pyparsing==3.1.2",
    "python-dateutil==2.9.0.post0",
    "pytz==2024.1",
    "pywin32==306",
    "pyzmq==26.1.0",
    "scikit-learn==1.5.1",
    "scipy==1.14.0",
    "seaborn==0.13.2",
    "six==1.16.0",
    "stack-data==0.6.3",
    "threadpoolctl==3.5.0",
    "tornado==6.4.1",
    "tqdm==4.66.4",
    "traitlets==5.14.3",
    "typing==3.7.4.3",
    "typing_extensions==4.12.2",
    "tzdata==2024.1",
    "wcwidth==0.2.13"
    ]
description = "Selects variable clusters for experimental design (need to fix this later)"
keywords = ["statistics", "clustering"]
license = {file = "LICENSE"}
name = "vbvarsel"
readme = {file = "README.md", content-type = "text/markdown"}
requires-python = ">=3.8"
version = "0.1.0"

[project.optional-dependencies]
dev = [
    "build",  # build is not only used in publishing (below), but also in the template's test suite
    "bump-my-version",
    "coverage [toml]",
    "pytest",
    "pytest-cov",
    "ruff",
    "sphinx",
    "sphinx_rtd_theme",
    "sphinx-autoapi",
    "tox",
    "myst_parser",
]
docs = [
    "sphinx",
    "sphinx_rtd_theme",
    "sphinx-autoapi",
    "myst_parser",
]
publishing = [
    "build",
    "twine",
    "wheel",
]

[project.urls]
Repository = "https://github.com/MRCBSU/vbvarsel"
Issues = "https://github.com/MRCBSU/vbvarsel/issues"
Changelog = "https://github.com/MRCBSU/vbvarsel/CHANGELOG.md"
ReadTheDocs = "https://vbvarsel.readthedocs.io"

[tool.pytest.ini_options]
testpaths = ["tests"]


[tool.coverage.run]
branch = true
source = ["src/vbvarsel"]
command_line = "-m pytest"

[tool.tox]
legacy_tox_ini = """
[tox]
envlist = py38,py39,py310,py311,py312
skip_missing_interpreters = true
[testenv]
commands = pytest
extras = dev
"""

[tool.ruff]
line-length = 120
output-format = "concise"
extend-exclude = ["docs"]

[tool.ruff.lint]
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"

# Enable Pyflakes `E` and `F` codes by default.
select = ["ALL"]
ignore = [
    "ANN101", # Missing type annotation for `self` in method
    "ANN102", # Missing type annotation for `cls` in classmethod
    "ANN204", # Missing return type annotation for special (dunder) method
    "FBT",    # Using boolean function arguments
    "TD",     # TODOs
    "FIX001", # Resolve FIXMEs
    "FIX002", # Resolve TODOs
    "B028",   # No explicit `stacklevel` keyword argument found in warning
    # No docstrings required in the following cases
    "D100", # Missing module docstring
    "D104", # Missing public package docstring
    "D105", # Missing docstring in magic method
    "D107", # Missing docstring in `__init__`
]
pydocstyle.convention = "google"

[tool.ruff.lint.per-file-ignores]
# Tests can ignore a few extra rules
"tests/**.py" = [
    "ANN201", # Missing return type annotation for public function
    "PT011",  # Missing `match` parameter in `pytest.raises()`
    "S101",   # Use of assert is detected
]

[tool.ruff.lint.isort]
known-first-party = ["vbvarsel"]
force-single-line = true
no-lines-before = ["future","standard-library","third-party","first-party","local-folder"]

[tool.bumpversion]
current_version = "0.1.0"

[[tool.bumpversion.files]]
filename = "src/vbvarsel/__init__.py"

[[tool.bumpversion.files]]
filename = "pyproject.toml"

[[tool.bumpversion.files]]
filename = "CITATION.cff"

[[tool.bumpversion.files]]
filename = "docs/conf.py"
