Skip to content

Commit

Permalink
Issue #560 Remove setup.cfg (#707)
Browse files Browse the repository at this point in the history
In this commit all the contents of setup.cfg has been moved to the
pyproject.toml file.
Flake8 doesn't support the pyproject.toml format, therefor it has been
relaced with ruff.
  • Loading branch information
Manangka authored Dec 22, 2023
1 parent 8bcc19f commit 9e8789b
Show file tree
Hide file tree
Showing 4 changed files with 126 additions and 99 deletions.
2 changes: 1 addition & 1 deletion docs/developing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -233,4 +233,4 @@ At this point, everything should be ready to run the tests on the Docker image.
.. _embedded: https://sphinx-gallery.github.io/stable/syntax.html#embedding-rst
.. _IPython Sphinx Directives: https://ipython.readthedocs.io/en/stable/sphinxext.html
.. _isort: https://github.com/PyCQA/isort
.. _flake8: https://github.com/PyCQA/flake8
.. _ruff: https://github.com/astral-sh/ruff
2 changes: 1 addition & 1 deletion imod-environment-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ channels:

dependencies:
- black
- flake8
- ruff
- hypothesis
- isort
- mypy
Expand Down
125 changes: 124 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,136 @@
requires = ["setuptools>=42", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "imod"
version = "0.15.0"
requires-python = ">=3.10"
authors = [
{ name = "Deltares", email = "[email protected]" },
]
maintainers = [
{ name = "Deltares", email = "[email protected]" }
]
description = "Make massive MODFLOW models!"
readme = "README.rst"
license = { file = "LICENSE" }
keywords = ["imod", "modflow", "groundwater modeling"]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Science/Research",
"Topic :: Scientific/Engineering :: Hydrology",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: Implementation :: CPython",
"opic :: Scientific/Engineering"
]
dependencies = [
"affine",
"cftime >=1",
"dask",
"fastcore",
"Jinja2",
"matplotlib",
"numba",
"numpy",
"pandas",
"pooch",
"scipy",
"tomli_w",
"toolz",
"tqdm",
"xarray >=0.15",
"xugrid >=0.3.0",
]

[project.urls]
Homepage = "https://github.com/Deltares/imod-python"
Documentation = "https://deltares.github.io/imod-python/"
Repository = "https://github.com/Deltares/imod-python.git"
"Bug Tracker" = "https://github.com/Deltares/imod-python/issues"
Changelog = "https://github.com/Deltares/imod-python/blob/master/docs/api/changelog.rst"

[project.optional-dependencies]
all = [
"bottleneck",
"contextily >=1",
"cytoolz",
"geopandas",
"pyvista",
"rasterio >=1",
"rioxarray",
"shapely >=1.8",
"tomli >= 1.1.0 ; python_version < '3.11'",
"zarr",
]
dev = [
"imod[all]",
"black",
"ruff",
"flopy",
"hypothesis",
"mypy",
"pydata-sphinx-theme",
"pytest",
"pytest-cov",
"pytest-benchmark",
"sphinx",
"sphinx-gallery",
]

[tool.isort]
profile = "black"

[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"pragma: no cover",
]

[tool.ruff.lint]
select = ["C4", "E", "F", "I"]
ignore = [
"C401",
"C402",
"C403",
"C404",
"C408",
"C416",
"C417",
"C419",
"D202",
"D205",
"D206",
"D400",
"D404",
"C405",
"E402",
"E501",
"E703",
"E713",
"E721",
"E731",
"E741",
"F811",
"PD002",
"PD901",
"PD003",
"PD004",
]
fixable = ["I"]
ignore-init-module-imports = true

[tool.ruff.lint.pydocstyle]
convention = "numpy"

[tool.ruff.lint.per-file-ignores]
"./docs/conf.py" = ["F401"]
"__init__.py" = ["F401"]
"conftest.py" = ["F401"]
"test_examples.py" = ["F401"]

[tool.mypy]
files = "imod/mf6/**.py"
Expand Down
96 changes: 0 additions & 96 deletions setup.cfg

This file was deleted.

0 comments on commit 9e8789b

Please sign in to comment.