feat: implement java-tron-up runtime installer#9208
Open
ulissesferreira wants to merge 4 commits into
Open
Conversation
c1f756d to
aed775e
Compare
f125d72 to
52b6278
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
There are 3 total unresolved issues (including 2 from previous reviews).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 52b6278. Configure here.
- Parse .yarnrc.yml as YAML for global-cache detection - Merge partial fullNode/javaRuntime overrides with pinned defaults - Verify the cached Java runtime checksum on reuse - Unify the bin wrapper and propagate signals as a non-zero exit
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.

Summary
This PR stacks on #9207 (scaffold PR) and contains the real
java-tron-upruntime installer implementation.It replaces the scaffold template files with:
src/install.ts— core java-tron download, extraction, and installation logicsrc/bin/java-tron-up.ts— CLI entrypoint (wired viabinfield in package.json)src/index.ts— updated public exportssrc/install.test.ts— test suite for the installerREADME.md— full usage documentationCHANGELOG.md— initial changelog entryknip.config.ts— ignores thesysctlsystem binary (not an npm package)Together with #9207, this PR replaces #8825. PR #8825 should not be merged.
Verification
The following checks were run and passed:
yarn workspace @metamask/java-tron-up run build✅yarn workspace @metamask/java-tron-up run test✅yarn eslint packages/java-tron-up✅yarn constraints✅yarn workspace @metamask/java-tron-up run changelog:validate✅yarn dedupe --check✅Changeset vs scaffold branch
Only these paths differ from the scaffold base:
packages/java-tron-up/— real implementation (replaces template)knip.config.ts— addedignoreBinaries: ['sysctl']entry for this packageyarn.lock— minor updateNote
Low Risk
New dev/CI tooling package with no production wallet logic; downloads are checksum-verified and behavior is covered by tests.
Overview
Replaces the
@metamask/java-tron-upscaffold with a foundryup-style runtime installer: it downloads and caches pinned FullNode.jar (GreatVoyage-v4.8.1) and Azul Zulu Java (JDK 8 on x64, JDK 17 on arm64), verifies SHA-256 checksums, and installsjava-tron-up/java-tronbinaries undernode_modules/.bin.The
java-tron-upCLI supports defaultinstall,cache clean, and flags for cache/bin paths and per-platform URL/checksum overrides; options merge from rootpackage.json(javaTronUp/ aliases) and CLI, with partialfullNode/javaRuntimeoverrides merged into pinned defaults. Cache location follows.yarnrc.ymlYAML parsing and Yarn global cache (~/.cache/metamaskvs.metamask/cache), namespace-isolated underjava-tron-up. Thejava-tronwrapper propagates child signals as a non-zero exit; cached Java reuse is gated by a.source-checksummarker.Adds
yamldependency,knipsysctlignore, expanded README / CHANGELOG, relaxed Jest coverage thresholds, and a broadinstall.test.tssuite (mocked downloads, cache, config merge, wrapper behavior).Reviewed by Cursor Bugbot for commit a362e4a. Bugbot is set up for automated code reviews on this repo. Configure here.