Oko/Docs

Command reference

oko tasks qualification

Refreshes later batch verdicts and reopens the author task when a covered build fails.

Invocation#

Command
oko tasks qualification [--json]

Inputs and options#

  • The same catalogue used when submitting; Stado supplies the saved build observations.

Output and state effect#

  • Reads source-bound build evidence, commands and exit statuses without requiring a release or publication. States are queued, building, awaiting_tests, passed and failed. The run_id is the standalone build id accepted by stado build status. The required-behavioral-tests-v1 qualification policy requires declared passing post-build tests on every required platform; a passing build with no tests remains awaiting_tests. Stored terminal receipts from an older policy are refreshed rather than accepted as behavioral proof. A failed read cannot finish a task. The normal control loop refreshes qualification before choosing work; a failure makes the affected task actionable again. A failure of a whole batch identifies its covered tasks, not a proven culprit commit.
  • Accepted handoffs remain in the watch's scope beyond the recent-session window. Pending batch results keep the task not done. Listing and show read the stored receipts; qualification performs the fleet refresh. A source commit or published release alone is not defect-specific replay evidence.
  • Qualification cannot preserve a previous done judgment when its receipt is pending, uses an outdated policy, has a read failure, omits a current defect, predates that defect, or lacks a valid submission time. The task remains not done with the actual cause and the obsolete verdict is removed from the report. A recorded blocker or unmet acceptance check also keeps an already-judged task open. A later operator correction still takes precedence; qualification does not reactivate a withdrawn task. CLI task listings and the native Tasks response use this same settlement.
  • Passing fleet receipts do not override an applicable independent not-done or blocked judgment. Its missing work or observed blocker remains visible. Qualification holds discard an obsolete done verdict, not a still-applicable negative judgment; resolving a build result does not itself resolve the independent judgment.
  • Passing fleet evidence cannot create an independent completion judgment. With no applicable done judgment, or an unrecognized observed judgment outcome, the task remains not done with the observed outcome in its reason. An actual retained judgment-read failure remains in judgeOutage and in that reason; passing fleet receipts do not erase its operation or cause. CLI and Desktop share this settlement; the genuine fleet receipts remain visible.
  • A current model refusal also keeps its refused status, identified model, author session and cause. Fleet receipts remain visible but neither passing nor incomplete qualification takes the refusal back. Use the documented unrefuse transition, or a later defect that reopens the work; a build result is not either transition.
  • A receipt can qualify only the exact task_id it names and must retain its handoff-author session_id. Listing a receipt beneath another task does not transfer its successful result. A wrong task or absent author identity keeps it open with the observed fields. The author may differ from the session that received the task: cooperating sessions can hand off repairs for one another. CLI and Desktop use this same settlement.
  • A stored passed or failed receipt that still carries readFailure is refreshed too. Its terminal state does not make an unsuccessful observation immutable. A later valid response for the same handoff replaces that failed observation; the read failure is never cleared merely to make a task look complete.
  • The real transition journey is `node tests/tasks/qualification.mjs` in the Oko checkout. Provide OKO_BIN and STADO_BIN as the actual executables, OKO_TEST_SOURCE_REVISION as the committed Oko revision, OKO_TEST_SUCCESS_EXIT as the platform's successful exit status, and OKO_TEST_QUALIFIED_TASK, OKO_TEST_FIXTURE_SESSION and OKO_TEST_ACCEPTANCE_CHECK for a dedicated test task. The task must already have genuine passed fleet qualification, a real done judge verdict and a met check with its original evidence. The journey verifies the fleet identities, marks that check unmet, inspects the persisted not-done state, restores the original check evidence through the CLI and inspects completion again. Commands, statuses, source and binary digests, failures and restoration results remain under .build/tasks/qualification. It does not start a build or fabricate receipts. Never select an operator's working task.
  • OKO_TEST_UNQUALIFIED_DONE_TASK names a separate read-only task in the same fixture session with a genuine done verdict but no passing source-bound behavioral report or observed acceptance. The journey requires it to remain status not done, standing claimed, with the actual missing-check cause; it never records a substitute verdict.
  • The same journey also requires OKO_TEST_NOT_DONE_TASK and OKO_TEST_BLOCKED_TASK in the declared fixture session. Both must have genuine passed fleet qualification and applicable independent negative judgments, with no separate contract hold. These fixtures are read-only: the journey checks their real Stado identities, not-done status and exact missing-work or observed-blocker cause. It does not manufacture or replace judge verdicts.
  • Also provide OKO_TEST_COOPERATING_TASK: a read-only task in the fixture session whose real passed handoff was submitted by another session. Its successful result must remain applicable to the named task; author identity is not task ownership. The journey compares that handoff with Stado before accepting the fixture and never manufactures a receipt.
  • Also provide OKO_TEST_MULTI_REPO_TASK in the same fixture session: a read-only task with genuine passed behavioral handoffs from distinct repositories, a done judgment, observed acceptance and task evidence matching one handoff. The journey reads each receipt back from Stado and requires derived verified standing; it does not invent a report or verdict.
  • Also provide OKO_TEST_REFUSED_TASK: a read-only task in the fixture session with a genuine current model refusal and passed fleet handoff. The journey compares the receipt with Stado and requires the refused status and exact model/session/cause to survive qualification. It does not create a refusal to make the assertion pass.
  • Also provide OKO_TEST_UNJUDGED_TASK: a read-only task in the fixture session with genuine passed fleet qualification but no applicable independent judgment and no separate contract hold. The journey compares its handoff with Stado, verifies that it remains not done for that exact reason, and never fabricates a judge result. The cooperating-author fixture must retain its own genuine done judgment as well as the passed handoff.
  • OKO_TEST_JUDGE_FAILURE_TASK names another read-only fixture with genuine passed fleet qualification and an actual retained judgment failure, not a fabricated outage. The journey verifies that the task remains open and that the recorded failure survives both the structured response and its displayed reason; it neither calls inference nor changes the fixture.

Refusals and safe exits#

  • Duplicated or changed handoff identities and failed fleet reads remain visible errors (“fleet change <id> is duplicated or has a different identity”). A failed read does not discard the last accepted handoff or report successful tests.
  • A handoff Stado no longer holds at all is not a read error: Stado's change list reads every ticket it keeps, so the receipt settles as failed with “Stado no longer holds fleet change <id>; this handoff will never be built. Hand the source of <repository> to Stado again: oko tasks submit <task-id> --source <checkout> --commit <SHA> --by <session>”, its task becomes actionable again, and later passes stop asking for it.

CLI reference#