| 1 |
[build-system] |
| 2 |
requires = ["poetry-core", "poetry-dynamic-versioning", "cffi", "setuptools"] |
| 3 |
build-backend = "poetry_dynamic_versioning.backend" |
| 4 |
|
| 5 |
[tool.poetry] |
| 6 |
name = "pymbd" |
| 7 |
version = "0.0.0" |
| 8 |
description = "Many-body dispersion library" |
| 9 |
authors = ["Jan Hermann <[email protected]>"] |
| 10 |
readme = "README.md" |
| 11 |
packages = [{ include = "pymbd", from = "src" }] |
| 12 |
repository = "https://github.com/libmbd/libmbd" |
| 13 |
documentation = "https://libmbd.nablapsi.science/pymbd" |
| 14 |
license = "MPL-2.0" |
| 15 |
include = [ |
| 16 |
{ path = "src/mbd.h" }, |
| 17 |
{ path = "src/pymbd/*.so", format = "wheel" }, |
| 18 |
] |
| 19 |
classifiers = [ |
| 20 |
"Development Status :: 4 - Beta", |
| 21 |
"Environment :: Console", |
| 22 |
"Intended Audience :: Science/Research", |
| 23 |
"Operating System :: MacOS :: MacOS X", |
| 24 |
"Operating System :: POSIX :: Linux", |
| 25 |
"Programming Language :: Fortran", |
| 26 |
"Topic :: Scientific/Engineering :: Chemistry", |
| 27 |
"Topic :: Scientific/Engineering :: Physics", |
| 28 |
] |
| 29 |
|
| 30 |
[tool.poetry.build] |
| 31 |
script = "cffi_build.py" |
| 32 |
generate-setup-file = false |
| 33 |
|
| 34 |
[tool.poetry.dependencies] |
| 35 |
python = "^3.10" |
| 36 |
scipy = "^1.6" |
| 37 |
numpy = ">=1.20" |
| 38 |
cffi = ">=1" |
| 39 |
pytest = { version = "*", optional = true } |
| 40 |
mpi4py = { version = "^3 || ^4", optional = true } |
| 41 |
|
| 42 |
[tool.poetry.extras] |
| 43 |
mpi = ["mpi4py"] |
| 44 |
test = ["pytest"] |
| 45 |
|
| 46 |
[tool.poetry.dev-dependencies] |
| 47 |
ruff = ">=0.10" |
| 48 |
fprettify = { git = "https://github.com/jhrmnn/fprettify.git", rev = "fix-config-search" } |
| 49 |
|
| 50 |
[tool.poetry-dynamic-versioning] |
| 51 |
enable = true |
| 52 |
dirty = true |
| 53 |
pattern = '^(?P<base>\d+\.\d+\.\d+)$' |
| 54 |
|
| 55 |
[tool.ruff] |
| 56 |
line-length = 88 |
| 57 |
target-version = "py310" |
| 58 |
|
| 59 |
[tool.ruff.lint] |
| 60 |
select = ["E", "W", "F", "N", "B", "C4", "C90", "Q", "I", "D"] |
| 61 |
ignore = [ |
| 62 |
"E501", |
| 63 |
"E741", |
| 64 |
"N802", |
| 65 |
"N803", |
| 66 |
"N806", |
| 67 |
"N812", |
| 68 |
"B905", |
| 69 |
"D100", |
| 70 |
"D104", |
| 71 |
"D105", |
| 72 |
"D107", |
| 73 |
"D202", |
| 74 |
] |
| 75 |
|
| 76 |
[tool.ruff.lint.mccabe] |
| 77 |
max-complexity = 12 |
| 78 |
|
| 79 |
[tool.ruff.lint.flake8-quotes] |
| 80 |
inline-quotes = "single" |
| 81 |
multiline-quotes = "double" |
| 82 |
docstring-quotes = "double" |
| 83 |
|
| 84 |
[tool.ruff.lint.isort] |
| 85 |
combine-as-imports = true |
| 86 |
no-lines-before = ["typing"] |
| 87 |
section-order = [ |
| 88 |
"future", |
| 89 |
"standard-library", |
| 90 |
"typing", |
| 91 |
"third-party", |
| 92 |
"first-party", |
| 93 |
"local-folder", |
| 94 |
] |
| 95 |
|
| 96 |
[tool.ruff.lint.isort.sections] |
| 97 |
typing = ["typing", "typing_extensions"] |
| 98 |
|
| 99 |
[tool.ruff.lint.pydocstyle] |
| 100 |
convention = "pep257" |
| 101 |
|
| 102 |
[tool.ruff.lint.per-file-ignores] |
| 103 |
"tests/**" = ["D"] |
| 104 |
"devtools/**" = ["D"] |
| 105 |
"doc/**" = ["D"] |
| 106 |
"cffi_build.py" = ["D"] |
| 107 |
|
| 108 |
[tool.ruff.format] |
| 109 |
quote-style = "preserve" |
| 110 |
|
| 111 |
[tool.coverage.run] |
| 112 |
branch = true |
| 113 |
source = ["pymbd"] |
| 114 |
parallel = true |
| 115 |
omit = ["*/pymbd/tensorflow.py", "*/pymbd/benchmark.py"] |
| 116 |
|
| 117 |
# Map the installed (non-editable) package back onto the source tree so the |
| 118 |
# combined report and coverage.xml use src/pymbd/... paths regardless of how |
| 119 |
# pyMBD was installed. |
| 120 |
[tool.coverage.paths] |
| 121 |
source = ["src/pymbd", "*/site-packages/pymbd", "*/pymbd"] |