Skip to content
0.2.0-dev Download ZIP
109 lines ·2.2 KB Raw
1[tool.mypy]
2disallow_any_generics = true
3explicit_package_bases = true
4ignore_missing_imports = true
5namespace_packages = true
6no_implicit_optional = true
7pretty = true
8show_column_numbers = true
9warn_redundant_casts = true
10warn_return_any = true
11warn_unreachable = true
12exclude = ["thirdparty/"]
13python_version = "3.10"
14
15[tool.ruff]
16extend-exclude = ["thirdparty"]
17extend-include = ["*SConstruct", "*SCsub"]
18target-version = "py310"
19line-length = 120
20preview = true
21fix = true
22
23[tool.ruff.lint]
24# NOTE: Starting with `0.15.2`, ruff uses a SIGNIFICANTLY expanded set of default rules for
25# preview builds. While expanding into these new rulesets is something we're interested in,
26# we'll adopt them gradually, depending on our needs. As such, our base `select` utilizes the
27# legacy defaults.
28select = ["E4", "E7", "E9", "F"]
29extend-select = [
30 "FA", # flake8-future-annotations.
31 "I", # isort.
32 "UP", # pyupgrade.
33]
34ignore = [
35 "UP015", # Unnecessary mode argument.
36]
37extend-safe-fixes = ["ALL"]
38
39[tool.ruff.lint.per-file-ignores]
40"{SConstruct,SCsub}" = [
41 "E402", # Module level import not at top of file.
42 "F403", # Undefined local with import star.
43 "F405", # Undefined local with import star usage.
44]
45
46[tool.ruff.lint.isort]
47sections = { metadata = ["misc.utility.scons_hints"] }
48section-order = [
49 "future",
50 "metadata",
51 "standard-library",
52 "third-party",
53 "first-party",
54 "local-folder",
55]
56
57[tool.codespell]
58enable-colors = true
59write-changes = true
60check-hidden = true
61quiet-level = 3
62builtin = ["clear", "rare", "en-GB_to_en-US"]
63skip = [
64 ".mailmap",
65 "*.desktop",
66 "*.gitignore",
67 "*.po",
68 "*.pot",
69 "*.rc",
70 "AUTHORS.md",
71 "COPYRIGHT.txt",
72 "core/input/gamecontrollerdb.txt",
73 "core/string/locales.h",
74 "DONORS.md",
75 "editor/import/unicode_ranges.inc",
76 "editor/project_converter_3_to_4.cpp",
77 "platform/android/java/lib/src/main/java/com/*",
78 "platform/web/package-lock.json",
79]
80ignore-words-list = [
81 "breaked",
82 "cancelled",
83 "checkin",
84 "colour",
85 "curvelinear",
86 "doubleclick",
87 "expct",
88 "findn",
89 "gird",
90 "hel",
91 "inout",
92 "labelin",
93 "lod",
94 "masia",
95 "mis",
96 "nd",
97 "numer",
98 "optin",
99 "ot",
100 "outin",
101 "parm",
102 "pEvent",
103 "requestor",
104 "streamin",
105 "te",
106 "textin",
107 "thirdparty",
108 "vai",
109]