mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-08-07 16:07:07 +00:00
The installer compares the agent binary it downloaded against the server that served it, stripping a leading "v" so "v6.0.4" and "6.0.4" match. It did not strip semver build metadata, so a server built from a working tree reporting "6.2.0-rc.8+git.46.g98a638e00.dirty" never matched the "v6.2.0-rc.8" agent it had just served, and the mismatch warning fired on every correct development install. This is the warning's whole job, so a false positive is expensive. It is the only client-side signal that a stale agent was downloaded, and because it always fired it read as background noise. That is exactly how a genuinely stale v6.0.5 agent was installed on a live host earlier today: the warning was there, above the install output, and looked like the one that always appears. Strip build metadata from both sides before comparing, keeping the prerelease suffix because 6.2.0-rc.8 and 6.2.0 are genuinely different releases. This is the same release-identity reduction the server applies when deciding whether a local agent artifact is fresh enough to serve; the contracts now state that one definition governs both ends rather than leaving each side to invent its own. Guarded by a test that pins both normalisation steps and exercises the comparison across the cases that matter: the dev-server shape that used to warn wrongly, the stale-download shape that must still warn, and a prerelease against its release. Verified to fail when either strip is removed. |
||
|---|---|---|
| .. | ||
| windowslifecycleserver | ||
| agent_state_dir_lifecycle_test.go | ||
| backfill_release_assets_test.go | ||
| build_release_assets_test.go | ||
| docker_entrypoint_test.go | ||
| install_docker_sh_test.go | ||
| install_ps1_test.go | ||
| install_sh_test.go | ||
| provider_msp_deploy_test.go | ||
| pulse_auto_update_test.go | ||
| release_ldflags_test.go | ||
| root_install_sh_test.go | ||
| uninstall_sensor_proxy_test.go | ||
| windows_agent_lifecycle.ps1 | ||