Choose the right verification gate
Contributor guide · Runtime qualification
Normal local work
Section titled “Normal local work”mise run checkThis runs formatting checks, go vet, dead-code analysis, race-enabled unit tests, Compose validation, and repository-local documentation links.
Run the narrowest relevant tests during implementation, then this gate for code changes.
Use mise run docs-check for a documentation-only link/anchor pass.
Use mise run docs-site-check for the Astro/Starlight build and generated-site checks.
Use mise exec -- go test -race ./.github/workflows for the website and application CI contracts, which are not included by go test ./... because the directory is hidden.
See mise.toml (GitHub) for the exact executable commands.
Docker-backed integration
Section titled “Docker-backed integration”mise run test-integrationThis builds the Pi image and checks doctor, Docker runtime, PostgreSQL/store/migrations, and deployment behavior with Docker-backed fixtures. Use Docker Engine or Docker Desktop with enough capacity and network access for fixture images.
The executable documentation examples can be checked independently:
mise exec -- go test ./internal/deployment -run TestPiOperatorRestoreRequiresConfirmedNativeAbsence -count=1mise exec -- go test -tags=integration ./internal/deployment -run TestPiOperatorExamplesPreserveComposeSelection -count=1The restore test uses stub commands and temporary data. The Compose example test renders the documented selections without deploying or changing protected state. The Docker-backed gate exercises the orchestrator image check described in source builds.
Investigate test duration
Section titled “Investigate test duration”The PR check job captures the host-side unit, general Docker integration, and Pi protocol test commands with go test -json -count=1.
It preserves readable test progress and test failures, publishes a job summary, and uploads the check-test-timings artifact for seven days, including available evidence after failure.
An interrupted or unstarted command is reported as incomplete, not as zero time.
Missing, null, or negative terminal-event durations also make the capture incomplete; their costs are null in JSON and unavailable in Markdown, while an explicit zero remains a valid measurement.
An unfinished command’s wall time is likewise null, and a measured wall time remains available even when test-event data is incomplete.
Observed packages and named tests must have terminal events; output alone does not establish a complete test execution.
To measure the store suite locally after preparing the Docker integration prerequisites:
mise exec -- go build -o bin/test-timings ./scripts/test-timingsmise exec -- bin/test-timings run coverage/test-timings integration -- sh scripts/go-test.sh -p 1 -race -tags=integration -count=1 -json -timeout 30m ./internal/storemise exec -- bin/test-timings report coverage/test-timings integrationUse a fresh output directory for each comparison, or remove only that comparison’s old timing files first.
Each capture writes <label>.events.jsonl and <label>.run.json; reporting writes summary.md and summary.json.
The JSON summary includes all completed test results and fixture samples, while the Markdown tables show the slowest twenty entries per category.
The runner expects a JSON-producing Go test command and returns its failing exit code; malformed capture output also fails an otherwise successful command.
Ordinary store integration fixtures lazily share one PostgreSQL process per test-binary invocation, but each fixture gets a distinct empty database cloned from template0.
The normal migration path still runs for every store initialization; no migrated application template, shared tables, or rollback-only isolation replaces fresh databases.
Test cleanup drops only its database, including any leaked connections, and TestMain removes the owned shared container after all tests finish.
Dedicated startup/password and concurrent-migration tests, the fresh/existing migration probes, and the separate migration-engine package retain fresh PostgreSQL processes.
The shared server retains filesystem hardening and normal durability settings; bounded WAL/checkpoint settings keep repeated fixture creation within its disposable tmpfs budget.
This changes fixture allocation, not the suite’s application-test parallelism.
Store integration fixtures log PostgreSQL container startup, port discovery, readiness polling, removal, isolated database creation/drop, and each writable store.Open call.
Reports count container-start attempts separately from per-database creation attempts so process reuse is visible.
Internal fixture phases from nested helper subprocesses are not merged into the parent command’s phase counts, although their runtime remains included in the owning test’s duration.
Fixture identifiers are process-local counters, and timing records contain no connection strings, passwords, SQL parameters, or error messages.
Raw Go test output still has the same sensitivity as ordinary CI logs and must not contain real credentials.
Fresh and already-migrated schema probes measure migrations.Run separately and verify the resulting migration history.
The store_open phase includes connection setup and migration handling; probe results do not establish the migration share of every store initialization.
Phase statistics report sample count, errors, total measured work, median, and nearest-rank p95. Parent test durations include their subtests, and concurrent package or phase totals are not elapsed wall time. Command wall time includes compilation and execution, but not preceding image builds. Docker-contained Workflow, recovery, upgrade, deployment, and development-image gates are outside this capture scope, as are individual SQL operations and unfinished fixture phases. Do not subtract these samples from wall time and label the remainder as test-body time.
Complete backend qualification
Section titled “Complete backend qualification”mise run test-docker-integrationOMNIGREX_MICROSANDBOX_KVM_GID=<host-kvm-group> mise run test-microsandboxThe Microsandbox gate requires a Linux/amd64 Docker host with usable KVM.
On that host, obtain the group with stat -c '%g' /dev/kvm.
From macOS, use an existing authorized remote DOCKER_HOST=ssh://USER@HOST and that host’s numeric KVM group.
Most source gates transfer fixtures over stdin rather than mounting client-side files.
Image-only deployment smoke must run on the daemon host because Compose secrets are host files.
| Focus | Docker task | Microsandbox task |
|---|---|---|
| Runtime/storage/resources | test-integration | test-microsandbox-integration |
| Pi protocol/configuration/Sessions | test-pi-integration | test-pi-microsandbox-integration |
| Complete controlled Workflow | test-pi-workflow | test-pi-microsandbox-workflow |
| Failure recovery | test-pi-recovery | test-pi-microsandbox-recovery |
| Upgrade and retained state | test-pi-upgrade | test-pi-microsandbox-upgrade |
| Image-only deployment | test-pi-deployment | test-pi-microsandbox-deployment |
mise run test-compose delegates to disposable Pi deployment smoke.
Its fixtures use isolated names and remove their own resources; inspect the task/script before running a full-stack gate against a shared host.
The production Compose files retain fixed defaults and are not isolated merely by changing the project name.
The native integration gate also runs the bounded catalog longevity/multi-process, coordinated payload, and v0.7.6-to-v0.7.11 catalog migration/backup-recovery regressions. See Microsandbox upgrade evidence for their assertions and limits.
Live external gates
Section titled “Live external gates”The GitHub gate performs a Developer App repository-ID read and submits both Reviewer outcomes against a pre-existing Developer App-authored Pull Request.
It can mutate live review state.
Supply the OMNIGREX_LIVE_GITHUB_* values listed by the skipped test, using a designated fixture repository and Pull Request, then run:
mise run test-live-githubFor a paid provider prompt through the production runner, see live-provider smoke. Live gates are opt-in and separate from deterministic controlled-provider CI. Never substitute real credentials into ordinary fixture gates.
Release evidence
Section titled “Release evidence”CI runs docker-check, development-qualification, and the required Linux/amd64 KVM microsandbox job independently.
The stable check job succeeds only when all three pass, preserving the required branch-protection context and gating publication on every qualification.
The development job pulls the exact selected golden digest, verifies the cold/offline module source, and runs the real development-container unit suite with its resource limits.
To check the dependency contract locally, run mise exec -- go test -race ./.github/workflows.
CI runs these tests explicitly because go test ./... excludes hidden directories.
They execute the aggregate shell against success, failure, cancellation, skipped, and missing results, and check isolated development-build ordering and failure propagation with disposable stubs.
After publication, CI repeats image-only smoke against actual published registry digests.
The development image has additional exact-digest native qualification before repository promotion.
Only after release readiness succeeds does release-candidate render backend-specific deployment guidance from verified packaged metadata and the qualified development-environment artifact.
The early publication summary is unqualified build information, not a deployment recommendation.
Passing unit tests or fixture aliases alone does not establish a deployable release.
See runtime qualification and release selection.
Reviewer CI-admission regressions
Section titled “Reviewer CI-admission regressions”Use TestReviewScheduling* for deterministic result/grace/deadline evaluation and internal/reviewpolicy tests for strict policy validation.
TestReviewerAllocationRequiresOrchestratorAdmission exercises the real PostgreSQL allocation boundary without an admission fence.
TestReviewGateSharedObserverPersistsAndFencesTargets uses the production shared CI observer with a deterministic HTTP provider, durable healthy delayed claims, frozen policy/inventory, and verified test-merge replacement.
Scheduling fixtures must not sleep for registration grace or CI deadlines.
TestPiControlledWorkflow includes pending-CI admission after the actual Developer handoff, asserting no Reviewer Participant, active Turn, successor execution job, or second Runtime Process is allocated until CI becomes terminal.
It then exercises successful admission through the real Reviewer launch and native review path.
The ci-repair subtest returns a selected failure directly to the retained Developer Participant/Session, verifies no Reviewer allocation, publishes the repair, then exercises success reset and native review.
TestCIRepairRoutingCommitsOneSuccessorAndCharge and TestCIAdmissionResetOnlyOnLiteralSuccessAtAllocation exercise atomic repair routing, the third/fourth boundary, unchanged Review Cycles, allocation-time resets, and stale-reset rejection.
The existing default Docker and Microsandbox Workflow script selectors both include that scenario.
Run mise run check, mise run test-integration, and mise run test-pi-workflow, and inspect the same-head Linux/KVM CI result for mise run test-pi-microsandbox-workflow before claiming backend qualification.
Never attempt nested Microsandbox qualification inside a Microsandbox Execution Environment.
TestPiControlledWorkflow/clarification-large-history seeds more than 1 MiB of durable, already-delivered historical fixture input for each Role, then runs retained-Session continuation through actual Pi RPC and bounded MCP retrieval of the new answer and question rounds.
The transport-independent projection regression additionally retrieves every content chunk of an oversized pending batch, including JSON escaping and multibyte characters.
TestPiFailureRecovery/clarification-restart records a real completed Pi prompt and question publication for each Role, then restarts the orchestrator Store/backend before settlement.
It verifies corroboration enters clarification waiting without spending an infrastructure retry, stops the Runtime Process, and schedules retained-Session continuation only after a correlated human reply.
The PostgreSQL clarification recovery matrix additionally covers empty-question yields, input on both sides of the corroboration boundary, unpublished-question rejection, and revalidation after explicit Human Handoff recovery.
TestPiControlledWorkflow/planning also admits an amendment and steering after preparation, verifies actionable checkpoint non-publication and identical-operation replay through the existing Pi bridge, yields with empty questions, and delivers both inputs in the same Participant, Session and Workflow Attempt.
It asserts explicit assessments, audience reinterpretation, a revised standalone CLI plan, immutable history, exactly one complete final checkpoint, unchanged budgets and no implementation allocation.
The first two answer/question rounds have no intervening checkpoint; the final pair remains complete and requires exact confirmation.
TestPlanningNonPublicationRecovery distinguishes committed late-input/oversize rejections whose acknowledgments were lost from interruption before reservation or before frozen-payload publication, and retains a successful-publication control with the same frozen history bounds.
Recovery may prove absence only after durable Runtime Process stop and closed admission under the Workflow lock; committed reservations still require exact-artifact reconciliation.
TestPlanningUnreadInputRequiresDurableCoverage keeps publication fenced until every frozen input chunk is durably recorded, not merely read.
These deterministic tests establish the continuation mechanism, not real-model reasoning quality.
Manual release designation
Section titled “Manual release designation”See release publication for candidate evidence, finite artifact retention, manual alpha publication, and no-rebuild stable promotion.
Run mise exec -- go test -race ./.github/workflows explicitly: the hidden-directory suite validates workflow boundaries; ordinary Go release behavior tests live in scripts/release/ and are included in the normal unit gate.
Product post-publication smoke now verifies and extracts the CI deployment archive before testing its Compose files with captured exact digests.
Dedicated release App setup and live historical-tag authorization, first publication, anonymous GHCR access, and first promotion remain separately authorized post-merge acceptance.
Conversation contract regressions
Section titled “Conversation contract regressions”TestPermanentReferencesSurviveFailureReplacementAndRestart and TestConcurrentInputReferencesAndReceiptPublicationReservation cover durable non-rebinding names, exact targets, source deduplication, concurrent admissions and independently reserved acknowledgment publication.
TestNaturalCorrectionsAndHistoricalConflictFenceEveryRole covers explicit correction links, several historical decisions, incompatible authorized-human evidence and reconciliation without application semantic matching.
TestConversationAssessmentFencesAllRoleTerminalAdmissionAndRecoversExactly checks real locked-store terminal fences and operation-bound assessment replay for Planner, Developer and Reviewer.
TestQualifiedWithdrawalAndRenewedExactConfirmation checks change requests, invalidation, unchanged-pair renewal and settlement-time authority rather than treating admission as confirmation.
TestFrozenPayloadReconcilesWithoutRendererOrSignatureRegeneration, TestCompletePayloadLimitIncludesUnicodeSignatureAndMarker and TestOversizeCompletePairReturnsActionableDefiniteNonPublication distinguish exact new-format recovery from rendering, including complete payload boundaries and definite rejection without truncation or half-pair publication.
Controlled-provider qualification establishes these mechanisms, not real-model semantics, tone or reading burden.
After a separately authorized deployment, record fresh unassisted real-provider results and actual human feedback under Work Item 176 or a linked follow-up; closed evaluation 172 is not an unqualified pass or a substitute for that assessment.
TestRevisedQuestionsRejectMixedEvidenceAtomically covers the old-plus-current versus current-only evidence contrast for replaced questions.
TestResolutionGatewayRejectionReplayAndCorrectedRequest exercises production backend/gateway result semantics, identical-operation replay, corrected fresh requests, and unexpected-error masking.
TestResolutionRejectionDurableReceiptAndFreshCorrection covers operation-bound pre-effect rejection, atomic batches, receipt replay, fresh correction, and stopped-Turn recovery of a lost rejection acknowledgment for Developer and Reviewer.
TestPiControlledWorkflow/planning deliberately submits invalid older-question evidence, replays the rejection through the selected pinned Pi bridge, corrects the request without another human answer, and reaches the consolidated planning pair and confirmation without implementation allocation.
A successful MCP transport or a SUCCEEDED invocation is not itself a recorded resolution: consumers must inspect recorded and application; the resolution aggregate and operation-origin proof remain authoritative.
No terminal-outcome consumer treats resolve_clarification as Stage completion; reconciliation distinguishes durable rejection receipts from actual resolution origins and leaves absent evidence unresolved.
TestProposalRejectsEveryStaleHistoricalInterpretation preserves the multi-decision correction fence and immutable history while permitting explicit reaffirmation of an unchanged decision.
TestPiControlledWorkflow/planning now traverses three question rounds: A2 corrects A1, only one R1 interpretation is reaffirmed, and A3 accepts the revised R3 question.
It recovers both invalid mixed-round resolution and stale historical proposal rejection through the selected pinned Pi bridge, with exact replay, explicit unchanged-decision reaffirmation and one complete published pair without another human answer or implementation allocation.
TestPlanningNonPublicationRecovery/historical-rejection-commit-ack-lost restarts through the durable exact-operation rejection receipt rather than inferring outcome from frozen history.
TestPlanningRejectionProjectionBudgetsEncodedBytes covers small inline results, long escaped histories, and a single oversized decision which must use bounded retrieval rather than truncation.
Docker-backed TestHistoricalPlanningRejectionBoundedThroughPinnedSession generates 900 published five-question rounds and a delivered/assessed correction, rejects through the production gateway, and checks exact replay plus complete retrieval of all 4500 durable prerequisites from a separate Store.
It passes the generated result and every remaining page through the selected pinned MCP extension and Session validator/loader, with the former unbounded result as a failing control and successful retained-Session reopening for bounded feedback.
Exact planning implementation admission
Section titled “Exact planning implementation admission”TestExactImplementationConsentWithdrawalRestartAndAdmission, TestKnownInputAndMaterialRevisionFenceImplementation and TestDelayedEarlierAuthorizationCannotUndoWithdrawal distinguish confirmation, exact-pair consent, immaterial revalidation, material supersession, withdrawal and delayed source replay without time expiry.
TestImplementationPreparationRechecksActorAndOpenWorkItem checks fresh external authority and Work Item identity before preparation can commit.
PostgreSQL TestImplementationAdmissionSerializesWithdrawalSteeringAndRestart and TestImplementationClosureAndFirstAdmissionHaveOneStartBoundary race the real locked first-admission transaction against human input/closure and replay the stale preparation through another Store.
TestImplementationRepositoryMovementReopensValidationWithoutRevokingGrant preserves an unused grant while queuing Planner relevance assessment, without allocating a Developer Participant.
TestImplementationAcceptedPairRequiresCompleteLosslessDelivery fences terminal handoff until every omitted accepted-pair chunk is durably read.
TestImplementationMilestoneOutboxReconcilesLostReceiptWithoutRetryNoise restarts publication after a lost response and observes exactly one queued and one started milestone independently of label effects.
TestPiControlledWorkflow/planning extends the unchanged planning-only confirmation path with fresh authorization of the already-ready pair, retained Planner validation, first Developer admission, ordinary CI admission and native Reviewer approval.
The direct-development controlled path remains independently exercised.
Run the normal local, Docker integration, controlled Workflow/recovery and exact-head Linux/KVM gates before claiming backend qualification.
These fixtures do not deploy the feature, exercise a historical production plan or establish real-model semantic reasoning quality.
Clarification request rejection
Section titled “Clarification request rejection”TestRequestRejectionGatewayConversationAndCorrection runs the two-question received-input-index conversation through the production gateway/backend and PostgreSQL store for all Roles.
It assesses the delivered answer, resolves Q2, rejects a changed Q1 body without publication, replays the rejection, and exercises both unchanged-body/introduction and explicit-replacement corrections.
It also covers duplicate IDs, omitted unresolved questions, applicable count limits and unjustified empty-question waiting at the actual admission boundaries.
TestRequestRejectionLostAcknowledgmentAndEarlierUnsettledPublication reads the committed receipt through another Store, distinguishes earlier uncertain publication from correctable arguments, and retains stopped-and-fenced recovery without inventing a rejection from absence.
TestRequestRejectionGatewayAncestorReplayAcrossCheckoutHeads fails the original Turn and retries identical arguments through a restarted production backend at the same or a changed checkout head, then publishes a fresh correction against the retry head.
Backend replay controls retain exact-request/resource/authority checks, reject genuine waiting and malformed evidence across changed heads, and verify rejection replay restores no publication state.
TestClarificationRenderPreflightDoesNotClaimQuestionIdentities uses the real GitHub renderer through Gateway + Store: oversized render preflight and its replay leave no round/reference, authoritative duplicate validation still takes precedence, and a shortened fresh operation publishes the first round normally.
It also verifies that a later uncertain POST retains its frozen artifact and fences even oversized fresh requests.
TestClarificationRecordedPromptRecovery includes a handled rejection before each genuine clarification outcome across Roles and stopped/normal corroboration paths.
TestRetryTurnExposesOnlyItsSuccessfulAncestorTerminalIntent includes a rejected request before the genuine review handoff to exercise ancestor counting, prior-intent discovery and confirmation.
Strict-result and outcome-selection unit tests keep malformed successful evidence fail-closed and unknown dependency errors masked.
TestPiControlledWorkflow/planning passes request rejection and exact replay through the selected pinned Pi bridge, then publishes one corrected replacement round without another human answer or implementation allocation.
Run mise run check, mise run test-integration, mise run test-pi-workflow and mise run test-pi-recovery; inspect same-head Microsandbox Workflow/recovery CI before claiming both-backend qualification.
These deterministic fixtures establish mechanisms, not real-model reasoning quality or deployment of a historical recovery.
