Independent default app npmtest killed the chatty optimize child at 614ms
because the 600ms idle timer started at spawn and the first progress byte
waited on Node boot plus setInterval. Emit the first stderr byte immediately
after boot, then ten 400ms ticks (result ticks 11) under a 2s silence budget.
Node boot still counts; the larger smoke window absorbs it. Work still
outlives a fixed total-runtime cap. Production already resets on every byte;
timeout constants unchanged.
An audit of everything on main since v0.9.23 turned up five places where
real detail had been used where an invented value would have done. None of
them is a credential and none identifies a customer, but a public
repository is the wrong home for any of it.
perf/README.md cited an absolute path into a private audit workspace on a
contributor's own machine, naming their home directory, the workspace's
naming scheme and a run timestamp accurate to the second, as "evidence" no
reader can open. The number stays; the path goes, and the text now says
plainly that the artifact is not published. The same file described the
measurement corpus as the founder's 35 GB of session history, which is a
personal fact about one identifiable person, so it is now described by what
it is rather than by whose it is.
The remaining three are fixtures: a private product name as a working
directory, the maintainer's real operating-system username inside the very
tests that assert such a path is redacted, and their two machine names in
the sharing tests. Using the real values proved nothing the invented ones do
not, and the redaction tests read better when the string being scrubbed is
obviously synthetic.
The rename retry landed, but its test kept the watcher reading in a
tight loop, and on real Windows that lost 8 runs in 12: a reader holding
the file open every instant is a race no bounded retry can win, because
an open handle blocks a rename until it closes. That is not a reader
either app has. The watcher now polls at 1ms, which still samples the
file thousands of times and still catches a lost update, while leaving
the writers room to rename. The locked path passes 15 of 15 on Windows,
and the unlocked path still reports a rolled-back write.
Also restores the lineage case the review asked for: a refresh where the
account id and refresh token are unchanged and only the id_token subject
moves, so the subject comparison is what discards the write. Both copies.
The Windows CI leg failed on the cross-process test with EPERM from
renameSync. It is not a test artifact. Windows refuses a rename over a
file another process holds open rather than waiting, with
ERROR_ACCESS_DENIED or ERROR_SHARING_VIOLATION, and reads of these two
files are deliberately lock-free on both sides. So any tray or app read
that overlaps a writer's replace fails that write, and since this branch
made writers report a failure instead of swallowing it, the outcome is
exactly the lost update the lock exists to prevent, reached by another
route. The test's reader thread only made it visible by reading the way
both apps really do, continuously and without the lock.
The replace is now retried on that error class, ten attempts about 20ms
apart, on both sides: replace_file in settings.rs, used by settings patch
and by the dock's write_state_at, and renameOnto behind writeFileAtomic
in tray-settings.ts. The lock is already held at that point, so the wait
can only ever be on a reader, never on another writer, and a read of one
of these files is microseconds of open file. Once the budget is out the
original error is returned unchanged and the caller cleans up as before.
On POSIX, where a rename over an open file cannot fail this way, it
compiles out in Rust and short-circuits on process.platform in Node.
Reads stay lock-free, which is the right trade and the reason the files
can be read at all without coordination; both read paths now say what it
costs and where that cost is absorbed. The reader thread stays as it is,
and is now the regression test for the retry as well: it is what puts a
replace under a continuous reader.
The retry itself is covered on the Node side by faking the platform and
the rename, since a rename that fails this way cannot be produced on a
Mac: a reader waited out and the write landing, the budget running out
with the old file still whole, and an error a reader cannot cause not
being waited out at all. The Rust half is compiled out off Windows, so
CI is its only proof.
writeDockEnabled still did its own read, mutate and atomic write of
windows-dock.json, outside the lock the rest of the module takes. It is
the Node side of the dock's enabled switch, reached from the desktop
app's Sidebar toggle, so a toggle there could still land between the
tray app's read and its rename and erase whatever it had just stored,
which in practice is the rail's placement. It now merges through
patchTrayFile, which takes the lock for the whole cycle; enabled is
already an accepted dock key, so nothing is dropped on the way.
Stale-lock recovery could hand out two owners at once. Both sides did
"if abandoned, unlink and retry", and nothing stood between the check
and the unlink: contender A could already have removed the stale lock
and created a fresh one of its own, and B's unlink then deleted A's
fresh lock, leaving both of them holding the file. Windows' share mode
hides this most of the time, because a lock a live holder still has open
will not unlink at all, but the same protocol runs on Linux and macOS,
where the unlink always succeeds. Removing an abandoned lock is now
itself arbitrated, by the same exclusive create the lock uses, on a
sibling <lock>.takeover file. Only its winner may unlink, and only after
re-checking staleness under that right, so a rival that reclaimed first
keeps the lock it now holds. A takeover file is dropped on every path
out, never held across the wait, and one left behind by a reclaimer that
died is freed by the same staleness rule as the lock itself.
The cross-process test asserted only each side's final value, so it
noticed a lost update only when the last writes happened to collide: on
a deliberately broken lock it passed about one run in three, which is
weak evidence for the property it exists to prove. Each side now writes
a counter that only rises, and a reader thread watches the file for the
whole run. A separate reader is the point: neither writer can see its
own counter rolled back, because in the unlocked cycle each carries the
other side's value forward itself, so what it reads back is never older
than what it last read. With the lock both counters only ever rise in
the file; without it one falls. It now fails on every unlocked run.
Also: a placement that cannot be saved is logged instead of discarded
silently, since losing the lock under contention is a new way for the
rail to revert at the next launch; and the Codex sameLogin comment now
states outright that a replacement document carrying none of the three
identifying fields reads as the same login and is written over, which is
the deliberate side to err on.
The desktop app and the tray app both read, merge and rename the same
preference files. The atomic rename stopped a torn file but not a lost
update: both read state A, each changed a different field, and the last
rename erased the other's change, so dock placement, enabled state,
provider choice or scale silently reverted.
One cross-process lock now covers the whole read-modify-write cycle,
designed once and implemented in both Rust and Node against the same
protocol: a sibling .lock file taken by exclusive create, carrying the
holder's pid and timestamp, taken over only when abandoned by a dead pid
or a stale mtime, and failing loudly rather than writing behind a live
holder. It follows the CLI's existing cache-refresh lock. All three
sites use it, including the dock's enabled, provider and placement
writes. A test drives real Node and Rust processes at the same file and
fails without the lock.
The refresh reread auth.json before writing the rotated tokens but only
checked it was still ChatGPT mode, not that it was still the same login.
A `codex login` account switch, or a second CodeBurn process refreshing
the same credential, landing while our refresh was in flight let the late
response splice one account's tokens into another's document: a new
account id over an old refresh token, or an older refresh token over a
newer one. Either signs the user out or binds them to the wrong account.
The login the grant belongs to is now captured before the grant and
compared against the reread document on account id, refresh token and
id-token subject. A demonstrated mismatch discards the write and says so.
An unreadable or key-sparse file is not a mismatch and still writes, so a
rotated token is never dropped. Both the CLI and the Electron copy.
The onboarding screen, the privacy settings and the README each said the
daily report includes the names of the models, tools, skills and MCP
servers in use, and then in the next breath that it never includes
anything identifying. A server named after an employer is identifying,
so the second half was not true. All three now use the wording the tray
notice already had, which names what is withheld rather than claiming
more than the product does: never your prompts, your code, or your
project and file names.
The reboot-pending flag lived in memory with a comment claiming the
restart it waits for also clears it. Quitting the desktop app and
opening it again cleared it too, and that is not the restart being
waited for, so the next launch started the old tray binary under the new
version's name, which is the confusion the flag exists to prevent.
It is saved as a timestamp now and read back by comparing it against
when Windows last booted, so only a real restart clears it. The test
that asserted the old behaviour crossed the boundary by restarting the
app; it now moves the boot time, and a second test covers restarting the
app without restarting Windows.
- Tray preference patches from the window were used with `in` before
any type check; every patch handler now refuses anything that is not
a plain object.
- The tray install passes `--staged-msi <path>` to the CLI instead of
an environment variable.
- A timeout or a missing CLI no longer counts as a declined install,
so it is retried at the next launch; only a cancelled prompt is
remembered. After msiexec reports a pending restart the old binary is
not launched, and the sidebar says a restart finishes the install.
- The telemetry opt-in event fired before the toggle was applied and
could never be sent; it fires after a successful write.
- The ARM64 installer carries the x64-named tray, since the CLI accepts
only that asset name; the distribution notes say so plainly.
- The README, the onboarding screen and the privacy settings say that
the daily report includes the names of the models, tools, skills and
MCP servers in use, and the renderer's fallback builder reports zero
turns as zero.
The daily usage_snapshot event now carries the payload's
telemetrySnapshot verbatim, with the old renderer builder kept as the
fallback for an older CLI. Five name-only events join it: optimize_apply
with the fix kind, plan_set with the provider, export with the format,
compare_view with the two models, and settings_change with the setting
and its enum or boolean value.
The props sanitizer had allowed one level of arrays of flat objects and
would have stripped the snapshot's nested model and task rows; it walks
plain objects recursively now, five levels deep at most and a thousand
leaves per event, leaves still short strings, finite numbers and
booleans only. The README gains a Telemetry section listing every event
and field and how to turn it off.
7-Zip compresses ARM64 executables with its ARM64 branch filter by
default. The decoder inside the NSIS installer predates that filter, so
extraction dropped every .exe and .dll while the data files landed, and
the installer exited zero with no program in the directory. A new
package:win:arm64 script pins the BCJ filter through the electron-builder
override, and the distribution notes say why.
The Run value was seeded once per machine. Uninstalling the desktop app
removes the tray and, with it, the Run value; reinstalling put the tray
back but the seeded flag survived in the companion settings, so launch
at login was silently off afterwards. A tray app the current launch has
just installed now seeds the value as a first run does.
Two faults in the uninstall hook, found by running it for the first time:
- NSIS has no doubled-quote escape, so the '' written for PowerShell's
single quotes ended the NSIS string at the first one. The plugin got a
truncated command PowerShell could not parse, and the hook silently
did nothing: uninstalling the desktop app left the tray, its Run value
and its marker behind. Each inner quote is now the NSIS escape.
- An upgrade runs the previous version's uninstaller first, with the
updated flag, and the hook removed the tray there too, so every desktop
upgrade uninstalled the tray and reinstalled it with an elevation
prompt. The hook now leaves the tray alone during an upgrade.
The Store package is signed at submission and updates itself. The tray
.msi under windows-v* and the desktop setup exe are a developer preview:
unsigned, SmartScreen warns on first run, and they do not update
themselves; the tray app reports a newer version and links to it. Said
in the README, the distribution notes, the tray development notes and
the release body.
companionDataDir only honoured LOCALAPPDATA when it began with a drive
letter, so the POSIX sandbox path the test hands it fell through to the
home fallback on Linux and macOS. It now takes any absolute path in the
Windows sense, which a drive path and a rooted path both are. The
launcher expectations join with the host separator instead of spelling
out backslashes, so the same assertions hold on every runner.
- The tray resolves codeburn from PATH and the npm locations and never
saw the CLI the desktop app bundles, so a machine with only the
desktop app had a tray with nothing to run. The desktop app now writes
a launcher that runs its bundled CLI through its own executable,
records the path in the tray settings, and the tray's resolver takes
it after PATH and before giving up; a global codeburn still wins. The
first launch also gets CODEBURN_BIN in its environment.
- Four IPC handlers for tray preferences and launch at login had no
platform check and would have touched Windows files or reg.exe on a
Mac; they return neutral values off Windows.
- The install probe ran on every launch and a declined UAC prompt came
back at the next one. A declined or failed staged version is recorded
and not retried until the version changes or the user flips the
switch, and a matching installed version skips the probe.
- Launch at login in the Store build is managed by Windows through the
package's startup task; the switch said otherwise and did nothing.
That build now says so and opens the Startup Apps page.
- Settings files the tray reads were truncated and rewritten in place;
they are written to a temp file and renamed over.
- DISTRIBUTION.md records that the installer's staged tray and the
windows-v* release asset at the same version are separate builds.
The tray switches took the sidebar corner on Windows and the social
links moved to About, but the switches render nothing off Windows, so
Mac and Linux users lost the row and gained nothing. The links are back
there on every platform but Windows.
taskkill only ran for children spawned through the .cmd shim, and the
shipped desktop build runs the bundled CLI through Electron's node, so
it never ran at all and provider subprocesses were orphaned on every
stop. On the shim route it was also fire-and-forget followed by killing
the top of the tree, which reparents the children before taskkill can
find them. Every Windows child now goes through taskkill /T /F from
System32 and the handle is only ended if taskkill fails.
The desktop app's Codex quota reader is a copy of the CLI's and carried
the same fault: two await points between parsing the token grant and
writing auth.json, a rotated refresh token dropped when the grant had no
access token or the file could not be re-read, a silent failed write,
and the caller's abort passed into the grant request. Ported the CLI
fix so the two files match apart from import specifiers.
Tauri names the bundle after productName, so `tauri build` leaves
`CodeBurn Menubar_<version>_x64_en-US.msi` with a space. GitHub rewrites
that space to a dot on release upload, which is the form the CLI
installer, the Electron side and the tray updater all match. The staging
script only knew the dot form, so the installer workflow built the tray
and then failed with "no CodeBurn.Menubar_<version>_x64_en-US.msi".
It now accepts both and stages the dot form, so a local build and a
downloaded release produce the same shape.
The single-instance plugin hands a second launch over with a synchronous
SendMessage, so that launch sits inside it until the running app's callback
returns. When the message landed while the first launch was still in setup,
the callback showed the dock from inside a nested message pump, waited on an
event loop that was not running yet, and never returned; every launch after
it, the desktop app's --quit included, blocked behind the same message and
piled up as processes with no windows.
The callback now only records the request and carries it out from the event
loop. The desktop companion also waits, briefly, for a quit it has just sent
to finish before starting the tray app again, because a launch that arrives
while the old process is still going hands its request to that process and
exits with it.
hasUsage is a new payload field, so every RELEASED CLI omits it. Both decoders
treated the absent case as "derive from cost", which is the strict reading of
a field that is not there: a provider with $0 spend in the period vanished
from the picker even though the user has it and is actively using it on an
included subscription.
Absent now means visible on both surfaces. The strict signal still applies
wherever the CLI actually emits the field, so an explicit false still hides an
idle discovery row. Settings.tsx carried the same fallback and is fixed with
it.
The plugin runtime has not shipped for Windows, so `codeburn plugin list` never
answers there and the section sat on "Loading plugins..." for as long as the app
was open. A spinner that will never stop is worse than a sentence.
Windows now gets a panel instead: the section's own glyph, one line saying
plugins are coming, and one saying they arrive in a later Windows release and
work today elsewhere. It loads nothing, and the check happens in a dispatcher
above the loader rather than inside it, so the loader's hooks never mount and
there is no CLI call, no spinner and no timer to unwind. Every other platform
renders exactly what it did.
The desktop app's stderr on the VM carried "Antigravity quota unavailable:
Command failed: ps -ax -o pid=,command=" with "ps: unknown option -- x" on every
quota poll. Windows has no ps, and asking for one is a spawn failure rather than
an answer, so the provider reported a transient failure with a warning behind it
instead of simply not being there.
Win32_Process is the same listing by another name, and it is already how
src/providers/antigravity.ts finds these servers, so the quota adapter asks the
same way: PowerShell by absolute System32 path, argv only, no shell string, and
the Where-Object is a prefilter rather than the decision, which classifyProcessLine
still makes. There is no lsof either, so a pid's listening ports come from
netstat -ano; its state column is localized, so it is not matched on, and a row
that turns out not to be listening only costs one refused probe.
The guard this replaces was `win32 && !deps.execFile`, which the desktop app
defeated by injecting execFile, and which its own copy of the adapter never had
at all. Both copies now carry the same code, and the platform is injected so
either branch can be tested from either OS.
The tray app has a settings window of its own, and nobody should have to find it
to change how the thing in their notification area behaves. Two panes join the
Settings rail: Menu bar and Capacity Dock.
Only the settings the desktop app does not already have are there. Currency, the
period, the scope and the daily budget are shared through the CLI config and
already live in General, and repeating them would be two controls for one value.
So Menu bar carries the tray figure's metric and period, the accent, whether
today's figure gets its own tray icon, the two refresh cadences, the terminal and
launch at login; Capacity Dock carries show, resting provider, size, appearance,
gauge shape and the per-provider switches.
Each pane appears only while its switch in the sidebar corner is on: there is
nothing to configure about a tray app that is not running, and the rail is one of
its windows. A pane whose switch has just gone off cannot stay on screen either,
so the rail falls back to General.
Two things the rail's own rules are worth restating here. The last connected
provider cannot be switched off, because the rail must never have nothing to
show. And a provider stays in the list after its connection drops, so one that
has stopped working can still be taken off.
Every control renders what came back rather than what it sent: the main process
is what decides the value that lands, and it repairs one it would not be able to
read later.
The tray app keeps its preferences in two files it reads from Rust before any of
its windows exist, so those files are the interface rather than any running
process: windows-settings.json for what only it cares about, windows-dock.json
for the Capacity Dock. The desktop app can now read and write both, which is
what lets its Settings carry the tray app's own panes.
Every write is a merge. Both files hold keys this side has no business touching,
the rail's placement above all, and a whole-file write would take them with it.
And every value is checked against the same closed set the tray app parses it
with: a value it cannot read collapses to a default there, so sending one would
silently lose the setting rather than store it. The check is also what keeps a
renderer from reaching a key it was not offered.
Two rules come with the dock file. Writing the provider set latches
manualSelection, because editing the set by hand is what stops the tray app
seeding it from whatever is connected. And a set that no longer holds the
resting provider moves it, since the rail can only rest on a row it is showing.
Showing the rail is the Sidebar switch under another name, so it goes through
that path rather than straight to the file, and keeps the rule that the rail
cannot outlive the tray app. Launch at login is the one setting that is not in
either file: it is the Run value, which this app already owns.
After every write the running tray app is nudged with --reload-settings, which
makes it re-read both files and broadcast to its own windows. With the tray app
off there is nothing to tell and the files are enough.
They start real children and then wait for the OS to report them gone. Under the
whole suite, fifty files at once, that wait outran the five-second default often
enough to fail on a busy machine while nothing was wrong. Same reason and same
headroom as the resident-serve block.
The rail is a window of the tray app, and every setting it renders from belongs
to the tray app, so a Sidebar that is on while the menu bar app is off describes
something that cannot exist.
Turning Menu bar off now turns Sidebar off with it, and writes enabled: false
into windows-dock.json before sending --quit, so what the tray app finds the next
time it starts is the state the switches are showing rather than a rail that
comes back on its own. Turning Sidebar on with Menu bar off turns Menu bar on
first, installing and starting the tray app and writing the Run value, and only
then enables the rail; if the tray app cannot be turned on there is nothing for
a rail to live in, and both switches stay off.
In the corner the Sidebar switch is disabled while Menu bar is off, with a title
saying why. That is the primary guard, and the cascade above is what answers a
request that arrives any other way: through the IPC channel, or from a settings
file that already disagrees with itself.
The stored path is a memory, not a fact. It was written by a build that derived
the binary name from the product name, so on this machine it named a file that
has never existed, and the switches sent --quit and --reload-settings into it
while the desktop app's own stderr said ENOENT. A tray app uninstalled after the
path was stored gets to the same place.
So nothing is launched, and no Run value is written, without checking the file
first. A stale stored path is re-resolved through the CLI rather than trusted,
which costs one `codeburn menubar`: it re-reads the uninstall registry and
installs nothing when the version already matches. A path the installer reports
but nothing is at is refused rather than saved, since saving it is what made the
switches silently do nothing.
Launch at login gets the same treatment. The rule is still that an existing Run
value is not this app's to rewrite, with one exception: a value pointing at a
file that is not there is not somebody's preference, it is the old wrong path,
and it would fail silently at every login. That one is repaired.
While here: a byte order mark no longer makes the settings file unreadable.
Falling back to the defaults means seeding again, which reinstalls the tray app
and re-enables the rail, and a BOM is what anything editing that file by hand on
Windows leaves behind.
They start several real node children each, and the suite runs fifty files at
once, so two of them intermittently hit the five-second default while the
machine was busy rather than while anything was wrong. Nothing here asserts how
fast a child answers, only which one does.
Windows has no shebang. CreateProcess starts executables, and both shapes a
codeburn install takes here are scripts: dist/cli.js in dev, and the codeburn.cmd
that a global npm install puts on PATH. Spawning either with shell: false is
EFTYPE, so nothing the desktop app ran ever ran on this platform. The throw came
out of startServe inside whenReady and took the rest of it with it, which is why
`npm run dev` never even opened a window, and why 49 of this file's own tests
failed here.
Each script now gets a runner that can start it. A .js goes through this
process's own binary as Node, the same shape the bundled CLI already used. A .cmd
goes through cmd.exe as one command line, because that is the only way to start
a batch file, and the line is built rather than handed to shell: true, which
does not escape anything: two parsers read it, cmd first and then whatever splits
a command line back into argv, and a .cmd re-expands its own arguments through
%*, so the arguments are escaped for both readings. That is cross-spawn's rule,
restated here rather than depended on, since the main process ships no npm
dependencies. An .exe and a POSIX codeburn are spawned exactly as before.
Two things follow from the cmd.exe route. The PATH lookup asks for codeburn.cmd
before bare codeburn, because npm writes both into the same directory and the
bare one is a shell script Windows cannot start. And killing such a child means
killing the tree: the shim exits as soon as it has started node, so the handle we
hold is the shim's, and taskkill /T is what reaches the generation below.
Five tests do not run on Windows now rather than failing there. They assert
catchable SIGTERM: a grace window, a cleanup handler, a child that ignores the
first signal, a resident closing its own stdin. child.kill on Windows is
TerminateProcess, so those are things the platform does not have rather than
things this code gets wrong, and the POSIX expectations are untouched. Three
assertions that hard-coded ":" as the PATH separator now use the platform's.
The first run wrote enabled: true into windows-dock.json and wrote the tray
app's Run value, whatever was already there. On a machine where somebody had
installed the tray app by hand and deliberately turned the rail off, or turned
launch at login off, installing the desktop app quietly undid both. A default
is an answer for a question nobody has answered, not an override of one that has
been.
So the seed now looks first. An existing enabled value is left exactly as it is
and mirrored into the Sidebar switch instead, so the corner opens saying what
the rail is actually doing rather than what this app would have preferred; only
an absent key is seeded. A file that exists but has never mentioned the rail
still counts as no answer, which is the case for anyone who has only ever
dragged the rail somewhere.
The Run value follows the same rule and, like the rail, is only ever touched on
the first run. After that it belongs to whoever changes it: the tray app's own
launch-at-login toggle, or the Menu bar switch here, which still writes it on
and deletes it off.
stage-menubar.mjs is stage-cli.mjs for the Tauri tray app: it copies rather than
downloads, taking the local `cargo tauri build` output by default and whatever
CI fetched with --from. The two routes need different things staged, so it has
two shapes. The NSIS build gets the .msi and its .sha256, computing the digest
when a local build has none, so the installer's verification means the same
thing there as it does for a release. The Store build gets the executable, since
a packaged app cannot run msiexec at all.
build/menubar rides into both packages as win.extraResources. Unlike the CLI it
carries no node_modules, so electron-builder's production-dependency filter has
nothing to strip and the afterPack hook is not needed.
installer.nsh removes the tray app on uninstall only when the marker credits
this app with installing it, which is what keeps a manual `codeburn menubar`
install alive through a desktop uninstall. PowerShell reads the marker and pulls
the product code out of the uninstall string, because NSIS has no JSON and the
alternative was hand-parsing one in a macro.
appx-extensions.xml declares the tray app's launch at login as the package's own
windows.startupTask, so it appears in Settings > Apps > Startup like anything
else the Store installed. No Run value is written on that route.
The sidebar's bottom corner held About and a row of five brand glyphs. The
glyphs were the least useful thing on that screen: they are visited once, and
About already listed every one of them under Links. So they are only there now,
and the corner carries the two things a Windows user does want at hand: whether
CodeBurn sits in the notification area, and whether the Capacity Dock rail is on
the screen edge.
Both are on by default and neither renders at all until the main process says
this build has a tray app staged, which is why there is no placeholder row and
no greyed-out switch: on macOS, on Linux, and in a dev build with nothing
staged, the corner is exactly what it always was.
The switch is the shared one from Settings and onboarding, at 30x17 rather than
38x22 because a 186px sidebar has no room for the full size beside a label, and
keyed off the theme tokens rather than the white overlays the bare shape uses on
the dark onboarding sheet.
Installing the desktop app should give a person the tray icon and the Capacity
Dock without their ever learning that `codeburn menubar` exists. So it carries
the matching windows-v* build and puts it there itself, at first launch and at
every launch after, which is also what covers a desktop-app update: the staged
.msi travels with the app.
The install itself is not reimplemented here. The CLI already owns the registry
read, the checksum, the msiexec call and the never-downgrade rule, so this side
stages the file, names it in CODEBURN_MENUBAR_MSI and reads the one JSON line
that comes back. What it does own is the tray app's process and its Run value,
because the two sidebar switches have to be able to stop and start it: the tray
app is reached through its own argv, --quit to stop and --reload-settings to
make it re-read the dock preference this module writes.
The Store route shares almost none of that. msiexec is not available to a
packaged app and would fight the package manager anyway, so the tray exe ships
inside the package and is launched from there, and no Run value is written
because the manifest's own startup task covers launch at login.
Two rules worth naming. The defaults are seeded once, so a person who later
turns the rail off in the tray app's own settings does not find it back on at
the next launch of this one. And every setter answers with the whole status
rather than an acknowledgement, so a switch shows what took: an install
cancelled at the UAC prompt leaves it where it was.
The Electron Settings pane still filtered on cost, the exact gap this
change exists to close; it now reads the hasUsage field the payload
carries, falling back to cost for older CLIs.