Skip to content

Release 4.7.1 — mx update reports the version actually installed - #45

Merged
rousan merged 1 commit into
mainfrom
develop
Aug 28, 2026
Merged

Release 4.7.1 — mx update reports the version actually installed#45
rousan merged 1 commit into
mainfrom
develop

Conversation

@rousan

@rousan rousan commented Aug 28, 2026

Copy link
Copy Markdown
Owner

mx update reported the registry's advertised latest as the version it "updated to", trusting that npm i installs what npm view advertises and that exit 0 proves it. Behind a lagging mirror / virtual-repo proxy those disagree (registry advertises a version whose tarball it can't serve; npm i reinstalls the same version, exits 0) — so mx falsely claimed the upgrade and ran a pointless auto-sync.

Now it re-reads the actually-installed version via npm ls -g and reports that; updated is true only on a genuine upgrade (auto-sync skipped otherwise). A new staleRegistry state names both versions and points at a direct --registry https://registry.npmjs.org install. Adds installedVersion/staleRegistry to porcelain.

Bump 4.7.1.

mx update reported the registry's advertised latest (`latestInMajor`) as the
version it "updated to", assuming `npm i` installs exactly what `npm view`
advertises and treating exit 0 as proof. Those disagree behind a lagging mirror
or virtual-repo proxy: the registry can advertise a version whose tarball it
can't yet serve, so `npm i -g` reinstalls the same version and still exits 0 —
and mx claimed the upgrade (e.g. "Updated to v4.7.0" while 4.6.0 actually
installed), then ran a pointless auto-sync.

After the install, re-read the version actually on disk via `npm ls -g` and
report that. `updated` is now true only when a genuinely newer version landed
(so the auto-sync is skipped otherwise). When a newer version was advertised but
didn't install, surface a `staleRegistry` state that names both versions and
points at a direct `--registry https://registry.npmjs.org` install.

Adds `installedVersion` and `staleRegistry` to the porcelain output. Bump 4.7.1.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@rousan
rousan merged commit 1da9374 into main Aug 28, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant