midstreamer@0.3.1 is unusable as published — no "." export; main/module point at an unshipped dist/
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 147
- Forks
- 39
- Avg merge
- 16h 39m
- Merged PRs (30d)
- 2
Description
Summary
The published midstreamer@0.3.1 tarball cannot be imported by its advertised
default entry. main/module reference a dist/ directory that is not
included in the tarball, and the exports map only exposes the ./quic
subpath — so import 'midstreamer' throws ERR_PACKAGE_PATH_NOT_EXPORTED by
construction. The WASM temporal-compare / scheduling surface described in the
README is therefore unreachable from the published package.
Reproduction
mkdir /tmp/midstreamer-probe && cd /tmp/midstreamer-probe
npm init -y >/dev/null
npm i midstreamer@0.3.1
node --input-type=module -e "import('midstreamer').then(m => console.log(Object.keys(m)))"
# → throws ERR_PACKAGE_PATH_NOT_EXPORTED (or MODULE_NOT_FOUND for dist/)
Inspect the shipped files:
npm pack midstreamer@0.3.1
tar -tzf midstreamer-0.3.1.tgz
# → package.json, quic.js, and docs only — no dist/
Evidence
- Default entry broken as published.
main/modulepoint atdist/…,
but the tarball'sfiles/pack output contains onlypackage.json,quic.js,
and docs — nodist/. So the default import target does not exist in the
installed package. exportsmap only exposes./quic. There is no"."export that
resolves, soimport 'midstreamer'is rejected with
ERR_PACKAGE_PATH_NOT_EXPORTEDeven before the missing-file error.midstreamer/quicdoes load (loadQuicTransport,isQuicAvailable,
isNative, delegating to agentic-flow's QUIC stack) — but on a plain host
isQuicAvailable() === false(native transport absent), and the dependency
tree pulled in is large (~580 packages / ~2 GB viaagentic-flow@2.0.12),
which is a lot for a temporal-compare consumer that never needs QUIC.
Impact
Downstream consumers cannot use the advertised default surface (temporal
sequence comparison / scheduling). Our workaround was to depend on the focused
Rust crate midstreamer-temporal-compare (crates.io) instead, which is clean
and small — but the npm package should still ship its own dist/.
Suggested fix
- Ensure
dist/is built and included infiles(or the pack allowlist) before
publishing, and add a"."entry toexportsthat resolves to the built
entry (withtypes). - Consider splitting the temporal-compare surface from the QUIC/agentic-flow
transport so a consumer that only needs sequence comparison doesn't pull the
full 2 GB transport tree (e.g.midstreamer/temporalsubpath export, or a
lighter default with QUIC behind an optional peer dep). - A CI
npm pack+ fresh-install smoke test (import 'midstreamer'in a temp
dir) would catch this class of packaging regression.
Environment
midstreamer@0.3.1, Node 22.x, Linux.
---
_Verified against `midstreamer@0.3.1` on 2026-08-16: `npm view midstreamer exports` → `{ "./quic": "./quic.js", "./package.json": "./package.json" }` — no `"."` export, while `main`/`module` point at `dist/`._
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by inspecting package.json, its files or pack allowlist, main/module fields, and exports map, then run npm pack followed by the import probe in a fresh directory. Done means the published tarball contains the built dist/ entry, exposes a working "." export, and the smoke test imports midstreamer successfully; consider the suggested CI pack-and-install check separately.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, nodejs
- Domain
- build-system, ci-cd, release
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 65/100