You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(build): root the generated-module namespace at the project root so artifacts are byte-reproducible
Rspack writes module identifiers relative to the bundler context into the
emitted bundles (the // NAMESPACE OBJECT comments of concatenated modules).
The generated wrapper, route registry, and agent-bundle/meta modules were
served under the per-build staging root (.<output>.stage-XXXXXX/<target>/
.agent-bundle-virtual/), so every routed MCP entry carried the staging token
and two builds of one source differed in those files' sha256 and in the
manifest. The namespace now hangs off the project root, independent of the
output root, and a build-pool test builds one project twice into two output
directories and asserts identical manifests and bytes.
Make emitted artifacts byte-reproducible across builds: `agent-bundle build` now emits identical bytes — the same `agent-bundle.manifest.json`, the same per-file `sha256` — from two builds of one unchanged source tree, whatever `--output` names and however the per-build staging directory (`.<output>.stage-XXXXXX`) is named. The generated wrapper, route registry, and `agent-bundle/meta` modules every compiled surface imports are now served under the project-rooted `.agent-bundle-virtual/` namespace instead of under the staging root, so the module identifiers Rspack writes into MCP entries (`// NAMESPACE OBJECT: ./.agent-bundle-virtual/…`) no longer carry the staging token that made consecutive builds differ. This keeps install receipts, preview packages, and `doctor`'s bytes-at-rest comparison (`AB7326`) stable for one source revision. `agent-bundle inspect --bundler` shows the same project-rooted paths in each entry's virtual-module aliases and generated entry. (#PR)
0 commit comments