Kill metrics-counter and install_patch gate mutation survivors (#27, #28) - #33
Kill metrics-counter and install_patch gate mutation survivors (#27, #28)#33leynos wants to merge 2 commits into
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: Pro Plus Run ID: 📒 Files selected for processing (1)
🔗 Linked repositories identifiedCodeRabbit considers these linked repositories for cross-repo context during reviews:
Summary
WalkthroughThe test suite now verifies patch-helper metric counters, cached versus rebuilt children, dummy fallbacks, version-gate messages, strict errors, logger propagation, AST-shape validation, and acceptance of extra trailing parameters. ChangesPatch helper coverage
Possibly related issues
Suggested labels: Poem
🚥 Pre-merge checks | ✅ 19 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (19 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Reviewer's GuideAdds precise metrics Counter assertions and new coverage around _patch dispatch/resolve flows plus detailed install_patch version-gate and astroid shape validation behavior, all in tests only. File-Level Changes
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
|
Review finding actioned (branch rebased onto the updated #32):
A full |
4013d9e to
ccafc4d
Compare
|
Heads-up: #34 replaced ci.yml's bespoke |
ccafc4d to
8ab93ef
Compare
d9724d5 to
845a5b2
Compare
8ab93ef to
6b94e98
Compare
|
@coderabbitai review |
✅ Action performedReview finished.
|
Closes #27, #28.
Summary
Second of two survivor-triage PRs following the 2026-07-10 mutmut 3.6.0
run on
main@03b8ed1. Stacked on #32 (branchkill-mutation-survivors); it kills the 61 survivors that PRexplicitly deferred:
get_metrics()counter assertions across every dispatch andresolve
_record_metriccall site, pinning both the precise counterkey and the increment (Mutation testing: metrics counter survivors #27);
install_patchversion-gate coverage — the major-version boundaries,the mixed supported/unsupported combination that pins the
oroperator, missing
__version__defaults, and strict-mode messagecontent — plus
_validate_astroid_shapelogger routing, exact errormessages, missing-attribute handling, and signature tolerance (Mutation testing: install_patch version-gate and shape-validation survivors #28).
Tests only; no production code changes.
Before/after survivor counts
main@03b8ed1(baseline)kill-mutation-survivors)mutmut run)Two mutants the triage worklist had recorded as equivalent (the
"0"version-default strings in
install_patch) are killed here instead ofannotated: asserting the exact skip-warning message
(pylint 0, astroid 0)distinguishes them.Review walkthrough
is the only file touched:
Counterassertions added to the existing resolve, dispatchrouting, and non-string-dir-entry tests, so every
_record_metrickey is pinned via the publicget_metrics()snapshot (Mutation testing: metrics counter survivors #27);
special/plain counters, and the dummy getattr-failure counter
(Mutation testing: metrics counter survivors #27);
test_install_patch_version_gate_reports_exact_versionsparametrizes the unsupported combinations (pylint 5.x, astroid 5.x,
and both
__version__attributes missing) and asserts the exactwarning message (Mutation testing: install_patch version-gate and shape-validation survivors #28);
_validate_astroid_shapetests assert exactPatchErrorand log-record content, that errors land on thecaller-supplied logger, that a missing
object_buildstill raisesPatchError, and that extra trailing parameters are tolerated(Mutation testing: install_patch version-gate and shape-validation survivors #28).
Red-green evidence
_patchmodule (hand-applied metric mutant,_record_metric("dispatch.routine")→_record_metric(None)):Validation
ruff format --check,ruff check,ty check pkg tests tools, andpytest -n auto(91 passed, 1 skipped) all pass on this branch.uv run mutmut runat this branch's tree: 407 generated,407 killed, 0 survived, 0 timeouts, 0 suspicious.
🤖 Generated with Claude Code