CI lint job; milestone definition of done includes clean lint

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Lx9FNLG2CqeBbVGGd9bFsP
This commit is contained in:
2026-10-22 18:55:27 +00:00
parent f7b394585b
commit 2f6dcd5754
2 changed files with 14 additions and 0 deletions

View File

@@ -1,6 +1,17 @@
name: ci
on: [push, pull_request]
jobs:
lint:
# Hard rule (docs/MAINTAINABILITY.md): any finding fails the build.
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with: { go-version: stable }
- uses: actions/setup-node@v4
with: { node-version: 22 }
- run: cd web && npm ci
- run: make lint
test:
strategy:
matrix:

View File

@@ -4,6 +4,7 @@ The build follows the six gated milestones in [`docs/spec/spec.md`](../spec/spec
Each milestone has its own document here. It is written before any code for that milestone and
its **Gate log** is filled in when the gate passes. A milestone is done only when:
0. `make lint` is clean: maintainability is a hard rule ([`docs/MAINTAINABILITY.md`](../MAINTAINABILITY.md)), and every gate script runs lint first,
1. every acceptance line it closes (from [`build-detail.md`](../spec/build-detail.md#acceptance-criteria)) has a test that passes,
2. `make test` (`go test -race ./...`) and `make test-integration` pass,
3. its gate command (`make gate-mN`) passes when run by the supervisor, and
@@ -31,6 +32,8 @@ Departures from the spec are recorded in [`docs/DEVIATIONS.md`](../DEVIATIONS.md
## Rules every WP follows (from "Decisions that don't move")
- **Maintainability is a hard rule.** Follow [`docs/MAINTAINABILITY.md`](../MAINTAINABILITY.md): zero golangci-lint and ESLint findings in your packages, the function, complexity and file-size limits, and the layering rules. Every WP brief cites it.
- One static binary, `CGO_ENABLED=0`. No raw SQL outside `internal/store`.
- The 60 s poll path talks only to devices (SNMP, ICMP) and the local hot store.
- Metric labels on SNMP series: `device=<slug>`, plus `iface=<ULID>` on interface series. Nothing else.