Skip to content

Commit 388f41b

Browse files
committed
chore(welcome): replace vague "tracked separately" claim with explicit FIXME anchor
v0.9.5 review — PM P2. The comment at `welcome.ts:46` referenced a "pre-existing telemetry-init gap (tracked separately)" — a claim that implied a tracking issue existed. It didn't (verified by searching open issues on `AltimateAI/altimate-code`). Rewritten to: - Anchor the gap with `FIXME(telemetry-init-config-opt-out)` so it shows up in code searches. - Describe the exact failure mode: `doInit()` may run before `Instance.provide()` has made `Config.get()` resolvable — the catch branch in `telemetry/index.ts::doInit` proceeds with telemetry enabled, so a user who opted out via `telemetry.disabled` config (env var not set) can still have a machine-id minted on cold-start. - Explicitly note the env-var opt-out (`ALTIMATE_TELEMETRY_DISABLED` / `OPENCODE_DISABLE_TELEMETRY`) is unaffected — that check doesn't need Instance context. - Honestly state no tracking issue currently exists rather than repeat the earlier false claim. Pre-existing (not introduced by this release). Filed as part of the release/v0.9.5 deferred-items tracker.
1 parent 4759a75 commit 388f41b

1 file changed

Lines changed: 10 additions & 4 deletions

File tree

‎packages/opencode/src/cli/welcome.ts‎

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,16 @@ export function showWelcomeBannerIfNeeded(): void {
4343
// launch. Probe existence with existsSync only — do NOT mint here. Minting is left to
4444
// Telemetry.doInit() (its job, not the welcome banner's); the first_launch machine_id is
4545
// attached at flush time from telemetry module state, so it does not depend on minting here.
46-
// NOTE: doInit's early call runs before an Instance is available, so its CONFIG opt-out gate
47-
// fails open and it can still mint for a config-only opt-out user. That is a pre-existing
48-
// telemetry-init gap (tracked separately), not something this banner can fix — this code just
49-
// stops adding a SECOND minting site under an even weaker (env-only) gate.
46+
//
47+
// FIXME(telemetry-init-config-opt-out): doInit() may run before Instance.provide() has made
48+
// Config.get() resolvable (see the try/catch around Config.get in telemetry/index.ts::doInit
49+
// — the catch branch proceeds with telemetry enabled). A user who opted out via the
50+
// `telemetry.disabled` config key — with no env var set — can therefore still get a
51+
// machine-id minted on first launch. The env-var opt-out (ALTIMATE_TELEMETRY_DISABLED /
52+
// OPENCODE_DISABLE_TELEMETRY) is unaffected — that check does not need Instance context.
53+
// Pre-existing (not introduced by this release); calling it out explicitly here rather than
54+
// leaving the earlier "(tracked separately)" wording, which claimed a tracking issue that
55+
// does not currently exist.
5056
const machineIdPath = path.join(os.homedir(), ".altimate", "machine-id")
5157
const isUpgrade = fs.existsSync(machineIdPath)
5258
// altimate_change end

0 commit comments

Comments
 (0)