Skip to content

feat: v0.5.0a3 β€” Smart Init, Mutation Campaign + Tiered QA Doctrine#30

Merged
PythonWoods-Dev merged 9 commits intomainfrom
fix/standardize-v0.5.0a3
Apr 4, 2026
Merged

feat: v0.5.0a3 β€” Smart Init, Mutation Campaign + Tiered QA Doctrine#30
PythonWoods-Dev merged 9 commits intomainfrom
fix/standardize-v0.5.0a3

Conversation

@PythonWoods-Dev
Copy link
Copy Markdown
Contributor

Summary

Ships Smart Initialization (zenzic init --pyproject), the "Mutant War"
campaign (80 new tests, mutation score 58% β†’ 86.7%), tiered Hypothesis profiles,
and the Vanguard UI refresh for v0.5.0a3.

Smart Initialization β€” zenzic init --pyproject

  • Interactive pyproject.toml detection: when pyproject.toml exists,
    zenzic init asks whether to embed config as [tool.zenzic] instead of
    creating a separate zenzic.toml
  • --pyproject flag: skip the interactive prompt and write directly
  • --force: overwrite existing config in both standalone and pyproject modes
  • Engine auto-detection: mkdocs.yml β†’ mkdocs, zensical.toml β†’ zensical,
    otherwise vanilla defaults β€” works in both modes
  • 12 new tests covering all init paths (standalone, pyproject, interactive,
    force, error states, engine detection)

Mutation Testing Campaign β€” "The Mutant War"

  • Mutation score: 86.7% (242/279 killed) β€” target was 75%, exceeded by +11.7 pp
  • 80 new tests in test_rules.py across 7 specialised test classes
  • 37 survivors classified as equivalent mutations or framework limitations
  • mutmut 3.5.0 configured under [tool.mutmut] in pyproject.toml

QA Infrastructure (Team Sentinel)

  • Hypothesis profiles (tests/conftest.py): dev (50), ci (500), purity (1 000)
  • just test-full: thorough test run with ci profile
  • nox -s mutation: mutmut on src/zenzic/core/rules.py
  • .hypothesis/, .mutmut-cache/ added to .gitignore and just clean
  • Resolver perf test: threshold relaxed 100 ms β†’ 200 ms (O(1) verified, env jitter)

UI Refresh (Team Vanguard)

Documentation

  • Smart init documented in commands.md (EN/IT), configuration index (EN/IT), READMEs
  • Mutation testing campaign documented in CHANGELOG.md and RELEASE.md
  • Stale hardcoded coverage values (98.4%) replaced with gate-relative language
  • CHANGELOG link references fixed (wrong compare ranges, missing [0.5.0a2])
  • Workflow tables updated across EN/IT (CONTRIBUTING, docs/developers, docs/community)
  • Test counts updated from 694 β†’ 706 across CHANGELOG.md and RELEASE.md

Test results

  • 706 passed, 0 failed
  • Branch coverage: β‰₯ 80% (hard gate)
  • Mutation score: 86.7% (242/279 on rules.py)

- Unified Panel: banner + report fused into single Indigo block.
- Traceback Gutter: β”‚  16  ❱ spacing implemented.
- Caret Chirurgico: surgical underline, no noise.
- LinkInfo NamedTuple in validator.py (used by downstream test modules).
- Core fixes: validator, scanner, rules adjustments.
- Closes #4, #6, #13.
80 targeted mutant-killing tests added to test_rules.py:
- TestExtractInlineLinksWithLines (14): empty hrefs, escaped brackets, multi-link.
- TestVSMBrokenLinkRuleMutantKill (22): check_vsm path/anchor, orphan, severity.
- TestAdaptiveRuleEngineRunMutantKill (4): run() short-circuit, content propagation.
- TestAdaptiveRuleEngineRunVsmMutantKill (6): run_vsm() findings, file iteration.
- TestAssertPickleableMutantKill (2): deep-copy guard, UNREACHABLE sentinel.
- TestPluginRegistryMutantKill (27): discovery, duplicates, case, validate_rule().
- TestExtractLinksDeepMutantKill (5): fence-block skip, ref links, empty docs.

Result: 242/279 killed (86.7%), 37 equivalent/framework survivors.
694 tests pass. Suite grew from 614 to 694 (+80 targeted tests).
- Add 'Mutation Testing Campaign' section to CHANGELOG.md and RELEASE.md.
- Update Quality Gates: 694 tests, 86.7% mutation score, 80%+ coverage.
- Fix stale 98.4% coverage in docs/guide/index.md (EN/IT) β†’ β‰₯ 80% gate.
- Fix stale 529/433 test counts in RELEASE.md checksums β†’ 694.
- Fix CHANGELOG link refs: [0.5.0a3] compare range, add missing [0.5.0a2].
- Add just test-full, nox mutation entries to workflow tables (EN/IT).
- Document Hypothesis profiles and mutation testing in developer guide.
`zenzic init` now detects `pyproject.toml` and interactively asks
whether to embed config as [tool.zenzic] instead of a standalone
zenzic.toml.

- Add --pyproject flag to skip the prompt and write directly
- Add --force support for both standalone and pyproject modes
- Extract _detect_init_engine(), _engine_feedback() helpers
- Extract _init_standalone(), _init_pyproject() from init()
- Engine auto-detection (mkdocs/zensical) works in both modes
Cover standalone, pyproject, interactive prompt, --force overwrite,
error states, engine auto-detection, and vanilla fallback.
706 tests pass.
- Add --pyproject flag to commands.md (EN/IT)
- Add --pyproject to Getting Started in configuration/index.md (EN/IT)
- Add Project setup section with zenzic init to README.md and README.it.md
- Add smart init entry to CHANGELOG.md and RELEASE.md
- Update test counts 694 β†’ 706 across CHANGELOG.md and RELEASE.md
@PythonWoods-Dev PythonWoods-Dev merged commit 30d15bf into main Apr 4, 2026
9 checks passed
@PythonWoods-Dev PythonWoods-Dev deleted the fix/standardize-v0.5.0a3 branch April 4, 2026 11:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Rule DSL Parser & Pure Function Compiler

1 participant