-
Notifications
You must be signed in to change notification settings - Fork 21
/
pyproject.toml
174 lines (161 loc) · 4.6 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
[project]
name = "pyEQL"
readme = "README.md"
dynamic = ["version"]
description="A python interface for solution chemistry"
authors =[
{name = "Ryan Kingsbury", email = "[email protected]"}
]
classifiers=[
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Development Status :: 4 - Beta",
"Intended Audience :: Science/Research",
"Operating System :: OS Independent",
"Topic :: Scientific/Engineering",
]
license = {file = "LICENSE"}
requires-python = ">=3.10"
dependencies = [
"pint>=0.19",
"numpy>1.26,<2",
"scipy>=1.12",
"pymatgen>=2024.9.10",
"iapws>=1.5.3",
"monty>=2024.7.12",
"maggma>=0.67.0",
"phreeqpython>=1.5.2",
]
[project.urls]
Docs = "https://pyeql.readthedocs.io/"
Repo = "https://github.com/KingsburyLab/pyEQL"
Package = "https://pypi.org/project/pyEQL"
[project.optional-dependencies]
testing = [
"setuptools>=68",
"pre-commit>=2",
"pytest>=7",
"pytest-cov>=2.11",
"pytest-xdist>2",
"black",
"mypy>1",
"ruff>0.0.100",
"tox<4",
]
docs = [
"sphinx>=3.2.1",
"sphinx-rtd-theme",
"myst-parser[linkify]",
]
full = ["rich"]
[build-system]
# AVOID CHANGING REQUIRES: IT WILL BE UPDATED BY PYSCAFFOLD!
requires = ["setuptools>=46.1.0", "setuptools_scm[toml]>=5"]
build-backend = "setuptools.build_meta"
[tool.setuptools.packages.find]
where = ["src"]
exclude = ["tests"]
[tool.setuptools_scm]
# See configuration details in https://github.com/pypa/setuptools_scm
version_scheme = "no-guess-dev"
[tool.black]
line-length = 120
[tool.ruff]
line-length = 120
exclude = [".dat"]
src = ["src"]
[tool.ruff.lint]
select = [
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"D", # pydocstyle
"E", # pycodestyle error
"EXE", # flake8-executable
"F", # pyflakes
"FA", # flake8-future-annotations
"FLY", # flynt
"I", # isort
"ICN", # flake8-import-conventions
"ISC", # flake8-implicit-str-concat
"PD", # pandas-vet
"PERF", # perflint
"PIE", # flake8-pie
"PL", # pylint
"PT", # flake8-pytest-style
"PYI", # flakes8-pyi
"Q", # flake8-quotes
"RET", # flake8-return
"RSE", # flake8-raise
"RUF", # Ruff-specific rules
"SIM", # flake8-simplify
"SLOT", # flake8-slots
"TCH", # flake8-type-checking
"TID", # tidy imports
"TID", # flake8-tidy-imports
"UP", # pyupgrade
"W", # pycodestyle warning
"YTT", # flake8-2020
"NPY201", # Numpy 2.0 migration
]
ignore = [
"B008", # Do not perform function call `unit` in argument defaults
"B023", # Function definition does not bind loop variable
"B028", # No explicit stacklevel keyword argument found
"B904", # Within an except clause, raise exceptions with ...
"C408", # unnecessary-collection-call
"D105", # Missing docstring in magic method
"D205", # 1 blank line required between summary line and description
"D212", # Multi-line docstring summary should start at the first line
"FA100", # Missing `from __future__ import annotations`, but uses `typing.XXX` TODO
"PD011", # pandas-use-of-dot-values
"PD901", # pandas-df-variable-name
"PERF203", # try-except-in-loop
"PLR", # pylint refactor
"PLW2901", # Outer for loop variable overwritten by inner assignment target
"PT013", # pytest-incorrect-pytest-import
"RUF012", # Disable checks for mutable class args. This is a non-problem.
"SIM105", # Use contextlib.suppress(OSError) instead of try-except-pass
]
pydocstyle.convention = "google"
isort.split-on-trailing-comma = false
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401"]
"tests/*" = ["D", "E501"] # TODO - remove E501
[tool.pytest.ini_options]
minversion = "6.0"
addopts = [
"-ra",
"--showlocals",
"--strict-markers",
"--strict-config",
"--color=yes",
"--import-mode=importlib",
"--durations=30",
"--verbose",
]
norecursedirs = [
"dist",
"build",
".tox",
]
xfail_strict = true
filterwarnings = ["error", "ignore::UserWarning", "ignore::DeprecationWarning"]
log_cli_level = "warning"
testpaths = [
"tests",
]
[tool.mypy]
ignore_missing_imports = true
namespace_packages = true
explicit_package_bases = true
no_implicit_optional = false
strict = true
hide_error_codes = true
enable_error_code = ["ignore-without-code", "redundant-expr", "truthy-bool"]
warn_unreachable = true
[tool.codespell]
ignore-words-list = "nd,formate"
skip = "tests/test_files/*,src/pyEQL/database/*"