-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
119 lines (103 loc) · 2.74 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
[build-system]
requires = ["setuptools>=68", "setuptools_scm[toml]>=8"]
build-backend = "setuptools.build_meta"
[project]
name = "rosalind"
authors = [
{name = "Alyss Flynn", email = "[email protected]"},
]
description = "Package with some basic genetics functions."
readme = "README.rst"
requires-python = ">=3.8"
dynamic = ["version"]
dependencies = [
# Add runtime dependencies here
]
# Enables the usage of setuptools_scm
[tool.setuptools_scm]
[project.optional-dependencies]
lint = [
"mypy",
"ruff",
]
test = [
"pytest==7.4.1",
"pytest-cov==4.1.0",
"coverage[toml]==7.3.1",
]
doc = [
"sphinx",
]
build = [
"build[virtualenv]==1.0.3",
]
dev = [
"tox",
"rosalind[lint]",
"rosalind[test]",
"rosalind[doc]",
"rosalind[build]",
]
[tool.ruff]
line-length = 120
src = ["src"]
extend-exclude = [
"conf.py",
"build/",
"tests/",
]
target-version = "py39"
[tool.ruff.lint]
select = ["ALL"]
ignore = [
"COM812", # Conflicts with the formatter
"ISC001", # Conflicts with the formatter
"ANN101", # "missing-type-self"
"PT001", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
"PT004", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
"PT005", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
"PT023", # https://github.com/astral-sh/ruff/issues/8796#issuecomment-1825907715
]
[tool.ruff.lint.per-file-ignores]
"tests/**" = [
"S101", # Use of `assert` detected
"D103", # Missing docstring in public function
"D100", # Missing docstring in public function
"INP001", # Require __init__.py
"ANN201", # Missing return types
]
"**/__init__.py" = [
"F401", # Imported but unused
"F403", # Wildcard imports
"D104", # Missing docstring in public function
]
"docs/**" = [
"INP001", # Requires __init__.py but docs folder is not a package.
]
[tool.ruff.lint.pyupgrade]
# Preserve types, even if a file imports `from __future__ import annotations`(https://github.com/astral-sh/ruff/issues/5434)
keep-runtime-typing = true
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.mypy]
disallow_untyped_defs = false # Functions need to be annotated
warn_unused_ignores = true
ignore_missing_imports = true
exclude = [
"rosalind-\\d+", # Ignore temporary folder created by setuptools when building an sdist
"venv.*/",
"build/",
"dist/",
]
[tool.pytest.ini_options]
addopts = """
--import-mode=append
--cov=rosalind
--cov-config=pyproject.toml
--cov-report=
"""
[tool.coverage.paths]
# Maps coverage measured in site-packages to source files in src
source = ["src/", ".tox/*/lib/python*/site-packages/"]
[tool.coverage.html]
directory = "reports/coverage_html"