Repository navigation
chore(quality): the local SonarQube and IDE findings of 2026-11-29, no behaviour change - #90
Merged
Merged
Conversation
…o behaviour change A local SonarQube and IDE inspection round over this release's code, before 4.12.31: 432 analyzer rows in 16 files, 398 fixed and 34 kept with their reason on the line. In lockstep with the Node pack. Cognitive complexity (32 rows): each function over 15 is split along its seams, every check in the order it ran and with the message it raised - 14 in the agent tools (the listing, the search, the page ranges, the HTML reader's start tag, the address resolution, a fetch, the crawl, the database's errors, the value renderer, a node's properties, the ingest plan, the schema, the boot, describe's states), 8 in rest_automation.py, 4 in rest_routing.py, 3 in agent-question, 2 in ask-person, and the attachments loader of the LLM helper. Literals and expressions: a literal repeated three times or more is a constant; the two identifier expressions of the graph tools use \w under re.ASCII, which keeps them to the characters the class spelled out; the Cypher pattern over the regex limit is built from three named parts with the same pattern and flags; a "# noqa" carries its code alone, the reason on the line above; a list() copy stays only where the loop changes the size of what it walks. Tests (332 rows): every composite assertion is split into single ones, a pytest.raises block holds the one call that must raise, and a module global is patched through monkeypatch. PyCharm's own findings are taken where a local beside the existing guard, a @staticmethod or a rename settles them. Kept, each with "# NOSONAR - <reason>" on its line: 32 methods that are async because their interface is (the in-memory stores beside their PostgreSQL and Redis siblings, a callback the host awaits), the copy in the memory store's unaudited(), and one false positive on dataclasses.replace. ruff and basedpyright clean; pytest 921 passed, 76 skipped, as before. The IDE's own analyzer, run headless, reproduces the 432 rows on the files as they were and reports none on the scanned sources now outside the 34 marked lines; none of the scan's four test rules is left in the tests. CHANGELOG Unreleased Changed 11. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
acn-ericlaw
added a commit
that referenced
this pull request
Nov 30, 2026
…90) and the defect round (#91), both merged; a kept finding says why on its line; the round's defects thread closed Two session logs: the round with no behaviour change (432 analyzer rows, 398 fixed and 34 kept with their reason) and the round that fixed what it had written down, in lockstep with the Node pack - one address table and one glob grammar for the agent tools with a matcher bounded in time, one rule for a number in the LLM helper, one for a ticket and for a row id, rest.yaml flags as the Java engine reads them, the engines' error body at the edge. Continuity: the rule for a kept finding and for re-scanning a round with the IDE's own analyzer, the maintainer's ruling of 2026-11-29. The thread that held the first round's findings is closed with #91. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The findings of a local SonarQube and IDE inspection round (2026-11-29) on this release's code, with no behaviour change: 432 analyzer rows in 16 files, 398 fixed and 34 kept with their reason on the line. The twin of the Node pack's round.
rest_automation.py, 4 inrest_routing.py, 3 in agent-question, 2 in ask-person, and the attachments loader of the LLM helper.\wunderre.ASCII. The Cypher pattern over the regex limit is built from three named parts with the same pattern and flags. A# noqacarries its code alone, the reason on the line above. Alist()copy stays only where the loop changes the size of what it walks.pytest.raisesblock holds the one call that must raise, and a module global is patched throughmonkeypatch.@staticmethodor a rename settles them.# NOSONAR - <reason>on its line (34 rows). 32 methods that areasyncbecause their interface is (the in-memory stores beside their PostgreSQL and Redis siblings, a callback the host awaits), the copy in the memory store'sunaudited(), and one false positive ondataclasses.replace.Why
The code quality sprint before release 4.12.31. The files are the ones this release added or changed, so a finding left in them ships as new code.
A finding kept on purpose now says why on its line, the maintainer's ruling in this round, so the next scan shows only what is new.
For the reviewer
\wneedsre.ASCII. Without the flag it matches about 143,000 characters where the class had 63. With it the verdict is the same on every code point.Upgrade note
None.
Verification
ruff check .clean,basedpyright0 errors and 0 warnings,pytest921 passed and 76 skipped, the totals before the change.basedpyright --pythonversion 3.11reports 0 errors and ruff'spy311target is clean, each after a control file with 3.12 syntax and library calls was flagged. This pull request's 3.11 job is the first run on the floor.sonar-pythonjar of the PyCharm plugin), run headless with the 407 checks of its default profile, reproduces the 432 rows on the files as they were and reports none on the nine source files now outside the 34 marked lines. None of the scan's four test rules is left in the test files.Beside this pull request
mercury-nodejs, on a branch of the same name.Co-Authored-By: Claude Fable 5.2 noreply@anthropic.com
🤖 Generated with Claude Code