-
-
Notifications
You must be signed in to change notification settings - Fork 41
/
Copy pathpyproject.toml
111 lines (98 loc) · 2.73 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
[build-system]
requires = ["setuptools>=62", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "fenics-ffcx"
version = "0.10.0.dev0"
description = "The FEniCSx Form Compiler"
readme = "README.md"
requires-python = ">=3.9"
license = { file = "LICENSE" }
authors = [
{ email = "[email protected]" },
{ name = "FEniCS Steering Council" },
]
dependencies = [
"numpy>=1.21",
"cffi",
"setuptools; python_version >= '3.12'", # cffi with compilation support requires setuptools
"fenics-basix >= 0.10.0.dev0, <0.11.0",
"fenics-ufl >= 2024.3.0.dev0, <2024.4.0",
]
[project.urls]
homepage = "https://fenicsproject.org"
repository = "https://github.com/fenics/ffcx.git"
documentation = "https://docs.fenicsproject.org"
[project.scripts]
ffcx = "ffcx:__main__.main"
[project.optional-dependencies]
lint = ["ruff"]
docs = ["sphinx", "sphinx_rtd_theme"]
optional = ["numba", "pygraphviz==1.7"]
test = ["pytest >= 6.0", "sympy", "numba"]
ci = [
"coveralls",
"coverage",
"pytest-cov",
"pytest-xdist",
"types-setuptools",
"mypy",
"fenics-ffcx[docs]",
"fenics-ffcx[lint]",
"fenics-ffcx[test]",
]
[tool.setuptools]
packages = [
"ffcx",
"ffcx.codegeneration",
"ffcx.codegeneration.C",
"ffcx.ir",
"ffcx.ir.analysis",
]
[tool.pytest.ini_options]
minversion = "6.0"
addopts = "-ra"
testpaths = ["test"]
norecursedirs = ["libs", "docs"]
log_cli = true
[tool.mypy]
# Suggested at https://blog.wolt.com/engineering/2021/09/30/professional-grade-mypy-configuration/
# Goal would be to make all of the below True long-term
disallow_untyped_defs = false
disallow_any_unimported = false
no_implicit_optional = false
check_untyped_defs = false
warn_return_any = false
warn_unused_ignores = false
show_error_codes = true
[[tool.mypy.overrides]]
module = ['basix', 'cffi', 'numba.*', 'pygraphviz', 'ufl.*']
ignore_missing_imports = true
[tool.ruff]
line-length = 100
indent-width = 4
[tool.ruff.format]
docstring-code-format = true
[tool.ruff.lint]
select = [
# "N", # pep8-naming
"E", # pycodestyle
"W", # pycodestyle
"D", # pydocstyle
"F", # pyflakes
"I", # isort
"RUF", # Ruff-specific rules
"UP", # pyupgrade
"ICN", # flake8-import-conventions
"NPY", # numpy-specific rules
"FLY", # use f-string not static joins
"LOG", # https://docs.astral.sh/ruff/rules/#flake8-logging-log
# "ISC", # https://docs.astral.sh/ruff/rules/#flake8-implicit-str-concat-isc
# "B", # https://docs.astral.sh/ruff/rules/#flake8-bugbear-b
# "A", # https://docs.astral.sh/ruff/rules/#flake8-builtins-a
]
ignore = ["RUF005", "RUF012", "RUF015"]
[tool.ruff.lint.per-file-ignores]
"test/*" = ["D"]
[tool.ruff.lint.pydocstyle]
convention = "google"