Skip to content

feat(install): place a dckt alias beside the docket binary - #400

Merged
danielhanold merged 11 commits into
mainfrom
feat/install-an-alias-for-the-docket-binary
Oct 6, 2026
Merged

danielhanold merged 11 commits into
mainfrom
feat/install-an-alias-for-the-docket-binary

Conversation

@danielhanold

@danielhanold danielhanold commented Oct 6, 2026 •

Copy link
Copy Markdown
Owner

↩ Change 0534 — Install an alias for the docket binary

Summary

Every install now places dckt, a symlink to the docket binary, in the same bin directory:

  • The release downloader (internal/release/downloader/install.sh) creates a relative dckt -> docket link after it places the binary.
  • The development installer (docket development install) creates the alias inside its journaled transaction, so a rolled-back install removes the alias it created and leaves any earlier alias alone.

A foreign or unresolvable dckt is never overwritten: the install still succeeds and prints a warning. docket install check reports a missing or foreign alias as a warning finding (binary-alias-missing / binary-alias-foreign), and docket uninstall leaves the alias in place, as it does the binary.

Review (deep tier)

# Severity Finding Disposition
1 blocker A looping dckt, a link through a file, or an unreadable dckt made install and check fail instead of reporting the alias as foreign fixed — 07d1b63
2 minor A docket-recorded alias that the user later replaced kept a stale binary-alias record in install state fixed — 582a5d0
3 minor The downloader's alias= record line is written but never read fixed (now documented as informational only) — 1b77b83
4 minor A vanished binary made docket's own alias read as foreign, with a misleading remedy fixed — 582a5d0

The release smoke (scripts/release-smoke.sh) now asserts the alias, but it runs only in release-candidate CI. Locally it was only syntax-checked.

…ike install.sh

installHandoff mirrors internal/release/downloader/install.sh's fresh-install
path but predated its alias step, so install check correctly reported the
missing dckt and confirm-install's no-warning promise failed. Mirror the
downloader: a relative dckt -> docket symlink beside the binary and alias= in
the ownership record.
… install

Review blocker: a looping dckt, a link through a regular file or into an
unreadable directory, or an unreadable regular-file dckt made InspectBinaryAlias
and planBinaryAlias return the resolution error, failing development install
(filesystem-failed) and install check. Once the alias path is known to exist,
any failure resolving or reading it is now an AliasForeign finding; only the
Lstat error and failures canonicalising the binary path remain errors.
… is not a foreign alias

Two review findings, batched:

- A dckt docket recorded earlier and the user later replaced was reported
  foreign but its roleBinaryAlias record was carried forward forever (records
  with no harness are always carried). The development install now passes the
  foreign alias path to desiredState, which drops any prior roleBinaryAlias
  record for it, so the published state stops claiming a path docket no
  longer owns. The record never granted ownership; this keeps state truthful.

- When the docket binary itself had vanished, check classified docket's own
  dckt -> docket link as AliasForeign with the "docket did not create what is
  at this path" remedy, contradicting the binary-drift report. checkBinaryAliases
  now skips the alias probe for an absent binary; binary drift (or a
  re-install) covers it. InspectBinaryAlias's primitive classification is
  unchanged, and an unresolvable alias beside a present binary is still
  foreign, never an error.
@danielhanold
danielhanold merged commit dc35598 into main Oct 6, 2026
1 check passed
@danielhanold
danielhanold deleted the feat/install-an-alias-for-the-docket-binary branch October 6, 2026 14:57
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.

1 participant