diff --git a/.github/ISSUE_TEMPLATE/custom_rule_proposal.yml b/.github/ISSUE_TEMPLATE/custom_rule_proposal.yml new file mode 100644 index 00000000..13fd2b2e --- /dev/null +++ b/.github/ISSUE_TEMPLATE/custom_rule_proposal.yml @@ -0,0 +1,40 @@ +# SPDX-FileCopyrightText: 2026 PythonWoods +# SPDX-License-Identifier: Apache-2.0 + +name: Custom Rule Proposal +description: Propose a new Z-Code rule to catch documentation flaws +title: "[Rule] " +labels: ["enhancement", "rule-proposal"] +body: + - type: textarea + id: flaw + attributes: + label: What documentation flaw do you want to catch? + description: Describe the issue in detail. + placeholder: "e.g., Missing alt text on images..." + validations: + required: true + - type: textarea + id: failing_markdown + attributes: + label: Example of failing Markdown + description: Provide an example that should trigger this rule. + render: markdown + validations: + required: true + - type: textarea + id: passing_markdown + attributes: + label: Example of passing Markdown + description: Provide the corrected version. + render: markdown + validations: + required: true + - type: input + id: proposed_zcode + attributes: + label: Proposed Z-Code name + description: "e.g., Z7xx" + placeholder: "Z7xx" + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/good_first_issue.yml b/.github/ISSUE_TEMPLATE/good_first_issue.yml new file mode 100644 index 00000000..a46d4303 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/good_first_issue.yml @@ -0,0 +1,20 @@ +# SPDX-FileCopyrightText: 2026 PythonWoods +# SPDX-License-Identifier: Apache-2.0 + +name: Good First Issue +description: Claim an easy task to get started with contributing to Zenzic +title: "[Claim] " +labels: ["good first issue"] +body: + - type: markdown + attributes: + value: | + Welcome to Zenzic! This is a great place to start contributing. + Please describe the task you are claiming or asking about. + - type: textarea + id: task_description + attributes: + label: Task Description + description: What task are you planning to work on? + validations: + required: true diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 47eb80c8..dde1b5e2 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -3,78 +3,28 @@ ## Description - - - + Closes # -## Type of change - -- [ ] Bug fix -- [ ] New feature (new adapter, check, Shield pattern, CLI flag) -- [ ] Documentation update -- [ ] Performance improvement -- [ ] Refactor (no behaviour change) -- [ ] Test coverage - ---- - -## The Zenzic Way — mandatory checklist - -Zenzic's Core is built on four non-negotiable design pillars. Every PR that touches `src/` -must satisfy all that apply. - -### 1. Determinism & Pure Functions - -- [ ] Core validation logic is **deterministic and side-effect-free**: same input always - produces the same output, with no file I/O, network access, or global state mutations - inside pure functions. -- [ ] I/O is confined to CLI wrappers and scanner edges — never inside validator, checker, - or rule modules. - -### 2. Zero Subprocess - -- [ ] No `subprocess.run`, `os.system`, `os.popen`, or equivalent shell calls have been - added anywhere in the linting path (`src/zenzic/core/`). -- [ ] Any new parsers use pure Python stdlib (e.g. `tomllib`, `json`, `yaml.safe_load`). - -### 3. ReDoS Immunity - -- [ ] All new regex patterns use **`zenzic.core.regex`** (the RE2-backed ACL facade) — - direct `import re` is forbidden in governed paths (`src/zenzic/` and `tests/`), - and family-repository tooling must preserve the same ACL contract. -- [ ] New patterns are pre-compiled as module-level constants (`_NAME_RE = re.compile(...)`); - no inline raw-string compilation inside loops or hot paths. - -### 4. Namespace Contract - -- [ ] New finding codes respect the **Frozen Codes** list (`FROZEN_CODES` in `codes.py`): - existing codes are immutable; new codes follow the Tier Model (`Z4xx` Structure, - `Z6xx` Governance). -- [ ] No code previously in `FROZEN_CODES` has been removed, renamed, or had its - suppressibility changed. - ---- - -## Enterprise governance compliance - -- [ ] This PR addresses an approved Issue #___ and complies with the **Issue-First Policy**. -- [ ] Every commit in this PR is **cryptographically signed** (GPG/SSH/S/MIME) and shows as "Verified" on GitHub. -- [ ] Every commit has a valid **Developer Certificate of Origin (DCO)** sign-off (`Signed-off-by:` via `git commit -s`). -- [ ] I have verified and can architecturally justify every single line of code proposed in this PR (**No AI Slop**). -- [ ] All commit messages comply with the **Conventional Commits** specification. - ---- +## Type of Change -## Quality gates +- [ ] Bug fix (non-breaking) +- [ ] New feature (non-breaking) +- [ ] Breaking change (fix or feature that breaks backward compatibility) +- [ ] Documentation / D.I.A. update +- [ ] Technical Debt removal / Refactoring -- [ ] `just verify` passes end-to-end (pre-commit + coverage ≥ 80% + `zenzic check all --strict` self-dogfood). -- [ ] New behaviour is covered by tests — happy path and at least one failure case. -- [ ] `nox -s lint` passes (`ruff check` + `mypy --strict`). -- [ ] REUSE/SPDX headers are present on every new file. +## Engineering Quality Gates ---- +- [ ] **TDD / Tests:** New or updated tests cover these changes. The test suite passes locally. +- [ ] **Static Analysis:** `uv run zenzic check all --strict` passes. The DQS score has not regressed. +- [ ] **D.I.A. (Documentation Impact Analysis):** If this PR modifies CLI, rules, or core behavior, the user documentation has been updated simultaneously. +- [ ] **Zero Subprocess:** No unauthorized shell executions or non-Python dependencies are introduced. -## Notes for reviewers +## Enterprise Governance - +- [ ] **Issue-First:** This PR addresses an explicitly approved Issue. +- [ ] **Signatures:** Every commit is cryptographically signed (GPG/SSH). +- [ ] **DCO:** Every commit contains a valid `Signed-off-by:` line. +- [ ] **Semantics:** Commit messages follow the Conventional Commits specification. +- [ ] **Absolute Ownership:** I have verified and can architecturally justify every single line of code. No unreviewed AI-generated code is included. diff --git a/mkdocs.yml b/mkdocs.yml index b6d834af..d5ad1ab9 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -11,6 +11,7 @@ docs_dir: docs site_dir: site repo_url: https://github.com/PythonWoods/zenzic repo_name: PythonWoods/zenzic +edit_uri: edit/main/docs/ copyright: "Copyright © 2026 PythonWoods — Apache-2.0 License" extra_css: