feat: v0.1 tree-sitter complexity gate with Claude Code and Codex hooks - #3
Merged
Conversation
9 tasks
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.
Closes #1
What changed
complexity-gate-core(tree-sitter parsing, per-language decision/depth/naming tables, config resolution, Git changed-span math) and thecomplexity-gateCLI (check,hook claude|codex,init,doctor --coverage).PostToolUse/Stopand Codex equivalents, loop guard (3 blocks per session,UNRESOLVEDafter), state under~/.pickforge/complexity-gate/.-D warnings, llvm-cov floor, self-gate, gitleaks, osv-scanner), cargo-dist release workflow, branch protection.docs/spec.mdis the contract;docs/hooks.mdrecords the harness mapping.Tested
cargo test --workspace --locked --all-targets,cargo clippy --workspace --all-targets -- -D warnings,cargo run -- check crates(self-gate),cargo llvm-cov— see CI.--changedscopes them out).Not tested
--dangerously-bypass-hook-trustinexec; interactive requires the one-time trust prompt).Known risks / decisions
matcharms andloopcount (stricter than clippy's cognitive metric by design; recorded in spec)..complexity-gate.jsonis trusted like any repo file;tests.exemptis restricted tolines,max_blocksclamped, and a changed config is flagged in the report.--changed <paths>resolves paths relative to cwd like any CLI; config resolves nearest-to-file (supports nested packages).Local-review risk class: serious backend.