verify-gate
Skill0 starsChanged 6 months agoMITView on GitHub
Quality gate — runs configurable checks against a project's codebase for anti-patterns that functional tests cannot catch
- Reads credentials
7 other projects use a version of this.
Adopted by
Most recently taken up by
- kuhlman-labs/fishhawktheir own version, first seen Oct 31, 2026
- Ces107/agent-forgetheir own version, first seen Oct 25, 2026
- feelthefusion/skill-starter-kittheir own version, first seen Oct 13, 2026
- limoaCatherine/game-studio-harnesstheir own version, first seen Sep 20, 2026
- svy04/ballasttheir own version, first seen Aug 23, 2026
- piprail/piprailtheir own version, first seen Jun 10, 2026
Other versions7 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 7
- pskoett/pskoett-ai-skills★ 327same name
- svy04/ballast★ 73same name
- kuhlman-labs/fishhawk★ 9same name
- piprail/piprail★ 9same name
- limoaCatherine/game-studio-harness★ 4same name
- Ces107/agent-forge★ 0same name
- feelthefusion/skill-starter-kit★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository13 other files it gives its agents.
- AGENTS.mdAGENTS.md
- build-loop-initSkill
- build-loop-iterateSkill
- build-loopSkill
- frontend-designSkill
- handle-pr-reviewSkill
- orchestrateSkill
- phase-goal-reviewSkill
- phase-retroSkill
- regression-detectSkill
- review-prSkill
- spec-authorSkill
- test-gateSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
38 rules. 0 are common, 20 are distinctive, and 18 are very specific to this project.
0
Common
Most of the 4 edited versions we read keep these.
20
Distinctive
This author's own choices. Worth a look.
18
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 8
Run configurable quality checks against a project's codebase.
- Very specific: line 21
Read the project's AGENTS.md and look for a ## Quality checks section.
- Distinctive: line 22
If the section exists, it lists which checks to run (by check name).
- Very specific: line 23
If no ## Quality checks section exists, report "No quality checks configured for this project.
- Very specific: line 24
If dry-run is provided, run checks against the fixture directory instead of the project root.
- Distinctive: line 25
Run each configured check against the target directory.
- Very specific: line 50
Test functions with zero assert statements
- Very specific: line 53
How to scan: Read all files matching test_*.py, *_test.py, tests//*.py, /*.test.ts, /*.spec.ts.
- Distinctive: line 55
Pass criteria: Every test function contains at least one assertion that executes unconditionally.
- Distinctive: line 66
How to scan: Read application source files (exclude test files and vendor directories).
- Distinctive: line 68
Pass criteria: Every except/catch block either logs the error or re-raises with context.
- Very specific: line 80
How to scan: Read all .html, .jinja, .js, .ts, .jsx, .tsx files.
- Distinctive: line 82
Pass criteria: No innerHTML assignments with user-controlled data.
- Distinctive: line 92
How to scan: Read application source files.
- Distinctive: line 94
Pass criteria: All SQL queries use parameterized queries or an ORM.
- Distinctive: line 103
Verify the validation function imports/loads the schema file.
- Distinctive: line 104
Check that all schema file references in AGENTS.md point to files that exist.
- Distinctive: line 106
Pass criteria: Every schema file is loaded by at least one validation function.
- Distinctive: line 113
Read AGENTS.md and extract all rules from "invariants", "non-negotiable", "edit policy", "layer rules" sections.
- Distinctive: line 115
Verify the code matches the description.
- Distinctive: line 117
Pass criteria: Every non-negotiable rule has corresponding enforcement that matches the documented behavior.
- Distinctive: line 123
Pass criteria: No function exceeds the configured line limit.
- Distinctive: line 134
Pass criteria: Every route has at least one test asserting an error status code.
- Very specific: line 142
Pass criteria: Every fetch call checks response.ok or response.status before parsing the body.
- Very specific: line 155
Check file names against secret file patterns (.env*, credentials*, *.key, *.pem).
- Very specific: line 156
Verify .gitignore includes standard secret file patterns (.env*, *.key, *.pem, credentials*).
- Distinctive: line 157
Search file contents for secret value patterns using grep/ripgrep.
- Very specific: line 160
Pass criteria: No tracked files match secret file name patterns, no tracked file contents contain secret value patterns, and .gitignore …
- Very specific: line 178
Pass criteria: Every var(--lense-*) reference in CSS files points to a token defined in tokens.css :root.
- Very specific: line 180
When to run: Only when the project has a tokens.css file.
- Very specific: line 192
Search for page.route( calls with glob string arguments.
- Very specific: line 194
If sub-path requests exist but the glob only uses single *, flag: the mock silently fails to intercept individual-resource operations.
- Very specific: line 196
Pass criteria: Every page.route() glob that mocks a REST resource also covers sub-path routes (:id), either via `` suffix or a separate …
- Very specific: line 198
When to run: Only when the project has E2E test files with page.route() calls.
- Distinctive: line 205
Read the project's root AGENTS.md (the workspace root charter, resolved relative to the project's workspace).
- Distinctive: line 208
If the hashes don't match, flag as FAIL with the expected and actual hash values.
- Very specific: line 235
When run standalone (/sabs:verify-gate project=<path>), the gate reports results but does not modify any files.
- Very specific: line 239
Verify-gate itself is read-only (uses git ls-files for no-secrets-in-commit).
“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
<!-- version: 3 -->Run configurable quality checks against a project's codebase. Each check scans for anti-patterns that functional tests cannot catch — security holes, silent failures, schema drift, and test quality issues.
Relationship to standard linters: These checks are supplementary to AST-based static analysis tools (ruff, eslint, semgrep). The project's verify command should already run real linters. Verify-gate checks catch patterns that standard linters miss: AGENTS.md consistency, contract drift, silent test passes, and project-specific invariants. They are heuristic (text-pattern based, not AST-parsed) and may produce false positives — when in doubt, flag and let the operator decide.
Parameters
project— path to the project root (absolute, or relative to cwd). If omitted, inferred from cwd — cwd must contain a project-levelAGENTS.md, not the workspace root; error with "specify project=" if not.dry-run— path to a fixture directory (optional). When provided, run all configured checks against the fixture directory instead of the project root. Useful for testing new checks against known-bad code. Report results but never modify files.
How it works
- Resolve the project root (same logic as build-loop).
- Always run
root-agents-immutablefirst. This check is non-optional — it runs for every project regardless of the project's## Quality checksconfiguration. If it fails, stop and report the failure immediately. - Read the project's
AGENTS.mdand look for a## Quality checkssection. - If the section exists, it lists which checks to run (by check name). Run only those checks.
- If no
## Quality checkssection exists, report "No quality checks configured for this project. Add a## Quality checkssection to AGENTS.md to enable them." and stop. - If
dry-runis provided, run checks against the fixture directory instead of the project root. Report results but never modify files. - Run each configured check against the target directory.
- Report results: pass/fail per check, with specific findings (file path, line number, description) for failures.
AGENTS.md configuration format
Projects opt in to checks by adding a section to their AGENTS.md:
## Quality checks
- no-silent-pass
- no-bare-except
- no-innerhtml-user-data
- contract-validation
- function-length(50)Built-in check library
no-silent-pass
Scans test files for patterns where a test can pass without executing any assertion.
What to look for:
if condition: returnorif not condition: returnbefore any assertion in a test function- Test functions with zero
assertstatements - Conditional blocks that skip all assertions
How to scan: Read all files matching test_*.py, *_test.py, tests/**/*.py, **/*.test.ts, **/*.spec.ts. For each test function, check whether every code path contains at least one unconditional assertion.
Pass criteria: Every test function contains at least one assertion that executes unconditionally.
no-bare-except
Scans server/application code for exception swallowing without logging.
What to look for:
except Exception:followed bycontinue,pass, orreturnwithout any logging callexcept:(bare except) without loggingcatch (e) { }orcatch (e) { /* empty */ }in JS/TS
How to scan: Read application source files (exclude test files and vendor directories). Search for except/catch blocks. Verify each block contains a logging call or a re-raise.
Pass criteria: Every except/catch block either logs the error or re-raises with context.
no-innerhtml-user-data
Scans templates and JavaScript for XSS patterns where user-controlled data flows into innerHTML.
What to look for:
innerHTML =or.innerHTML +=where the right-hand side contains user-controlled data- Jinja/template variables inside JS string literals without
|tojsonfilter document.write()with user-controlled data.insertAdjacentHTML()with user-controlled data
How to scan: Read all .html, .jinja, .js, .ts, .jsx, .tsx files. Flag any innerHTML assignment where the source could be user-controlled.
Pass criteria: No innerHTML assignments with user-controlled data. All user content rendered via textContent, programmatic DOM construction, or a sanitization library.
no-raw-sql
Scans for SQL injection patterns where user input is string-interpolated into queries.
What to look for:
- f-strings,
.format(), or%formatting inside SQL query strings - String concatenation with variables in SQL contexts
How to scan: Read application source files. Search for SQL keywords near string interpolation. Parameterized queries are safe.
Pass criteria: All SQL queries use parameterized queries or an ORM.
contract-validation
Verifies that schema/contract files are programmatically loaded and enforced by validation code.
How to scan:
- Find schema files: glob for
schema/*,contracts/*,*.schema.json,*.schema.yaml. - Find validation functions: search for
validate,check_schema, or similar. - Verify the validation function imports/loads the schema file.
- Check that all schema file references in
AGENTS.mdpoint to files that exist.
Pass criteria: Every schema file is loaded by at least one validation function. No phantom references.
agents-consistency
Checks that rules stated in AGENTS.md are actually enforced in code.
How to scan:
- Read
AGENTS.mdand extract all rules from "invariants", "non-negotiable", "edit policy", "layer rules" sections. - For each rule, determine what code it describes.
- Verify the code matches the description.
Pass criteria: Every non-negotiable rule has corresponding enforcement that matches the documented behavior.
function-length(N)
Flags functions exceeding N lines (default 50). Excludes blank lines and comments from the count.
Pass criteria: No function exceeds the configured line limit.
error-path-coverage
Verifies that API endpoints have error-path tests.
How to scan:
- Find all route definitions in the application.
- For each route, search test files for tests asserting error status codes.
- Flag routes with zero error-path test coverage.
Pass criteria: Every route has at least one test asserting an error status code.
fetch-status-check
Scans JS/TS for fetch calls that skip status checking.
What to look for: fetch().then(r => r.json()) without checking r.ok first.
Pass criteria: Every fetch call checks response.ok or response.status before parsing the body.
no-secrets-in-commit
Scans all tracked files for accidentally committed secrets or credentials. This check is a hard blocker — if secrets are detected, the build-loop must pause and require operator intervention before proceeding. Secrets findings cannot be suppressed without explicit operator override.
What to look for:
- Files named
.env*,credentials*,*.key,*.pem - File content containing patterns:
API_KEY=,SECRET=,-----BEGIN.*PRIVATE KEY-----,sk-,ghp_,aws_secret_access_key - Base64-encoded secret patterns: long base64 strings (40+ characters) adjacent to key/secret/token assignment patterns
How to scan:
- List all tracked files:
git ls-files. - Check file names against secret file patterns (
.env*,credentials*,*.key,*.pem). - Verify
.gitignoreincludes standard secret file patterns (.env*,*.key,*.pem,credentials*). Flag if these patterns are missing from.gitignore. - Search file contents for secret value patterns using grep/ripgrep.
- Exclude false positives in documentation, test fixtures with dummy values, and
.gitignoreitself.
Pass criteria: No tracked files match secret file name patterns, no tracked file contents contain secret value patterns, and .gitignore covers standard secret file patterns.
Limitations: Base64-encoded secrets and secrets split across multiple lines may evade text-pattern detection. For higher assurance, consider a dedicated secrets scanner (e.g., truffleHog, detect-secrets).
token-consumer-check
Verifies that all CSS token references (var(--lense-*) point to tokens that actually exist in tokens.css.
What to look for:
- CSS files referencing
var(--lense-<name>)where--lense-<name>is not defined in any:rootblock intokens.css - Token renames that leave stale references in consumer CSS files
How to scan:
- Find the token definition file (glob for
**/tokens.css). - Extract all
--lense-*variable names from:rootblocks. - Scan all
.cssfiles undersrc/forvar(--lense-references. - For each reference, verify the token name exists in the extracted definitions.
Pass criteria: Every var(--lense-*) reference in CSS files points to a token defined in tokens.css :root.
When to run: Only when the project has a tokens.css file. Skip silently otherwise.
e2e-route-coverage
Verifies that Playwright page.route() glob patterns cover sub-path routes (:id parameters), not just query-parameter variants.
What to look for:
page.route('**/api/<resource>*', ...)patterns where the trailing*(single star) cannot match sub-paths like/<resource>/:idbecause glob*does not cross/boundaries- The fix is
**(double star) suffix:**/api/<resource>**
How to scan:
- Find all E2E test files (glob for
e2e/**/*.spec.ts,e2e/**/*.test.ts). - Search for
page.route(calls with glob string arguments. - For each glob, check if it ends with a single
*after a resource path segment (e.g.,/api/records*). If so, check whether the test file also exercises requests to sub-paths of that resource (e.g., PUT, DELETE, or GET with/:id). - If sub-path requests exist but the glob only uses single
*, flag: the mock silently fails to intercept individual-resource operations.
Pass criteria: Every page.route() glob that mocks a REST resource also covers sub-path routes (:id), either via ** suffix or a separate route registration.
When to run: Only when the project has E2E test files with page.route() calls. Skip silently otherwise.
root-agents-immutable
Verifies the root workspace AGENTS.md has not been modified. This check is non-optional — it always runs for every project regardless of the project's ## Quality checks configuration (see "How it works" step 2).
How to scan:
- Read the project's root
AGENTS.md(the workspace root charter, resolved relative to the project's workspace). - Compute its SHA-256 hash:
shasum -a 256 <path-to-root-AGENTS.md>. - Compare against the known-good hash stored in the project's build-system hash file.
- If the hashes don't match, flag as FAIL with the expected and actual hash values.
Pass criteria: Root AGENTS.md SHA-256 hash matches the stored reference hash.
Hash file maintenance: To create or update the reference hash (requires operator approval since it reflects a new AGENTS.md version):
shasum -a 256 <path-to-root-AGENTS.md> | awk '{print $1}' > <path-to-hash-file>Output format
## Verify Gate Results — <project>
Checks run: N
Passed: N
Failed: N
### PASS: <check-name>
### FAIL: <check-name>
- `file:line` — description of findingIntegration with build-loop
The build-loop's quality checks step (Branch A, step 5) calls this gate. If any check fails, the build-loop treats it as a verify failure — does not commit and queues a fix task.
When run standalone (/sabs:verify-gate project=<path>), the gate reports results but does not modify any files.
GitHub permission requirements
Verify-gate itself is read-only (uses git ls-files for no-secrets-in-commit). However, the build-loop init should validate that the GitHub token has the scopes needed for the full build cycle:
| Scope | Required by |
repo | verify-gate (git ls-files), build-loop (commit, push), review-pr (create PR, post comments) |
workflow | CI management (workflow dispatch, status checks) |
actions:read | phase-retro CI check (read workflow status) |
The build-loop init Gate 3 should inspect token scopes and report missing permissions with actionable suggestions before starting a phase.
Version requirements
This skill uses an HTML comment version tag (<!-- version: N -->). The build-loop init should read each skill's version field and compare against the minimum versions listed in the MANUAL. If a skill version is below the required minimum, init should fail with a message identifying which skill needs updating.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

