Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Team Run ID: 📒 Files selected for processing (9)
🔗 Linked repositories identifiedCodeRabbit considers these linked repositories for cross-repo context during reviews:
Included review availability: 0 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour. SummaryAdd a pinned
Validation passed for formatting, linting, documentation coverage, tests, workflow contracts, Markdown linting, and Nixie. Track the implementation against issue WalkthroughThe Python lint pipeline now includes pinned Interrogate coverage at 100%. The change adds explicit exclusions, documents the policy, adds required docstrings, and verifies the pin and command through workflow-contract tests. ChangesInterrogate documentation coverage
Suggested labels: Priority: ⬇️ Low Change: Feature Merge Risk: ⚪ Minimal · up to No actionable merge-blocking risk remains in the reviewed change. Caution Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional.
❌ Failed checks (2 errors)
✅ Passed checks (13 passed)
Full details: Testing (Overall)Explanation Reject the testing coverage for the new gate. The added contract tests check that Resolution Add a focused Makefile contract test that parses the Interrogate definition and asserts the pinned Full details: Testing (Unit And Behavioural)Explanation The pull request changes the externally observable Resolution Add a workflow-contract behavioural test that invokes A pinned gate now guards the code Comment |
Reviewer's GuideIntroduces a pinned Interrogate 1.7.0 quality gate requiring 100% docstring coverage for repository-owned Python sources, with explicit spelling-helper exclusions, documentation, workflow contract enforcement, and the missing docstrings needed to pass the gate. Flow diagram for the Interrogate Python lint gateflowchart LR
Sources[PYTHON_SOURCES] --> Exclusions[INTERROGATE_EXCLUDES]
Exclusions --> Interrogate[interrogate==1.7.0]
Interrogate --> Coverage{100% coverage?}
Coverage -->|pass| LintPython[make lint-python passes]
Coverage -->|fail| LintPythonFail[make lint-python fails]
File-Level Changes
Assessment against linked issues
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
751c8ce to
e58a1f3
Compare
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e58a1f326e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@coderabbitai Please investigate the cause of the following issue using codegraph exploration and research, identify a fix and provide an AI coding agent prompt for the fix: Seek a systemic fix rather than tactical. Ask yourself, can this happen again or happen elsewhere? If so, think about a long term fix of the underlying issue. |
This comment was marked as resolved.
This comment was marked as resolved.
|
@coderabbitai Have the following failed checks now been resolved? If further work is required, please provide an AI agent prompt for the remaining work to be done to address these failures. Do not treat warnings as optional or aspirational. Where a change is out of scope for this PR, propose a GitHub issue unless one exists already. (Treat o11y, code safety, documentation and validation coverage as in scope). ❌ Failed checks (2 errors)
|
|
Tip For best results, initiate chat on the files or code changes. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '%s\n' '== PR metadata and checks =='
gh pr view 680 --repo leynos/netsuke --json headRefOid,updatedAt,statusCheckRollup,files --jq \
'{headRefOid, updatedAt, files: [.files[].path], checks: [.statusCheckRollup[] | {name, conclusion, status, detailsUrl}]}'
printf '%s\n' '== Changed-file diff summary =='
git diff --stat origin/HEAD...HEAD 2>/dev/null || git diff --stat HEAD^...HEAD
printf '%s\n' '== Makefile Interrogate definitions and lint-python recipe =='
rg -n -C 8 'INTERROGATE|^lint-python:' Makefile
printf '%s\n' '== Workflow contract test outlines =='
ast-grep outline tests/workflow_contracts/python_toolchain_sync_test.py --items all
ast-grep outline tests/workflow_contracts/runner_shape_test.py --items all 2>/dev/null || true
printf '%s\n' '== Relevant contract-test implementation =='
sed -n '1,320p' tests/workflow_contracts/python_toolchain_sync_test.py
sed -n '1,360p' tests/workflow_contracts/runner_shape_test.py 2>/dev/null || true
printf '%s\n' '== Relevant branch diff =='
git diff origin/HEAD...HEAD -- Makefile tests/workflow_contracts/python_toolchain_sync_test.py tests/workflow_contracts/runner_shape_test.py 2>/dev/null \
|| git diff HEAD^...HEAD -- Makefile tests/workflow_contracts/python_toolchain_sync_test.py tests/workflow_contracts/runner_shape_test.pyLength of output: 6346 🏁 Script executed: #!/bin/bash
set -u
printf '%s\n' '== Makefile Interrogate definitions and lint-python recipe =='
rg -n -C 10 'INTERROGATE|^lint-python:' Makefile || true
printf '%s\n' '== Workflow-contract inventory =='
fd -t f . tests/workflow_contracts | sort
printf '%s\n' '== Contract test outlines =='
ast-grep outline tests/workflow_contracts/python_toolchain_sync_test.py --items all || true
ast-grep outline tests/workflow_contracts/runner_shape_test.py --items all || true
printf '%s\n' '== Python toolchain contract implementation =='
cat -n tests/workflow_contracts/python_toolchain_sync_test.py || true
printf '%s\n' '== Runner-shape contract implementation =='
cat -n tests/workflow_contracts/runner_shape_test.py || true
printf '%s\n' '== Behavioural make-target test candidates =='
rg -n -C 5 --glob '*.py' \
'subprocess\.run|Popen|make (lint-python|lint)|lint-python|PATH|shim|fake.*(command|tool)|monkeypatch.*PATH' \
tests/workflow_contracts scripts/tests || true
printf '%s\n' '== PR file patches for relevant files =='
gh api 'repos/leynos/netsuke/pulls/680/files?per_page=100' --paginate \
--jq '.[] | select(.filename == "Makefile" or .filename == "tests/workflow_contracts/python_toolchain_sync_test.py") | {filename, patch}'Length of output: 231436
This is a boundary test, not only a recipe text check. It will fail if Makefile expansion removes, changes, or reorders the Interrogate arguments. The current GitHub You are interacting with an AI system. |
|
@coderabbitai Please suggest a fix for this issue and supply a prompt for an AI coding agent to enable it to apply the fix. Include the file and symbol names indicated in the issue at the head of your response. Ensure that this is validated against the current version of the codegraph. If further refinement to address this finding would be deleterious, please supply a clear explanatory one to two paragraph markdown message in a code block that I can paste into the CodeScene web ui's diagnostic suppression function so this diagnostic can be silenced. tests/workflow_contracts/nextest_child_cargo_group_test.py Comment on lines +158 to +202 def _build_capable_test_names(source: str) -> set[str]:
"""Return tests reaching a direct or helper-mediated Cargo build command."""
executable_source = mask_non_code(source, RETAINED_RUST_LITERALS)
functions = _rust_functions(executable_source)
wrappers = _cargo_wrappers(functions)
operation_constants = _operation_constants(executable_source)
build_capable = {
name
for _, _, name, body in functions
if _has_build_capable_cargo_command(body, wrappers, operation_constants)
or _calls_build_helper(body)
}
while True:
helper_names = {name for _, _, name, _ in functions if name in build_capable}
callers = {
name
for _, _, name, body in functions
if any(
helper_name != "build" and re.search(rf"\b{helper_name}\s*\(", body)
for helper_name in helper_names
)
}
fixture_users = {
name
for attributes, signature, name, body in functions
if "#[test]" in attributes or "#[rstest]" in attributes
for helper_name in helper_names
if any(
"#[fixture]" in helper_attributes and helper_name in signature + body
for helper_attributes, _, fixture_name, _ in functions
if fixture_name == helper_name
)
}
expanded = build_capable | callers | fixture_users
if expanded == build_capable:
break
build_capable = expanded
return {
name
for attributes, _, name, _ in functions
if name in build_capable
and ("#[test]" in attributes or "#[rstest]" in attributes)
}❌ New issue: Complex Method |
This comment was marked as resolved.
This comment was marked as resolved.
Pin Interrogate 1.7.0 in the Makefile and run it against the repository-owned Python infrastructure at 100% documented coverage. Preserve the estate-synchronised spelling helper exemption while documenting every remaining missing constructor and nested helper. Protect the pin and lint integration with workflow contract coverage.
Select the repository baseline when creating Interrogate's pinned tool environment, so the docstring gate parses the same Python syntax locally and in CI. Exercise the expanded `lint-python` boundary through a controlled `uv` shim, preserving its threshold, spelling-helper exclusions, and owned source scope. Refresh the generated spelling policy required by the current estate dictionary.
Keep the focused Makefile contract readable under the repository's Python lint policy without changing the asserted Interrogate invocation.
Declare the immutable command and scope data explicitly so the workflow contract communicates its stable tuple shapes.
Describe the error and test-double constructor contracts with NumPy-style parameter sections while preserving the module-size policy.
Select CmdMox's `.cmd` launcher on Windows and verify both platform launcher forms. Clarify the coverage-output error parameter contracts.
Use valid NumPy parameter fields while keeping the cargo adapter module within its documented size limit.
Keep the coverage lane responsive by serializing only tests that launch build-capable child Cargo commands. Preserve normal Nextest concurrency, existing private target isolation, and immediate subprocess output.
Recognize restricted-visibility and asynchronous Rust test declarations so build-capable child Cargo commands cannot evade the serialized Nextest group.
Recognize indented Rust helpers and validate Nextest overrides through the shared structural TOML helper.
Describe the explicit Cargo executable and preserve the adapter measurement exception contract.
Keep nested-Cargo discovery from accepting function-like comments or literals while retaining the command tokens needed for policy classification.
Distinguish Rust character literals from lifetimes and labels, and document the source-mask helper contract.
Extract fixed-point discovery helpers to keep the workflow contract\nwithin the repository complexity budget while preserving direct, helper,\nand fixture-mediated nested Cargo detection.\n\nMove Rust syntax masking regression cases into a focused companion\ncontract module, add multi-hop propagation coverage, and retain the\nspelling-helper and Interrogate documentation requirements after rebase.
1a95c08 to
8c21da5
Compare
Summary
This branch adds a pinned
interrogate==1.7.0gate for NetsukePython infrastructure, so
make lint-pythonnow requires 100%docstring coverage across the repository-owned source boundary.
Closes #676.
Review walkthrough
lint-pythonintegration.typ.overloadexception policy.Validation
make check-fmt: passedmake lint: passed; Interrogate reports 100%make doc-coverage: passed (99.14%)make test: passed (2,798 nextest tests and doctests)make test-workflow-contracts: passed (276 tests)make markdownlint: passedmake nixie: passedcoderabbit review --agent: invoked twice after deterministic gates; the service did not return or store review findings.Notes
97.7%(544/557definitions; 13 missing). The issue-comment API rejected recording it withResource not accessible by integration; the scoped gate now passes at 100%.References
https://lody.ai/leynos/sessions/6322cc30-e75e-4b9f-b609-ccde83f647ef
Summary by Sourcery
Enforce complete Python docstring coverage and protect coverage runs from resource contention caused by concurrent nested Cargo builds.
New Features:
Enhancements:
Build:
make lint-python.Documentation:
Tests: