I2690 — A session reads whether it is current, attached, announced and useful, from one capability
Derive the four facts of ADR 0226 for the calling worker and answer them as one read: how far the checkout is behind the remote trunk after a bounded fetch, the newest release tag, the transport to the shared server, whether an open mesh session names this worker, and what the board leaves unheld.
PŘIPRAVENO vlna 0 · p0 · profil implementation · běží samostatně
Součást development-runtime — The runtime has a development surface.
Připraveno. Všechny závislosti jsou hotové, takže majordomus plan start I2690 bude přijato.
Cíl
Derive the four facts of ADR 0226 for the calling worker and answer them as one read: how far the checkout is behind the remote trunk after a bounded fetch, the newest release tag, the transport to the shared server, whether an open mesh session names this worker, and what the board leaves unheld.
Proč
The owner, 2026-10-13, after a session worked three hours stale and unannounced in a cluster of nineteen workers: this must never happen again; it must be formalized, derived, inferred, enforced, in .ai, announced, a hard requirement, on GitHub Pages, tested, documented and on the landing page. See ADR 0226.
Aktuální stav
Measured on master f0696ec535 on 2026-10-13: majordomus context prints the task and the peers but not whether the checkout is behind the trunk or the session is unannounced; the SessionStart line says 'Already up to date' from a state fetched earlier; mesh peers lists asks to all but no command lists what is unheld.
Cílový stav
One read capability, declared once with capability! under apps/majordomus-cli/src/capability/builtin/ and projected by majordomus generate to CLI, MCP and HTTP, answers current, attached, announced and useful with the commands that repair each one; an unreachable remote, a closed mesh and a missing server are each a named state, never 'current'.
Rozsah
- apps/majordomus-cli/src/capability/builtin/
- apps/majordomus-cli/src/mesh/
- .ai/repo/policy.yaml
Mimo rozsah
- Refusing anything: that is I2691
- Any screen or page: that is I2692
- A change to how the board is gathered (ADR 0044)
Závislosti
Žádné. Tento úkol je kořenem grafu.
Co na tom čeká
- I2691BLOCKED start, check, finish and the commit and push hooks refuse a change from a session that has not joined
- I2692BLOCKED The join state is projected to the briefing, the Cockpit, the UI, the handbook, the site and GitHub Pages
- I2693BLOCKED A session whose MCP server did not connect says so on the board, and a worker with nothing to do takes an open ask
Kritéria přijetí
- A checkout N commits behind the fetched trunk is reported behind by N with the newest tag
- An unreachable remote is unverified and is never reported current
- A session with no open mesh session on the live server is reported unannounced with the command that announces it
- With no claim held, the answer lists unheld asks to all, review requests with no answer and tasks without an owner, bounded and counted
- The bounds (how far behind, how old a fetch) are read from the policy and declared once
Validace
- bin/majordomus plan validate
- majordomus generate --check
- MJ_TEST_JOBS=2 bash test/run.sh 3010_a_session_joins_the_cluster
Požadované důkazy
- join_state_unit_tests
- join_state_case_3004
Důkazy
Nic nezaznamenáno. Za každým tokenem výše musí stát příkaz nebo artefakt, než lze tento úkol dokončit; vyprávění se odmítá.
Časová osa
- zahájeno
- —
- ověřeno
- —
- dokončeno
- —
Tato tři pole, důkazy výše a stav závislostí jsou vše, z čeho se stav skládá. Neexistuje žádné pole stavu, které by s nimi mohlo být v rozporu.
Canonical record: .ai/repo/project/issues/I2690.yaml. Read it back with majordomus plan show I2690.