Skip to content

spec: source-blind Quint model of the instance lifecycle - #3

Open
closer-claudio wants to merge 2 commits into
mainfrom
closer-claudio/20260906-quint-spec
Open

spec: source-blind Quint model of the instance lifecycle#3
closer-claudio wants to merge 2 commits into
mainfrom
closer-claudio/20260906-quint-spec

Conversation

@closer-claudio

Copy link
Copy Markdown
Contributor

First artifact of the spec-driven testing experiment (farcloser-level SPEC-DRIVEN-TESTING.md): a Quint state-machine model of what ossein is meant to do with backgrounded buildkit instances, cache volumes and the image cache, written from the public surface only (--help output, README, the acceptance criteria in docs/TODO.md) and without reading any source.

The model takes the strict reading of every documented sentence and encodes it as invariants: one writer per cache volume, gc leaves no orphans, one-shot commands leave no state, project-local caches are never deleted by ossein, a failed command changes nothing observable, and a fail-fast refusal is only ever caused by a live lock holder. Where the docs are silent the model does not guess: nine numbered questions in spec/README.md. The first (there is no way to list instances) blocks replay of every instance invariant until answered; the second (does a dead lock holder still block a new buildkit?) is the most likely real bug the driver will find.

Verified: quint typecheck clean; quint run --backend=typescript --invariant=all_invariants finds no violation over 300 runs of 12 steps. Quint itself arrives through the limen baseline (farcloser/limen#58); until that release is pinned here the commands in spec/README.md need a quint on PATH. Full just lint and just test green on this branch after rebasing onto #1.

🤖 Generated with Claude Code

https://claude.ai/code/session_016PTjN7e8aNY1gNsfZ98hgL

First artifact of the spec-driven testing experiment (farcloser-level
SPEC-DRIVEN-TESTING.md): a state-machine model of what ossein is meant to do
with backgrounded buildkit instances, cache volumes and the image cache,
written from the public surface only (--help output, README, the acceptance
criteria in docs/TODO.md) and without reading any source.

The model takes the strict reading of every documented sentence and encodes
it as invariants: one writer per cache volume, gc leaves no orphans, one-shot
commands leave no state, project-local caches are never deleted by ossein, a
failed command changes nothing observable, and a fail-fast refusal is only
ever caused by a live lock holder. Where the docs are silent the model does
not guess: nine numbered questions in spec/README.md, the first of which
(no way to list instances) blocks replay of every instance invariant until
answered.

Typechecks and simulates clean at 300 runs of 12 steps with
quint run --backend=typescript; the flag matters because the default backend
downloads an evaluator at run time.

Signed-off-by: closer-claudio <claudio@farcloser.world>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants