Repository navigation
Conversation
…resolves it --checkup wrote each hub import into a temporary root (import <path> as Hub) and loads that, so name lookup, fetching, hash checks and library confinement are the loader's own; the module keeps its hub namespace and its main becomes the root's main. A first parse with Base marked seen finds the module's file to see whether it imports Base, so Base is seeded as for local imports. The entry parameter through io_type, io_run, js_lib, book_main and book_run and the ns parameter of book_read go: comp.ts is unchanged, main.ts is +246 tokens over main instead of +608.
I pushed 67d6f8e on top of this PR. It keeps the behavior and lets the loader do all of the resolving:
Checks on macOS:
I left the README line and the ping test unchanged. |
|
I reproduced two confinement regressions in The synthesized root was loaded with the empty/local namespace. Fixed in cfd7b3d: mark the generated wrapper After-fix proof with real loopback HTTP package/name/manifest responses, source CLI and freshly compiled CLI:
The existing ping gate now contains two consumer regressions for traversal/continuation and named-cache symlink confinement. I ran the exact assertion block against the freshly compiled CLI (all three hub checks pass) and the repository gate passes 54/54. README documents the boundary. Full private-site installer ping, the mini cluster and macOS were not run here. |
Current-head review qualification
Head
cfd7b3d8preserves the maintainer's generated-root refactor and fixes its reproduced traversal/symlink regressions. Both the initial parse and checked load use a hub-owned wrapper namespace so the existing loader's library-confinement checks apply. Protectedbend.tsand compiler APIs are unchanged; no resolver/name/hash-cache copies or token-cap changes were added.Before
67d6f8e4: both0x<hash>/../../outside.bendand a cached entry symlinked outside the library executed the outside file (99n, exit 0). After: exit 1 and no outside output, while a later valid named IO import still executes. Cold hash/named loads use real loopback HTTP manifests and SHA verification. Warm hash, local IO, a no-main library, failure continuation, independent Base scope and SHA-mismatch rejection were exercised with the source CLI and a newly compiled CLI. Temporary roots were removed after success and failure.The exact existing/new ping hub-consumer assertion block passed against this compiled CLI; repository gate 54/54. The full private-site installer suite, mini cluster and macOS were not run here. The older proof below is retained as historical qualification, not represented as a rerun on this head.
Fixes #1499.
--checkupcurrently turns a documented content-hash or named hub import into a file beside the aggregation. The ordinary checker/runner resolves the same cached package and returns5n; independent checkup instead fails with ENOENT.Resolve package names using the existing public name/version grammar, name-cache layout and immutable hash lookup protocol. Hand acquisition and manifest/file digest verification to the unchanged loader. Keep the module's hub namespace while parsing/checking, then select its actual pure or IO
main; the shared JS generator now accepts an explicit entry root rather than only rootingmain. Ordinary CLI, JS and module entry defaults remain unchanged. Reuse checked Base when source is already present, but do not inject Base into a module that did not import it. Cache confinement is checked before executing an entry.The permanent installed-CLI consumer uses the gate's existing manifest hash helper to create a valid isolated cache: one content-hash pure entry returns
5n, and a different named effectful entry actually printshub-io. The exact new assertion fails against unchanged main and passes against the genuinely rebuilt standalone CLI. No wiring/source-shape/diagnostic-text assertion. README documents independent hub scope.Actual Linux x64 evidence:
5n; named imports resolve and executehub-io. This is local HTTP protocol proof, not a claim that a test package was published to the public hub.bun gates/repo.ts: 54/54.The human-written bend2/bend.ts, GUIDE, CHANGELOG, kernel, gate policy and permanent token limits are untouched. Full installer/archive/hub ping was not run because the sibling site checkout is unavailable; executing its new assertion is not a claim that the complete gate passed. No GPU/platform qualification.