feat(launch): flip to the gateless launch (#151)
CI / ci (push) Canceled after 0s

Wayfinder map #148's terminal slice (decisions #150 architecture,
#149 UX variant A): every launch now opens straight into the
workspace. The engine check (hermes acp --check) runs async from
ContentView.task via AppGateState.startLaunchCheck — provisioning
(x3 profiles) and the daily backup auto-fire the moment it passes
(the gate era's exact onEnginePass chain, moved verbatim; once per
app-launch, first window only, no-op under hosted tests). Nothing
blocks: the blocking gate sheet, the placeholder logo screen,
gateRaised/gateDismissed, EngineGateView, and the
ProvisioningFailureCard sheet are deleted (net -350 lines with the
additions).

Engine state stays visible instead of interrupting: a 44x44 rail
pill above Archive (8pt pulsing accent dot while checking, warning
glyph on an accent-12% wash when failed, nothing at all once
healthy — the slot collapses and the rail spacing closes) and
mono-10 mentor-pane header states (checking... / engine missing /
setup failed / hermes <base> once ready — the BASE version, never
the gate's derived string; session chip renders only once ready).
Failure auto-expands an anchored floating card (340pt, accent
border — floats, never blocks): engine-missing carries #40's
install steps with the gateless correction plus Copy, guide link,
Re-check (disabled-while-checking), stderr + probed path;
provisioning failure rides the same card (failing profile named,
Retry inline). Focus mode recesses the card with the rail. Panes
spawn the engine the moment the check lands (.task(id: binaryPath)
on the nil->value arrival; a nil binary never calls openSession —
that path lands the crash card). state.json semantics unchanged
(About still reads it); #38's no-silent-degradation AC survives,
carried by the pill.

New GatelessLaunchTests pin the seam (hosted-test no-op, chain
armed, pill + mentor-header visibility mappings — flip-verified);
EngineGateTests byte-untouched and green; the dead deferFailure
(#48's Not-Now) deleted with its test. PRD G1 amended; gateless
DOX pass (Museion/AGENTS.md engine section rewritten); CHANGELOG;
devlog. The #149 prototype ships lint-clean.

Verified: full-scheme test 582 passed / 0 failed / 0 skipped
(xcresult executed count, unit + UI), swiftformat lint clean,
swiftlint 0 errors on touched files, finish-audit fanout clean
(ponytail/security/general; 5 fixes applied, header-mapping pins
flip-discriminated and restored).

Closes #151
Closes #139
This commit is contained in:
AlexKucera committed 2026-11-03 16:50:55 +01:00
1 parent 4065c31ec8
commit 55eff3a754
19 files changed
+1721 -384

No files matched your search

+53
View File
@@ -17,6 +17,10 @@ import SwiftUI
struct WorkspaceView: View {
@Environment(AppGateState.self) private var gate
@State private var selection: Pane = .posts
/// #151: the fail card's expansion — auto-expands on each failure
/// arrival (`.onChange` of the visibility); chevron collapses, slot
/// click re-opens.
@State private var statusCardExpanded = false
enum Pane: Hashable {
case posts
@@ -85,6 +89,24 @@ struct WorkspaceView: View {
}
}
}
// #151: the anchored fail card — floats over content, never
// blocks, never pushes layout (bottom-leading at railWidth + 12,
// bottom 14 — #149's geometry). Fail auto-expands; chevron
// collapses; slot click re-opens. Focus mode recesses the card
// with the rail (chrome recedes for deep work; the pill stays
// hover-reachable, and exiting focus restores the card — the
// expanded state survives).
.overlay(alignment: .bottomLeading) {
if statusVisibility == .failed, statusCardExpanded, !gate.isFocused {
EngineStatusCard(gate: gate) {
statusCardExpanded = false
}
.padding(.leading, DesignTokens.railWidth + 12)
.padding(.bottom, 14)
.transition(.opacity.combined(with: .move(edge: .bottom)))
}
}
.animation(.spring(duration: 0.3), value: statusVisibility)
.background(DesignTokens.background)
// #94: the ONE Origin ask per import batch. Dismissal without an
// answer (Esc/Cancel) drops the batch.
@@ -126,6 +148,15 @@ struct WorkspaceView: View {
}
// Collapsed floor: rail 56 + editor placeholder (export ≤920 layout).
.frame(minWidth: 480, minHeight: 320)
// #151: every failure arrival auto-expands the card — a fresh
// engine fail, a provisioning fail landing, a Re-check that fails
// again. Collapse is the reader's call (chevron), re-open the
// slot's.
.onChange(of: statusVisibility) { _, newValue in
if newValue == .failed {
statusCardExpanded = true
}
}
// #92/#94: the editor column lives in Posts — a guest buffer or an
// import's opened post surfaces there, whatever pane was showing.
.onChange(of: gate.posts.externalSession != nil) { _, isUp in
@@ -195,6 +226,15 @@ struct WorkspaceView: View {
)
}
/// #151: the pill/card state — the gate's phase machine plus the
/// provisioning failure verdict.
private var statusVisibility: EngineStatusSurface.Visibility {
EngineStatusSurface.visibility(
phase: gate.gateModel.phase,
provisioningFailed: gate.provisioning.hasFailure,
)
}
@ViewBuilder
private func paneContent(_ geo: GeometryProxy) -> some View {
@Bindable var gate = gate
@@ -221,6 +261,7 @@ struct WorkspaceView: View {
posts: gate.posts,
binaryPath: gate.gateModel.currentBinaryPath,
home: gate.museionHome,
gate: gate,
)
case .learnings:
// #26: list-only pane over <home>/learnings/ — read side;
@@ -271,6 +312,17 @@ struct WorkspaceView: View {
// #32: Trends after Learnings — measurement beside memory.
RailButton(pane: .trends, selection: $selection, label: "Trends", systemImage: "chart.xyaxis.line")
Spacer()
// #151: the engine-status slot above Archive (#149 variant A) —
// quiet-when-healthy: nothing renders once the engine answered
// and provisioning finished; the slot collapses and the rail
// spacing closes.
if statusVisibility != .hidden {
EngineStatusPill(visibility: statusVisibility) {
if statusVisibility == .failed {
statusCardExpanded = true
}
}
}
// #108: Archive at the rail bottom, above Settings (prototype's
// box icon).
RailButton(pane: .archive, selection: $selection, label: "Archive", systemImage: "archivebox")
@@ -280,6 +332,7 @@ struct WorkspaceView: View {
.padding(.vertical, 8)
.frame(width: DesignTokens.railWidth)
.frame(maxHeight: .infinity)
.animation(.easeInOut(duration: 0.2), value: statusVisibility)
}
}