Verification Loop
Comprehensive verification system for ensuring code quality before commits and PRs.
When to Activate
- •After completing a feature or significant code change
- •Before creating a PR
- •After refactoring
- •When you want to ensure quality gates pass
Verification Phases
Phase 1: Build Verification
bash
go build ./...
If build fails, STOP and fix before continuing.
Phase 2: Vet Check
bash
go vet ./...
Report all vet warnings. Fix before continuing.
Phase 3: Test Suite
bash
go test -race -cover ./...
Report:
- •Total tests
- •Passed / Failed
- •Coverage percentage
- •Race conditions detected
Phase 4: Security Scan
bash
# Check for hardcoded secrets grep -rn "password\|secret\|api_key\|token" --include="*.go" . # Check for debug prints grep -rn "fmt.Println\|log.Print" --include="*.go" .
Phase 5: Diff Review
bash
git diff --stat git diff HEAD~1 --name-only
Review each changed file for:
- •Unintended changes
- •Missing error handling
- •Potential edge cases
Output Format
code
VERIFICATION REPORT ================== Build: [PASS/FAIL] Vet: [PASS/FAIL] (X warnings) Tests: [PASS/FAIL] (X/Y passed, Z% coverage) Race: [PASS/FAIL] Security: [PASS/FAIL] (X issues) Diff: [X files changed] Overall: [READY/NOT READY] for PR Issues to Fix: 1. ... 2. ...
Continuous Mode
Run verification after:
- •Completing each function
- •Finishing a component
- •Before moving to next task