2024-04-03 23:17:12 +00:00
|
|
|
[project]
|
2024-02-02 09:01:31 +00:00
|
|
|
name = "numpydantic"
|
2024-07-31 09:06:22 +00:00
|
|
|
version = "1.2.2"
|
2024-02-02 09:01:31 +00:00
|
|
|
description = "Type and shape validation and serialization for numpy arrays in pydantic models"
|
2024-04-03 23:17:12 +00:00
|
|
|
authors = [
|
|
|
|
{name = "sneakers-the-rat", email = "sneakers-the-rat@protonmail.com"},
|
|
|
|
]
|
|
|
|
dependencies = [
|
|
|
|
"pydantic>=2.3.0",
|
2024-04-09 01:36:47 +00:00
|
|
|
"numpy>=1.24.0",
|
2024-07-31 22:50:24 +00:00
|
|
|
"typing-extensions>=4.11.0;python_version<'3.11'"
|
2024-04-03 23:17:12 +00:00
|
|
|
]
|
2024-05-23 07:27:00 +00:00
|
|
|
homepage = "https://numpydantic.readthedocs.io"
|
2024-04-03 23:17:12 +00:00
|
|
|
requires-python = "<4.0,>=3.9"
|
2024-02-02 09:01:31 +00:00
|
|
|
readme = "README.md"
|
2024-05-23 07:27:00 +00:00
|
|
|
repository = "https://github.com/p2p-ld/numpydantic"
|
2024-04-03 23:17:12 +00:00
|
|
|
license = {text = "MIT"}
|
2024-02-02 09:01:31 +00:00
|
|
|
|
|
|
|
|
2024-04-03 23:17:12 +00:00
|
|
|
[project.optional-dependencies]
|
|
|
|
dask = [
|
2024-04-09 01:36:47 +00:00
|
|
|
"dask>=2024.4.0",
|
2024-04-03 23:17:12 +00:00
|
|
|
]
|
|
|
|
hdf5 = [
|
|
|
|
"h5py>=3.10.0"
|
|
|
|
]
|
2024-05-21 02:17:46 +00:00
|
|
|
video = [
|
|
|
|
"opencv-python>=4.9.0.80",
|
|
|
|
]
|
2024-05-21 04:16:16 +00:00
|
|
|
zarr = [
|
|
|
|
"zarr>=2.17.2",
|
|
|
|
]
|
2024-04-03 23:17:12 +00:00
|
|
|
arrays = [
|
2024-05-21 02:17:46 +00:00
|
|
|
"numpydantic[dask,hdf5,zarr,video]"
|
2024-02-02 09:01:31 +00:00
|
|
|
]
|
|
|
|
tests = [
|
2024-04-03 23:17:12 +00:00
|
|
|
"numpydantic[arrays]",
|
|
|
|
"pytest>=7.4.0",
|
|
|
|
"pytest-depends<2.0.0,>=1.0.1",
|
|
|
|
"coverage>=6.1.1",
|
|
|
|
"pytest-cov<5.0.0,>=4.1.0",
|
2024-04-23 03:23:24 +00:00
|
|
|
"coveralls<4.0.0,>=3.3.1",
|
2024-02-02 09:01:31 +00:00
|
|
|
]
|
|
|
|
docs = [
|
2024-04-03 23:17:12 +00:00
|
|
|
"sphinx<8.0.0,>=7.2.6",
|
|
|
|
"furo>=2024.1.29",
|
|
|
|
"myst-parser<3.0.0,>=2.0.0",
|
|
|
|
"autodoc-pydantic<3.0.0,>=2.0.1",
|
2024-05-22 20:25:43 +00:00
|
|
|
"sphinx-design<1.0.0,>=0.5.0",
|
|
|
|
"sphinxcontrib-mermaid>=0.9.2",
|
|
|
|
]
|
2024-02-02 09:01:31 +00:00
|
|
|
dev = [
|
2024-04-03 23:17:12 +00:00
|
|
|
"numpydantic[tests,docs]",
|
|
|
|
"sphinx-autobuild>=2021.3.14",
|
|
|
|
"black<25.0.0,>=24.1.1",
|
|
|
|
"ruff<1.0.0,>=0.2.0"
|
2024-02-02 09:01:31 +00:00
|
|
|
]
|
|
|
|
|
2024-05-21 02:17:46 +00:00
|
|
|
|
2024-04-03 23:17:12 +00:00
|
|
|
[tool.pdm]
|
|
|
|
distribution = true
|
|
|
|
|
|
|
|
[tool.pdm.build]
|
|
|
|
includes = []
|
2024-02-02 09:01:31 +00:00
|
|
|
[build-system]
|
2024-04-03 23:17:12 +00:00
|
|
|
requires = ["pdm-backend"]
|
|
|
|
build-backend = "pdm.backend"
|
2024-02-02 09:01:31 +00:00
|
|
|
|
|
|
|
[tool.pytest.ini_options]
|
|
|
|
addopts = [
|
|
|
|
"--cov=numpydantic",
|
|
|
|
"--cov-append",
|
|
|
|
]
|
|
|
|
testpaths = [
|
|
|
|
"tests"
|
|
|
|
]
|
2024-05-17 23:51:41 +00:00
|
|
|
filterwarnings = [
|
|
|
|
# nptyping's alias warnings
|
|
|
|
'ignore:.*deprecated alias.*Deprecated NumPy 1\.24.*'
|
|
|
|
]
|
2024-02-02 09:01:31 +00:00
|
|
|
|
|
|
|
[tool.ruff]
|
|
|
|
target-version = "py311"
|
2024-04-23 03:00:43 +00:00
|
|
|
include = ["src/numpydantic/**/*.py", "pyproject.toml"]
|
2024-02-03 06:45:50 +00:00
|
|
|
exclude = ["tests"]
|
2024-02-02 09:01:31 +00:00
|
|
|
|
|
|
|
[tool.ruff.lint]
|
|
|
|
select = [
|
|
|
|
# pycodestyle
|
|
|
|
"E",
|
|
|
|
# Pyflakes
|
|
|
|
"F",
|
|
|
|
# pyupgrade
|
|
|
|
"UP",
|
|
|
|
# flake8-bugbear
|
|
|
|
"B",
|
|
|
|
# flake8-simplify
|
|
|
|
"SIM",
|
|
|
|
# isort
|
|
|
|
"I",
|
|
|
|
# annotations
|
|
|
|
"ANN",
|
2024-07-31 21:15:24 +00:00
|
|
|
# perf
|
|
|
|
"PERF",
|
|
|
|
# numpy
|
|
|
|
"NPY",
|
2024-02-02 09:01:31 +00:00
|
|
|
## ----------
|
|
|
|
# pydocstyle
|
|
|
|
# undocumented public objects
|
|
|
|
"D100", "D101", "D102", "D103", "D104", "D106", "D107",
|
|
|
|
# indentation
|
|
|
|
"D207", "D208",
|
|
|
|
# whitespace
|
|
|
|
"D210", "D211",
|
|
|
|
# emptiness
|
2024-04-04 03:52:33 +00:00
|
|
|
"D419",
|
|
|
|
|
2024-02-02 09:01:31 +00:00
|
|
|
|
|
|
|
]
|
|
|
|
ignore = [
|
2024-04-09 01:36:47 +00:00
|
|
|
"ANN101", "ANN102", "ANN401", "ANN204",
|
2024-04-23 03:27:11 +00:00
|
|
|
# explicit strict arg for zip
|
|
|
|
"B905",
|
2024-04-04 03:52:33 +00:00
|
|
|
# builtin type annotations
|
|
|
|
"UP006", "UP035",
|
2024-04-09 01:36:47 +00:00
|
|
|
# | for Union types (only supported >=3.10
|
|
|
|
"UP007", "UP038",
|
2024-04-04 03:52:33 +00:00
|
|
|
# docstrings for __init__
|
|
|
|
"D107",
|
2024-02-02 09:01:31 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
fixable = ["ALL"]
|
2024-02-05 19:20:01 +00:00
|
|
|
|
|
|
|
[tool.mypy]
|
|
|
|
plugins = [
|
|
|
|
"pydantic.mypy"
|
2024-07-31 20:06:10 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
[tool.coverage.run]
|
|
|
|
omit = [
|
|
|
|
"src/numpydantic/vendor/*"
|
2024-04-03 23:17:12 +00:00
|
|
|
]
|