You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Addresses the findings from the review that fall inside this PR.
MAJOR — markSetupComplete() ran before the model-availability check
(dialog-provider). The branch below it deliberately refuses to claim success when
the gateway connects but offers nothing usable, and said so in a comment — but
completion had already been marked, so telemetry reported a finished onboarding
while the user was told to go pick a model. Now marked where the model is
actually set. This matters more since the scan gate moved onto the same signal.
MAJOR — the flushTimer leak. doInit() assigned a new interval without clearing
the previous handle, and shutdown() only ever clears the current one, so a second
doInit() stranded a timer for the life of the process. doShutdown also nulled
initPromise unconditionally, discarding a doInit() that init() had chained onto
the in-flight shutdown. Both fixed; see the note in doShutdown on why only the
first is covered by a test.
MAJOR — instance_connected and onboarding_abandoned could both be reported for
one launch. The gateway success events are emitted on the worker thread while
abandonment state is main-thread-owned, so a user who finished in the browser and
quit before the TUI observed the new provider was reported as abandoning at
gateway_auth. The exit path now checks whether credentials landed.
MAJOR — environment_scan_completed fired on every project_scan, including
/discover and any model-initiated call, so a funnel query could exceed 100%
conversion. Now guarded on isOnboardingSession.
MINOR — command.execute.before created a tracking record for every slash command
in every session, churning the capped map and evicting genuine onboarding
sessions, after which their remaining activation events were silently dropped.
noteCommandSubmission now only touches sessions already tracked, and
/onboard-connect marks the session before flagging its own submission.
MINOR — the cross-package event parity test that two comments claimed but which
did not exist. Now a compile-time assertion pinning the packages/tui event union
to the Telemetry variants; verified by renaming a property and watching the build
fail. Required exporting the context subpath from packages/tui.
MINOR — a raw HOME path could reach LLM-visible tool output on a sample-setup
failure. Paths are masked in `output`; the full message stays in metadata, which
the model never sees.
MINOR — documented why sample_setup_completed uses a success boolean instead of a
_failed sibling event.
NIT — launchId() no longer writes process.env. The worker receives the id
explicitly through WorkerOptions.env, so the write only leaked it into every
subprocess the CLI spawns.
Also removes the stray `// scratch` line at the end of cli/cmd/tui.ts.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_018SLUQF3xgZHsGZHSjxe7vb
0 commit comments