-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathpyproject.toml
More file actions
144 lines (119 loc) · 3.28 KB
/
pyproject.toml
File metadata and controls
144 lines (119 loc) · 3.28 KB
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
[build-system]
requires = [
"hatchling",
"hatch-gradle-version>=0.9.8",
]
build-backend = "hatchling.build"
# project metadata
[project]
name = "hexdoc-hexdebug"
description = "Python web book docgen and hexdoc plugin for HexDebug."
readme = "doc/README.md"
authors = [
{ name="object-Object" },
]
keywords = ["hexdoc"]
requires-python = ">=3.12"
dynamic = ["version", "dependencies", "optional-dependencies"]
[project.urls]
Homepage = "https://hexdebug.hexxy.media"
Source = "https://github.com/object-Object/HexDebug"
# project version
[tool.hatch.version]
scheme = "gradle"
source = "gradle-properties"
py-path = "doc/src/hexdoc_hexdebug/__version__.py"
key = "modVersion"
gradle-version-regex = { regex='^(.+?)(-.+)?$', repl='\1.{minecraftVersion}\2' }
# Python dependencies
# required
[tool.hatch.metadata.hooks.version-catalog]
dependencies = [
"hexdoc>=1!0.1.0a34",
{ package="hexdoc-hexcasting", op="~=", py-version="1.0", key="hexcasting" },
{ package="hexdoc-ioticblocks", op=">=", py-version="1.0", key="ioticblocks" },
]
# dev-only
[dependency-groups]
dev = [
"ruff",
]
# directory inclusion
[tool.hatch.build]
only-include = [
"doc/src/hexdoc_hexdebug",
"gradle.properties",
]
artifacts = [
"/doc/src/hexdoc_hexdebug/_export/generated",
"/doc/src/hexdoc_hexdebug/__gradle_version__.py",
]
[tool.hatch.build.targets.wheel]
sources = ["doc/src"]
# hexdoc entry point
[project.entry-points.hexdoc]
hexdebug = "hexdoc_hexdebug._hooks:HexDebugPlugin"
# linting/formatting
[tool.ruff]
preview = true
extend-exclude = [
"**/venv",
"**/.*",
"**/__pycache__",
]
[tool.ruff.lint]
extend-select = [
"I", # import sorting
"RUF022", # __all__ sorting
"TID252", # ban relative imports
]
extend-ignore = [
# covered by Pyright
"F821", # undefined variable
"F401", # imported but unused
"F841", # unused variable
]
[tool.ruff.lint.isort]
combine-as-imports = true
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "parents"
# type checking
[tool.pyright]
pythonVersion = "3.12"
pythonPlatform = "All"
include = ["doc/src"]
extraPaths = ["doc/src"]
typeCheckingMode = "standard"
strictDictionaryInference = true
strictListInference = true
strictSetInference = true
reportConstantRedefinition = "error"
reportIncompleteStub = "error"
reportInconsistentConstructor = "error"
reportInvalidStubStatement = "error"
reportDeprecated = "warning"
reportDuplicateImport = "warning"
reportMatchNotExhaustive = "warning"
reportMissingParameterType = "warning"
reportMissingTypeArgument = "warning"
reportMissingTypeStubs = "warning"
reportPrivateUsage = "warning"
reportTypeCommentUsage = "warning"
reportUnknownArgumentType = "warning"
reportUnknownLambdaType = "warning"
reportUnknownMemberType = "warning"
reportUnknownParameterType = "warning"
reportUnknownVariableType = "warning"
reportUnnecessaryCast = "warning"
reportUnnecessaryComparison = "warning"
reportUnnecessaryContains = "warning"
reportUnnecessaryIsInstance = "warning"
reportUntypedBaseClass = "warning"
reportUntypedClassDecorator = "warning"
reportUntypedFunctionDecorator = "warning"
reportUntypedNamedTuple = "warning"
reportUnusedClass = "warning"
reportUnusedExpression = "warning"
reportUnusedFunction = "warning"
reportUnusedImport = "warning"
reportUnusedVariable = "warning"