The product, its assistant, the repo, the host and every unit on the box now
share one name. 638 files, ~3,000 mentions: UI copy, config, env keys
(FLEETCROWN_* -> LOKI_*), systemd units (fleetcrown-* -> loki-*), docs,
articles, the deploy workflow other repos reuse, and nine file names.
- Three article slugs carried the old name and had been shared; permanent
redirects keep those links alive (next.config.ts).
- test-no-retired-name.sh now also forbids the old product name across the
whole repo, so the rename cannot creep back through templates and examples.
- ASSISTANT_STACK collapses the product and the assistant into one entry,
because they are now the same name.
Infra was cut over ahead of this merge: /opt/loki, loki-* units, the `loki`
database and role, loki.orangecat.ch (old host 308s to it; /api, /widget,
/embed keep proxying), GitHub repos bitbaum/loki and bitbaum/loki-releases.
The Resend sending domain stays fleetcrown.orangecat.ch until the new domain
is verified in DNS.
Claude-Session: https://claude.ai/code/session_016YJVAanfj8keVSXyZnTemh
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Replace the Resend SDK transport in src/lib/email.ts with the fleet's
@bitbaum/mail-kit. Templates and the sendEmail/sendEmailFire signatures
stay; the transport underneath is now sendMail (never throws — the
awaitable sendEmail preserves its old throw-on-failure contract for
callers). Sender SSOT moves from EMAIL_FROM to RESEND_FROM (mail-kit's
env contract) with conventionalFrom(APP_NAME) as the fleet-default
fallback; APP_EMAIL_FROM is gone from brand.ts and the env preflight now
warns on missing RESEND_FROM. The email-canary cron probes via
mailHealth() instead of a hand-rolled /domains fetch, and the digest
cron passes an idempotency key so a retried tick cannot double-send.
The resend dependency is removed.
Claude-Session: https://claude.ai/code/session_01WqKqMnHQHSmkGFfc5t7Rxn
Co-authored-by: Mao Nakamoto <41178744+maonakamoto@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
* chore: add a formatter, matching the style this repo already writes
singleQuote=false was chosen by counting this repo's own
imports, not by fleet decree. The fleet is genuinely split and the two repos
that already had a .prettierrc disagreed with each other, so there was no
standard to restore. Quote style does not cross repo boundaries; having a
gate does.
Markdown is ignored for now — prettier rewraps prose, which would bury the
real diff.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
* style: format with prettier (1062 files)
Mechanical. No behaviour change. This SHA is listed in
.git-blame-ignore-revs so `git blame` skips it.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
* chore: teach git blame to skip the reformat
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
* fix(lint): reattach two guards the reformat detached
Both effects were one-liners, so a trailing eslint-disable-line covered the
setState call:
useEffect(() => { setSelected(new Set()); }, [q.length]); // eslint-disable-line ...
prettier expanded the block. The comment stayed on the closing line while the
call moved above it, so the guard protected nothing and the rule its author had
deliberately silenced failed the build.
This is the second shape of the same defect — hirnli had the eslint-disable-NEXT-line
variant. Both come from the same fact: an eslint directive binds to a line
number, so reformatting can silently unbind it, which makes 'mechanical, no
behaviour change' false for any bulk reformat.
* chore(desktop): bump the runner version the reformat requires
desktop-release-drift enforces that anything built into Fleet Runner which
differs from the last released tag must carry a version ahead of that tag —
main read 0.8.15 and fleet-runner-v0.8.15 already shipped.
A whole-repo reformat changes bytes under desktop/, so the gate fires. The
alternative was adding desktop/ to .prettierignore, which would buy a quiet PR
by carving a permanent hole in the formatter's coverage — the precise shape of
silent drift this test was written to catch. Bumping is what the rule asks for
and costs one patch release whose only content is whitespace.
* chore: merge main and re-format
A whole-repo reformat conflicts with any concurrent commit, and a conflicting PR
runs no checks at all while reporting nothing. Conflicts resolved to main,
which is correct because this branch changes formatting and nothing else.
* chore: leave desktop/ out of this reformat
desktop-release-drift is right to refuse this. Everything under desktop/ is
built into Fleet Runner, so changing it means shipping: bump the version AND add
a FLEET_RUNNER_RELEASES entry, whose stated audience is 'person who installed
Fleet Runner and wants to know what changed'. For a whitespace-only build the
honest answer is 'nothing', so that release should not exist — and I should not
write release notes claiming otherwise.
I had bumped to 0.8.16 to get the gate green. That was the wrong direction:
publishing a build to three OS runners to keep a formatting PR quiet. Reverted.
desktop/ is excluded in .prettierignore with the reasoning recorded there, to be
formatted alongside the next real runner change, where the bump and the notes are
true anyway.
---------
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
* chore(ci): GitHub owner catomean -> bitbaum
* docs(hetzner): update _box-env.sh comments for the completed org migration
The GH_OWNER/WORKFLOW_OWNER comments described a future state (repos moving
to bitbaum while fleetcrown stayed personal) that sweep-gh-owner.sh just
made true, then obsolete: fleetcrown itself is in bitbaum now too. Comments
describing a plan that already happened are worse than no comment — they
send the next reader looking for a divergence that isn't there.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Y9rKLxddothnXEtY6KDziN
* chore(desktop): release 0.8.15 — the org-migration owner literals
Same shape as 0.8.14: desktop/ carries two literal owner references (issue
link, updater feed owner) that a fleet-wide rename touches, and
desktop-release-drift.ts correctly refuses to let that ship without a
version bump — a repo whose desktop app silently points at a dead update
feed is worse than one that fails the gate.
This should be the last time it's an account name: the org is the stable
home from here.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Y9rKLxddothnXEtY6KDziN
---------
Co-authored-by: Mao Nakamoto <41178744+maonakamoto@users.noreply.github.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Reliability (the paths the dogfood loop exercises):
- github-provision: AbortSignal.timeout on all three fetches (repo-create,
template-seed, deprovision) with the module's existing error envelopes —
a slow GitHub can no longer hang the new-project provision flow.
- x-oauth1: 10s timeouts on request/access token fetches — login fails fast.
- provision route: gitUrl + dirPath now land on user_projects in ONE update
(entity patch last) — a mid-flight crash can't leave a repo linked but
undispatchable.
- env health: warn-level GROQ_API_KEY check — the chat action-producer going
dark is now visible on /api/health instead of failing silently.
- Route-level error boundaries for /money /people /goals via a shared
RouteError component (extracted from the /system boundary — rule of three).
SSOT collapse (audit items 8a-8d):
- BUILDER_CHANNELS const in constants/statuses.ts; RunnerChannel /
BuilderChannel / PeekBuilderChannel now aliases; z.enum sites reference it.
- ORCHESTRATION_OUTCOME const-object; infer-outcome.ts comparison sites use it.
- One StatusTone (constants/statuses.ts); activity-status's colliding
EventStatus renamed; dispatch-status references the shared type.
- jsonOk/jsonError helpers in route-helpers.ts for new routes; CLAUDE.md now
documents the real { ok } / { error } envelope.
Docs + dead code:
- CLAUDE.md truth pass: Duet marked retired, Loki/Terminal/Activity added to
tree + Views table, magic contact count removed.
- Deleted: orangecat-context.ts (149L, 0 importers), 7 uncalled control-states
accessors, listPromptsForProject, updateBeaconChoice,
removeSubscriptionByEndpoint (push 410 cleanup already runs via
pruneDeadEndpoints — the audit's "never runs" claim was wrong).
- u/[username]: inline timeAgo → compactRelativeDate from lib/dates.
Tests: auth env fixture gains GROQ_API_KEY. 32/32 unit files, 150/150
test:home, tsc + eslint clean. Net −140 lines.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Tests (scripts/test/auth.ts, wired into pre-push): 13 framework-free,
DB-free assertions on the security-critical primitives — X 1.0a ticket
mint/verify/tamper/expiry/empty-secret, the env guardrail (whitespace
corruption, half-set provider pairs, missing AUTH_SECRET), password hash
round-trip. First real src/ test coverage.
Email canary (api/crons/email-canary, daily 06:00 via fc-cron timer): sends
to EMAIL_CANARY_TO and logs the outcome to debug_logs, so Resend key-rot /
domain breakage surfaces within 24h instead of when a user can't reset.
It worked on first fire: caught that prod EMAIL_FROM was Resend's test
domain (onboarding@resend.dev) — so ALL email to real users was silently
failing. Fixed on the box to the verified domain
(noreply@fleetcrown.orangecat.ch); canary now green.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>