feat: eliminate deps/hyperlight-js git clone#13
Merged
simongdavies merged 1 commit intohyperlight-dev:mainfrom Mar 24, 2026
Merged
feat: eliminate deps/hyperlight-js git clone#13simongdavies merged 1 commit intohyperlight-dev:mainfrom
simongdavies merged 1 commit intohyperlight-dev:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR removes the need to manually git clone hyperlight-js by switching the runtime to a Cargo git dependency and re-pointing Node/Vitest/Docker paths to a deps/js-host-api location (backed by a symlink to Cargo’s git checkout).
Changes:
- Switched
hyperlight-js-runtimefrom a local path dependency to a git dependency in the sandbox runtime crate. - Updated Node scripts and Vitest tests to import/use
deps/js-host-apiinstead ofdeps/hyperlight-js/.... - Refactored
Justfilesetup/build flow to discover Cargo’s checkout, build the NAPI addon, and create thedeps/js-host-apilink; updated docs and Dockerfile accordingly.
Reviewed changes
Copilot reviewed 15 out of 16 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
src/sandbox/runtime/Cargo.toml |
Uses a git dependency for hyperlight-js-runtime. |
Justfile |
Removes git-clone flow; discovers Cargo checkout, builds NAPI addon, and symlinks deps/js-host-api. |
package.json |
Points @hyperlight/js-host-api to file:deps/js-host-api. |
package-lock.json |
Updates lock entries for new local file dependency path. |
tests/hyperlight-host-module.test.ts |
Updates import path to deps/js-host-api/lib.js. |
tests/fetch-binary.test.ts |
Updates import path to deps/js-host-api/lib.js. |
scripts/build-binary.js |
Updates hardcoded paths for .node and lib.js to deps/js-host-api. |
scripts/extract-hyperlight-builtins.ts |
Uses cargo metadata to locate hyperlight-js-runtime source in Cargo’s checkout. |
Dockerfile |
Copies deps/js-host-api instead of the previously cloned path. |
docs/DEVELOPMENT.md |
Updates setup instructions to remove clone wording and use just commands. |
README.md |
Updates just setup description to remove clone wording. |
CLAUDE.md / .claude/CLAUDE.md / .github/copilot-instructions.md |
Updates setup descriptions to remove clone wording. |
.github/workflows/pr-validate.yml |
Updates Docker build comment to reflect symlink-based deps. |
.dockerignore |
Removes now-obsolete explicit ignore entries for old deps paths. |
9bf8ebc to
88e6f84
Compare
Replace the manual git clone of hyperlight-js with Cargo's built-in git dependency resolution. The runtime's Cargo.toml now uses a git dep on hyperlight-js-runtime, and the NAPI addon (js-host-api) is built from Cargo's checkout at ~/.cargo/git/checkouts/ with a symlink at deps/js-host-api for npm file: dependency resolution. Changes: - Cargo git dep for hyperlight-js-runtime (was path dep to clone) - HYPERLIGHT_CFLAGS resolved via cargo metadata + Node.js one-liner - Justfile: resolve-hyperlight-dir discovers checkout, builds NAPI addon, creates symlink (no more fetch-hyperlight/git clone) - package.json: file:deps/js-host-api (was file:deps/hyperlight-js/...) - Scripts/tests: all paths updated to deps/js-host-api - extract-hyperlight-builtins.ts: uses cargo metadata to find source - Removed: jq dependency, build-with-runtime alias, dead PWD variable - Docs: all clone references removed, setup descriptions updated - Docker/CI: COPY path and comments updated for symlink pattern Signed-off-by: Simon Davies <simongdavies@users.noreply.github.com>
88e6f84 to
3c5987d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replace the manual git clone of hyperlight-js with Cargo's built-in git dependency resolution. The runtime's Cargo.toml now uses a git dep on hyperlight-js-runtime, and the NAPI addon (js-host-api) is built from Cargo's checkout at ~/.cargo/git/checkouts/ with a symlink at deps/js-host-api for npm file: dependency resolution.
Changes: