ci(qodana): zero-problem quality gate, exclusions with their reasons
Each qodana.yaml now fails its job on any problem (failureConditions, any: 0), as in free-games-itchio-list, and names what it leaves out and why: - Python: DuplicatedCode in the two discovery and two leaderboard scripts (sharing them is a refactor); broad excepts where a failed request is "no answer" by design (steam_client, the Access diagnosis); PyCharm's sorted() typing in edit_game.py; the escaped bracket pair in normalize.py's `\[hover-add\]`. - JS/TS: ES6UnusedImports (the Svelte plugin cannot resolve `@lucide/svelte/icons/*` and calls all 122 icon imports unused; every tsconfig has noUnusedLocals, enforced by svelte-check and tsc), the admin's relative imports of the public app, `}` escapes kept for unicode-mode parsing, fetcher.ts's throw-to-own-catch fallback, and keyCode 229 for IME composition. - Rust: CargoUnusedDependency, which cannot see the ::serde_json paths generate_context!() expands to. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
11c38dba24
commit
55fcf1342a
3 files changed
+75
No files matched your search
@@ -14,6 +14,10 @@ linter: qodana-python
|
||||
withinDocker: false
|
||||
profile:
|
||||
name: qodana.recommended
|
||||
# The quality gate: any problem fails the job.
|
||||
failureConditions:
|
||||
severityThresholds:
|
||||
any: 0
|
||||
exclude:
|
||||
- name: All
|
||||
paths:
|
||||
@@ -23,3 +27,32 @@ exclude:
|
||||
- dead_games.log
|
||||
# The byte-exact blocklist golden file the tests compare against.
|
||||
- tests/fixtures
|
||||
# The two discovery scripts and the two leaderboard scripts each stand
|
||||
# alone and repeat a few lines of their sibling (argument and environment
|
||||
# handling; the tier, trend and star helpers). Sharing them would be a
|
||||
# refactor, which maintenance mode does not take (CLAUDE.md).
|
||||
- name: DuplicatedCode
|
||||
paths:
|
||||
- backfill_discover.py
|
||||
- discover_new.py
|
||||
- top_offline.py
|
||||
- top_online.py
|
||||
# A request that fails in any way is "no answer" there, by design: the
|
||||
# caller retries, skips or reports it, and a job of hours never dies on an
|
||||
# exception nobody listed (core/steam_client.py). The Access diagnosis in
|
||||
# discover_new.py is best effort on top of an error already being raised.
|
||||
- name: PyBroadExceptionInspection
|
||||
paths:
|
||||
- core/steam_client.py
|
||||
- discover_new.py
|
||||
# PyCharm types sorted(MANUAL_FIELDS), a frozenset of str, as its
|
||||
# comparison protocol instead of str, and then refuses `{f:<16}`.
|
||||
- name: PyStringFormatInspection
|
||||
paths:
|
||||
- edit_game.py
|
||||
# `\[hover-add\]` keeps both brackets escaped: the pattern removes that
|
||||
# literal text, and the pair reads as one. The rules in this file must stay
|
||||
# byte-stable (CLAUDE.md, save_main()).
|
||||
- name: RegExpRedundantEscape
|
||||
paths:
|
||||
- core/normalize.py
|
||||
@@ -11,6 +11,10 @@ plugins:
|
||||
- id: dev.blachut.svelte.lang
|
||||
profile:
|
||||
name: qodana.recommended
|
||||
# The quality gate: any problem fails the job.
|
||||
failureConditions:
|
||||
severityThresholds:
|
||||
any: 0
|
||||
exclude:
|
||||
- name: All
|
||||
paths:
|
||||
@@ -26,3 +30,31 @@ exclude:
|
||||
- .svelte-kit
|
||||
- worker/generated
|
||||
- worker-configuration.d.ts
|
||||
# Every icon is imported from `@lucide/svelte/icons/<name>` and used as a
|
||||
# component in the markup. The Svelte plugin does not resolve that subpath
|
||||
# export, so it calls every one of them unused. An unused import is an
|
||||
# error in all six tsconfigs already (`noUnusedLocals`), which svelte-check
|
||||
# and tsc enforce in Web CI.
|
||||
- name: ES6UnusedImports
|
||||
# The admin SPA reaches into the public app by relative path
|
||||
# (../../src/lib/...), as admin/tsconfig.json describes; `#lib` is the
|
||||
# SvelteKit app's mapping (tsconfig.json `paths`), which the admin's
|
||||
# tsconfig does not have.
|
||||
- name: ES6PreferShortImport
|
||||
paths:
|
||||
- admin
|
||||
# The escapes of } stay: without them a pattern only parses in non-unicode
|
||||
# (Annex B) mode.
|
||||
- name: RegExpRedundantEscape
|
||||
# fetchShard() and fetchRemovedText() throw PackUnavailableError to their
|
||||
# own catch on purpose: that catch is the one place that falls back from
|
||||
# the packed path to the plain one.
|
||||
- name: ExceptionCaughtLocallyJS
|
||||
paths:
|
||||
- src/lib/fetcher.ts
|
||||
# `keyCode === 229` is how a key that belongs to an IME composition
|
||||
# (Telex, VNI) shows in browsers that report isComposing false for it.
|
||||
- name: JSDeprecatedSymbols
|
||||
paths:
|
||||
- src/lib/common/CommandPalette.svelte
|
||||
- src/lib/palette.svelte.ts
|
||||
@@ -5,6 +5,10 @@ version: "1.0"
|
||||
linter: qodana-rust
|
||||
profile:
|
||||
name: qodana.recommended
|
||||
# The quality gate: any problem fails the job.
|
||||
failureConditions:
|
||||
severityThresholds:
|
||||
any: 0
|
||||
# The linter evaluates build scripts and expands macros with `cargo check`,
|
||||
# and its image has neither a C linker nor the libraries Tauri links against.
|
||||
# Needs root in the container (the workflow passes `-u root`).
|
||||
@@ -18,3 +22,9 @@ exclude:
|
||||
# generates (Kotlin and Gradle, not Rust).
|
||||
- target
|
||||
- gen
|
||||
# serde_json is used by the code tauri::generate_context!() expands
|
||||
# (::serde_json::Value for the plugins' configuration), which this
|
||||
# inspection does not see: without it the crate does not compile.
|
||||
- name: CargoUnusedDependency
|
||||
paths:
|
||||
- Cargo.toml
|
||||
Reference in new issue
Block a user