The canonical .doctor.just does not parse — every repo that fetched it has no doctor #92

Closed
opened 2026-08-27 11:11:59 +00:00 by agent.odin · 0 comments
Owner

Found while reviewing the file's Nushell, 2026-08-27.

.doctor.just on fastlane/main (20c7398c) is rejected by just before any recipe body runs:

$ just --unstable -f .doctor.just --list
error: recipe `environment` first defined on line 170 is redefined on line 464
   ——▶ .doctor.just:464:1

Removing that pair exposes a second: openspec-reference is also defined twice. At 20c7398c the file additionally carries ting_store_id and ting_store_remote twice, which just rejects even earlier (variable ting_store_id has multiple definitions).

The file is a bad merge of two doctor generations. Both duplicated recipes have an older and a newer form living side by side:

  • environment — the older writes a bare use flake and hard-errors on an inactive direnv; the newer (4e573fe) ensures the managed bootstrap header and continues diagnostics.
  • openspec-reference — the older is built on ting_store_id/ting_store_remote; the newer (d01076a) derives the store from the repository basename and performs the full openspec store setup reconciliation.

This is not cosmetic. Jostoph is the canonical source of .doctor.just and the file distributes itself: consuming repositories fetch it through the .envrc bootstrap, and sync overwrites their local copy from main. So no repository in the estate currently has a working just doctor, sync, or seam installation — and the doctor cannot even report that it is broken, because just never reaches a recipe body.

In scope

  • Delete the older copy of each duplicated recipe, keeping the 4e573fe/d01076a forms, plus the variables only the deleted recipe read.
  • The fastlane seam guard, found in the same pass: jj log over a revset that matches nothing exits 0 and prints nothing, so the first match arm's $carried.exit_code != 0 never fires and the seam is installed in every repository regardless of whether the forge carries a fastlane bookmark — the opposite of what the recipe's own header scopes it to. default-branch already tests the same call correctly, by empty stdout.

Out of scope

  • The idiomaticity findings from the same review: triplicated jj git remote list parsing that indexes $p.0/$p.1 instead of parse, the unguarded .git/info/exclude read, sync's O(n²) line diff, and governance's bare relative AGENTS.md. Real, none load-bearing; they belong in their own ticket.
  • NU_FORCE_FORMAT. The export is correct for the set shell path. That only [script] recipes exist in this file, so the display_output hook never fires and check's table will not round-trip through from ndnuon, is a separate observation and a separate decision.

Boundary

.doctor.just only. No change to what the surviving recipes do — the newer form of each is kept verbatim.

Acceptance

  • just --unstable -f .doctor.just --list succeeds and lists adopt, default, doctor, wire.
  • No recipe or variable is defined twice.
  • The fastlane recipe reports "none on the forge" in a repository whose forge carries no fastlane bookmark, and installs the seam in one that does.
  • Every [script] body parses under the pinned Nushell with no deprecation warnings.
Found while reviewing the file's Nushell, 2026-08-27. `.doctor.just` on `fastlane`/`main` (`20c7398c`) is rejected by `just` before any recipe body runs: ``` $ just --unstable -f .doctor.just --list error: recipe `environment` first defined on line 170 is redefined on line 464 ——▶ .doctor.just:464:1 ``` Removing that pair exposes a second: `openspec-reference` is also defined twice. At `20c7398c` the file additionally carries `ting_store_id` and `ting_store_remote` twice, which `just` rejects even earlier (`variable `ting_store_id` has multiple definitions`). The file is a bad merge of two doctor generations. Both duplicated recipes have an older and a newer form living side by side: - `environment` — the older writes a bare `use flake` and hard-errors on an inactive direnv; the newer (4e573fe) ensures the managed bootstrap header and continues diagnostics. - `openspec-reference` — the older is built on `ting_store_id`/`ting_store_remote`; the newer (d01076a) derives the store from the repository basename and performs the full `openspec store setup` reconciliation. This is not cosmetic. Jostoph is the canonical source of `.doctor.just` and the file distributes itself: consuming repositories fetch it through the `.envrc` bootstrap, and `sync` overwrites their local copy from `main`. So no repository in the estate currently has a working `just doctor`, `sync`, or seam installation — and the doctor cannot even report that it is broken, because `just` never reaches a recipe body. ## In scope - Delete the older copy of each duplicated recipe, keeping the 4e573fe/d01076a forms, plus the variables only the deleted recipe read. - The `fastlane` seam guard, found in the same pass: `jj log` over a revset that matches nothing exits 0 and prints nothing, so the first match arm's `$carried.exit_code != 0` never fires and the seam is installed in every repository regardless of whether the forge carries a `fastlane` bookmark — the opposite of what the recipe's own header scopes it to. `default-branch` already tests the same call correctly, by empty stdout. ## Out of scope - The idiomaticity findings from the same review: triplicated `jj git remote list` parsing that indexes `$p.0`/`$p.1` instead of `parse`, the unguarded `.git/info/exclude` read, `sync`'s O(n²) line diff, and `governance`'s bare relative `AGENTS.md`. Real, none load-bearing; they belong in their own ticket. - `NU_FORCE_FORMAT`. The export is correct for the `set shell` path. That only `[script]` recipes exist in this file, so the `display_output` hook never fires and `check`'s table will not round-trip through `from ndnuon`, is a separate observation and a separate decision. ## Boundary `.doctor.just` only. No change to what the surviving recipes do — the newer form of each is kept verbatim. ## Acceptance - `just --unstable -f .doctor.just --list` succeeds and lists `adopt`, `default`, `doctor`, `wire`. - No recipe or variable is defined twice. - The `fastlane` recipe reports "none on the forge" in a repository whose forge carries no `fastlane` bookmark, and installs the seam in one that does. - Every `[script]` body parses under the pinned Nushell with no deprecation warnings.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Ting/Jostoph#92
No description provided.