-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathpyproject.toml
More file actions
166 lines (145 loc) · 4.33 KB
/
pyproject.toml
File metadata and controls
166 lines (145 loc) · 4.33 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
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
[tool.poetry]
name = "nutcracker"
version = "0.3.141591"
description = "Tools for editing resources in SCUMM games."
authors = ["BLooperZ <blooperz@users.noreply.github.com>"]
license = "GPL-3.0-or-later"
readme = "README.md"
classifiers = [
"Development Status :: 4 - Beta",
"Programming Language :: Python :: 3",
"Environment :: Console",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Intended Audience :: Developers",
"Operating System :: OS Independent",
"Topic :: Software Development :: Build Tools",
"Topic :: Games/Entertainment",
"Topic :: Utilities",
]
keywords = ["scumm", "sputm", "smush", "lucasarts", "humongous"]
repository = "https://github.com/blooperz/nutcracker"
[tool.poetry.dependencies]
python = ">=3.12"
numpy = "^2.0.0"
parse = "^1.20.1"
Pillow = "^10.2.0.20240520"
typer = "^0.12.3"
PyYAML = "^6.0.1"
deal = "^4.24.4"
[tool.poetry.scripts]
nutcracker = "nutcracker.runner:app"
smush = "nutcracker.smush.runner:app"
[tool.poetry.group.dev.dependencies]
mypy = "^1.10.0"
ruff = "^0.4.9"
pytest = "^8.1.1"
pyinstaller = { version = "^6.13.0", python = "<3.14" }
pip-licenses = "^5.0.0"
types-pillow = "^10.2.0.20240520"
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.mypy]
strict = true
plugins = ['numpy.typing.mypy_plugin']
[tool.ruff] # https://beta.ruff.rs/docs/settings/
target-version = "py310"
line-length = 88
fix = false
src = ["src", "tests"]
[tool.ruff.lint]
select = [ # https://beta.ruff.rs/docs/rules/
"BLE", # flake8-blind-except
"FBT", # flake8-boolean-trap
"A", # flake8-builtins
"COM", # flake8-commas
"DTZ", # flake8-datetimez
"T10", # flake8-debugger
# "DJ", # flake8-django
# "EM", # flake8-errmsg
"EXE", # flake8-executable
"ISC", # flake8-implicit-str-concat
"ICN", # flake8-import-conventions
"G", # flake8-logging-format
"INP", # flake8-no-pep420
"PIE", # flake8-pie
"T20", # flake8-print
"PYI", # flake8-pyi
"RSE", # flake8-raise
"RET", # flake8-return
"SLF", # flake8-self
"ARG", # flake8-unused-arguments
"PTH", # flake8-use-pathlib
"ERA", # eradicate
# "PD", # pandas-vet
"PGH", # pygrep-hooks
"PL", # Pylint
"PLC", # Convention
"PLE", # Error
"PLR", # Refactor
"PLW", # Warning
"TRY", # tryceratops
"NPY", # NumPy-specific rules
"ANN", # flake8-annotations
"YTT", # flake8-2020
"C90", # mccabe
"E", # pycodestyle
"W", # pycodestyle
"F", # Pyflakes
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"D", # pydocstyle
"I", # isort
"N", # pep8-naming
"S", # flake8-bandit
"SIM", # flake8-simplify
"TCH", # flake8-type-checking
"TID", # flake8-tidy-imports
"Q", # flake8-quotes
"UP", # pyupgrade
"PT", # flake8-pytest-style
"RUF", # Ruff-specific rules
]
fixable = ["I", "COM"]
unfixable = ["ERA001", "F401", "F841", "T201", "T203"]
ignore = [
"RET504", # Allow assigning before return to ease debugging
"S101", # Allow using assert
"UP015", # Prefer explicitly configuring open mode
"ANN101", "ANN102", # Do not require annotating self and cls
"PTH103", # `os.mkdirs` is more readable
"D107", # No need to docstring `__init__` method
"D202", # No blank lines allowed after function docstring -> clashes with Black
"ARG001", "ARG002", # Unused arguments are generally used for API compatibility
"D", # TODO: Add docstrings
"COM812", "ISC001", # conflicts with formatter
"BLE001", # Expecting `Exception` is totally fine
]
[tool.ruff.lint.pycodestyle]
max-doc-length = 88
[tool.ruff.lint.flake8-annotations]
allow-star-arg-any = true
[tool.ruff.lint.flake8-bugbear]
# Allow default arguments like, e.g., `data: List[str] = fastapi.Query(None)`.
extend-immutable-calls = ["typer.Option", "typer.Argument"]
[tool.ruff.lint.flake8-boolean-trap]
extend-allowed-calls = ["typer.Option"]
[tool.ruff.lint.flake8-tidy-imports]
ban-relative-imports = "parents"
[tool.ruff.lint.flake8-type-checking]
strict = true
[tool.ruff.lint.flake8-unused-arguments]
ignore-variadic-names = true
[tool.ruff.lint.flake8-quotes]
docstring-quotes = "double"
inline-quotes = "single"
multiline-quotes = "double"
[tool.ruff.lint.pydocstyle]
# Use Google-style docstrings.
convention = "google"
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["D104"]
"tests/**/*.py" = ["D100"]
[tool.ruff.format]
# Prefer single quotes over double quotes.
quote-style = "single"