code-index-plugin-host cannot say which build it is — three of four shipped binaries answer --version, the fourth exits 21 with usage #262
Labels
No labels
code-review
correctness
dos
performance
security
severity/high
severity/low
severity/medium
tech-debt
Kind/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
h-dv/code-index#262
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Measured
Found while validating the new
install.shagainst the real publishedv0.27.1 release (not a fixture).
Reproduced on the current tree's
target/releasebuild as well, so it isnot a property of that release.
Why this is not cosmetic
Every release archive ships all four of these binaries. The plugin host
is the one that is separately executed, by the daemon, against a
module it is handed — and it is the only one an operator cannot ask what
it is.
That runs against the discipline #181 established.
answer_provenance.buildexists because an installed
0.26.1 (4555887)served pre-fix answersabout a tree sixty commits further on, and the crate version alone
compared equal throughout — the build hash is the load-bearing half.
daemon_buildextends the same comparison to the daemon that answers asession. There is no equivalent for the plugin host, and no way to
construct one from outside, because the process cannot be asked.
Concretely, a mixed install — four binaries from two different releases,
which is exactly what a partial install or a hand-copied upgrade
produces — is invisible for this one binary. The new installer refuses to
create that state (it stages all four and renames), but it cannot
detect a pre-existing one for the host, and neither can
doctor.Not claimed
I did not establish whether the host already reports a version over its
own protocol.
--self-reportappears in its usage as a flag to--serve, so a build identity may already cross the wire to the daemon;if it does, this issue is narrower — a missing CLI surface rather than a
missing fact — and the fix is correspondingly smaller. That should be
checked before the shape below is chosen.
Shape of a fix
--versionprintscode-index-plugin-host <version> (<hash>)andexits 0, in the spelling the other three already use — the installer,
doctorand any operator all parse the same shape then.the daemon can compare the host it just launched against its own
build and disclose a skew the way
daemon_builddoes.--version— derived from the archive's contents, not a list. Thepackaging step already names the four binaries it copies; that is the
population, and it is the same auto-detect-then-demand shape used by
the required-asset audit and by
installer_targets.rs.Point 3 is the one that lasts: a fifth shipped binary would otherwise
repeat this silently.
Anti-vacuity
A test that runs
--versionon four binaries and checks exit 0 issatisfied by a stub. It must assert the output contains the build
hash, and that the hash matches the one the other binaries report from
the same build — two binaries from one build agreeing is the measurement;
"it printed something" is not.
Related
#181 (which build answered), #182 (which tree), #245 (which generation),
#260 (an index behind the tree), #261 (pinning the installer).
Released in v0.28.1, build
340a75a, via #264 and #265. Release CI passed, including the Windows archive round-trip smoke test. The downloaded archive defines the executable population: all four installed binaries, including code-index-plugin-host, report 0.28.1 and the common build340a75a. The host ABI report carries the same identity. The exact-tag release smoke harness passed all 8 checks against the published Linux archive, including plugin execution and timeout/trap recovery; native Windows archive smoke also passed. Closing after public artifact verification.buildagent referenced this issue2026-09-11 20:25:15 +02:00