-
Notifications
You must be signed in to change notification settings - Fork 16
/
pyproject.toml
144 lines (131 loc) · 3.98 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
[project]
name = "pymatviz"
version = "0.11.0"
description = "A toolkit for visualizations in materials informatics"
authors = [{ name = "Janosh Riebesell", email = "janosh.riebesell@gmail.com" }]
readme = "readme.md"
license = { file = "license" }
keywords = [
"chemistry",
"data visualization",
"materials discovery",
"materials informatics",
"matplotlib",
"plotly",
"science",
]
classifiers = [
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
]
urls = { Homepage = "https://github.com/janosh/pymatviz" }
requires-python = ">=3.10"
dependencies = [
"matplotlib>=3.9",
"numpy>=1.26",
# output-formatting needed for pandas Stylers, see https://github.com/pandas-dev/pandas/blob/-/pyproject.toml
"pandas[output-formatting]>=2.2",
"plotly>=5.23",
"pymatgen>=2024.7.18",
"scikit-learn>=1.5",
"scipy>=1.14",
]
[project.optional-dependencies]
test = [
"adjustText>=0.8",
"bs4>=0.0.2",
"cssutils>=2.9",
"kaleido>=0.2",
"lxml>=4.9",
"pdfCropMargins>=2",
"pytest-cov>=5",
"pytest>=8",
"weasyprint>=60",
]
make-assets = ["kaleido>=0.2", "matminer>=0.9", "mp_api>=0.42"]
export-figs = ["kaleido>=0.2"]
gh-pages = ["jupyter>=1.1", "lazydocs>=0.4", "nbconvert>=7.16"]
df-pdf-export = ["pdfCropMargins>=2", "weasyprint>=60"]
df-svg-export = ["bs4>=0.0.2", "cssutils>=2.9", "lxml>=4.9"]
auto-text-pos = ["adjustText>=0.8"]
[tool.setuptools.packages]
find = { include = ["pymatviz*"], exclude = ["tests*"] }
[tool.setuptools.package-data]
pymatviz = ["*.csv"]
[tool.distutils.bdist_wheel]
universal = true
[build-system]
requires = ["setuptools>=71"]
build-backend = "setuptools.build_meta"
[tool.pytest.ini_options]
testpaths = ["tests"]
addopts = "-p no:warnings"
[tool.mypy]
check_untyped_defs = true
disallow_any_generics = true
disallow_incomplete_defs = true
disallow_untyped_defs = true
warn_redundant_casts = true
warn_unused_ignores = true
show_error_codes = true
no_implicit_optional = false
[tool.ruff]
target-version = "py310"
output-format = "concise"
[tool.ruff.lint]
select = ["ALL"]
ignore = [
"ANN401", # Any-type
"C408", # unnecessary-collection-call
"C901", # complex-structure
"COM812", # trailing comma missing
"D205", # 1 blank line required between summary line and description
"E731", # do not assign a lambda expression, use a def
"EM101", # raw-string-in-exception
"EM102", # f-string-in-exception
"ERA001", # dead code
"FIX002", # line-contains-todo
"PLR0911", # too-many-return-statements
"PLR0912", # too-many-branches
"PLR0913", # function-with-too-many-arguments
"PLR0915", # too-many-statements
"PLR2004", # magic-number-comparison
"PTH", # prefer pathlib over os.path
"SIM105", # Use contextlib.suppress instead of try-except-pass
"SLF001", # Access private class members
"TD", # TODO related
"TRY003", # raise-vanilla-args
]
pydocstyle.convention = "google"
isort.lines-after-imports = 2
isort.split-on-trailing-comma = false
[tool.ruff.format]
docstring-code-format = true
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401"] # unused-import
"tests/*" = [
"D", # pydocstyle
"FBT001", # boolean-type-hint-positional-argument
"FBT002", # boolean-default-value-positional-argument
"INP001", # implicit-namespace-package
"PLR2004", # magic-value-comparison
"S101", # use of assert
]
"examples/*" = [
"D100", # missing docstring in public module
"INP001", # implicit-namespace-package
"T201", # print found
]
"site/*" = [
"D", # pydocstyle
"INP001", # implicit-namespace-package
"S602", # subprocess-popen-with-shell-equals-true
]
[tool.pyright]
typeCheckingMode = "off"
reportPossiblyUnboundVariable = true
reportUnboundVariable = true