fix: Bugbot findings from promotion PR #383 (summary copy + backfill hook docs) - #394
Conversation
…kfill docs) - Reboot note: only promise auto-restart when docker.service autostart was actually enabled; Tier 0 (zero-privilege) leaves it to the user, so be honest - Connected summary Data path: branch on TB_STORAGE_MODE — node-local keeps datasets in-node on k3s local-path, so don't point at a host /tracebloc - Backfill docs: correct values.yaml + values.schema.json to say post-upgrade ONLY (not post-install) to match the Job's helm.sh/hook annotation - Refresh scripts/manifest.sha256 for the summary.sh + cluster.sh changes Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 4c9875d. Configure here.
… state Bugbot: on Tier 0, ensure_cluster_autostart deliberately never runs `systemctl enable docker`, and TB_DOCKER_AUTOSTART was set only when *this* run enabled the service. A host where docker.service is already enabled on boot (a normal package install) therefore kept the flag unset, so _reboot_note told the user to start Docker manually even though the cluster returns on its own after a reboot. Seed TB_DOCKER_AUTOSTART from the current on-boot state via an unprivileged `systemctl is-enabled docker` read (matching only the persistent "enabled" state, not the transient "enabled-runtime"). Add cluster.bats coverage for the pre-enabled, disabled, and enabled-runtime cases; refresh manifest.sha256. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…-backfill # Conflicts: # scripts/manifest.sha256
…-backfill # Conflicts: # scripts/manifest.sha256
aptracebloc
left a comment
There was a problem hiding this comment.
@shujaatTracebloc — Approved. Clean set of honest-messaging fixes; the through-line (don't let the summary claim something untrue) is exactly right. I verified the load-bearing bits:
- ✅ Manifest hashes match for
cluster.shandsummary.sh(recomputed) — R8 trust root intact; both parse (bash -n). - ✅ The
TB_DOCKER_AUTOSTARTseed is correct.systemctl is-enabled dockeris an unprivileged read (no sudo prompt), the flag is set only on the persistent"enabled"state and before the tier logic, so it captures the common case (a normal Docker package install already enabled the service → Tier 0 still honestly promises auto-restart) and the sudo-enable path also sets it. It correctly excludes the transient"enabled-runtime"— and that edge is explicitly tested. - ✅ Tests are thorough and precise — the three new
cluster.batscases pin the seed exactly (already-enabled → set; disabled → not set; enabled-runtime → not set),summary.batscovers both reboot-note branches + both storage modes, andcopy-catalog.batspinsTB_DOCKER_AUTOSTART=1for deterministic rendering (mirroringTB_CLI_USABLE_NOW). (bats isn't installed locally — parse-checked + logic-reviewed; CI runs the suite.)
⚪ Nits (non-blocking)
- Socket-activation blind spot. The seed recognizes only
is-enabled docker == "enabled". A setup wheredocker.serviceis"static"butdocker.socketis enabled (on-demand activation) falls to the conservative "start Docker" message even though Docker may come up on first connection after boot. That's the safe direction (under-promise — the whole point of this fix), but a one-line comment noting it, or also checkingdocker.socket, would tighten it. TB_STORAGE_MODE=node-localis a flag-gated prototype (RFC-0003 Option C, not GA); the branch is correct and defaults tohostpath— just flagging it quietly adds summary surface for an unshipped path.
What's good
Every change makes a claim honest (post-upgrade-not-install scope, conditional auto-restart, real data location). The standout is the test coverage — every branch pinned, including the transient-enable edge that's easy to get wrong — and the manifest is kept in lockstep.
Touches @saadqbal's code-owned scripts/lib/ + manifest.sha256 (R8), so his code-owner review is the intended backstop; this is the second set of eyes. No blocking issues.
🤖 Generated with Claude Code

Resolves the second batch of Cursor Bugbot findings on the client promotion PR (#383, develop → main).
Fixes:
_reboot_noteunconditionally told Linux users tracebloc auto-restarts after a reboot, but the zero-privilege Tier 0 path inensure_cluster_autostartnever enablesdocker.service. It now keys off aTB_DOCKER_AUTOSTARTsignal (set only whensystemctl enable dockersucceeds) and, when autostart wasn't enabled, honestly tells the user to start Docker. (Release develop → main #383 (comment))Data /tracebloc/<ns>, but underTB_STORAGE_MODE=node-local(RFC-0003 Option C) datasets live in-node on k3s local-path with no host/tracebloc. The Data line now branches on the storage mode. (Release develop → main #383 (comment))values.yamlandvalues.schema.jsondescribed the metadata-backfill hook aspost-upgrade/post-install, but the Job is deliberatelypost-upgradeonly (a fresh install has no pre-cutover data; a cold image pull could fail the install). Corrected both to match the template'shelm.sh/hook: post-upgradeannotation. (Release develop → main #383 (comment))Goldens are byte-stable: the copy catalog pins the canonical full-install path (autostart enabled, hostpath storage), mirroring the existing
TB_CLI_USABLE_NOWpin; the new honest / node-local branches are covered bysummary.batsunit tests.scripts/manifest.sha256refreshed for thesummary.sh+cluster.shchanges.Lands on develop; the promotion PR head picks these up on the next sync and Bugbot re-reviews.
🤖 Generated with Claude Code
Note
Low Risk
User-facing copy and documentation corrections plus a read-only
systemctl is-enabledcheck; no change to cluster provisioning or Helm hook behavior.Overview
Addresses Bugbot findings from promotion PR #383: installer messaging and Helm values docs now match actual behavior.
Reboot footer (
summary.sh+cluster.sh) — Linux no longer always promises automatic restart after reboot.ensure_cluster_autostartsetsTB_DOCKER_AUTOSTARTwhendocker.serviceis persistentlyenabled(including Tier 0 installs where Docker was already enabled on boot, without runningsystemctl enable), and when a privilegedsystemctl enable dockersucceeds. Transientenabled-runtimedoes not set the flag._reboot_noteuses three paths: macOS/Windows → open Docker Desktop; Linux with autostart → restarts automatically; Linux without → start Docker first.Connected summary data line — When
TB_STORAGE_MODE=node-local, the footer shows Data in-node (k3s local-path) instead of Data /tracebloc/<ns>, since there is no host bind mount.Helm docs —
metadataBackfillinvalues.yamlandvalues.schema.jsonnow states the hook is post-upgrade only (not post-install), aligned with the template.Tests and copy-catalog pins cover the new branches;
manifest.sha256updated forcluster.shandsummary.sh.Reviewed by Cursor Bugbot for commit 9c9d740. Bugbot is set up for automated code reviews on this repo. Configure here.