Skip to content

chore: use 'just' instead of 'npx nx'#2196

Merged
sergeytimoshin merged 10 commits into
mainfrom
sergey/just
Jan 22, 2026
Merged

chore: use 'just' instead of 'npx nx'#2196
sergeytimoshin merged 10 commits into
mainfrom
sergey/just

Conversation

@sergeytimoshin
Copy link
Copy Markdown
Contributor

@sergeytimoshin sergeytimoshin commented Jan 21, 2026

Summary by CodeRabbit

  • Chores
    • Migrated build and test workflows from Nx to a Just-based workflow across the repo, adding root-level convenience targets for build and test.
    • Removed several legacy package manifest files and associated Nx build-output configs.
    • Added standardized Just-based task files in multiple packages to define local builds, unit/integration/compressible tests, and verification workflows with sensible environment defaults.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Jan 21, 2026

📝 Walkthrough

Walkthrough

Replaces Nx-based build/test scripts with Just-based workflows: adds per-package Justfiles (forester, programs, program-libs, sdk-libs, prover/server), removes forester/package.json and programs/package.json, and updates CLAUDE.md to reference new just targets. No public API changes.

Changes

Cohort / File(s) Summary
Docs
CLAUDE.md
Replaced Nx JS/TS command examples with just targets (root-level aggregates and CLI/js test targets).
Removed manifests
forester/package.json, programs/package.json
Deleted package.json files including metadata, scripts, devDependencies, and Nx targets.build.outputs blocks.
Justfile — forester
forester/justfile
New Justfile exporting test env vars and adding build, build-test-deps, test, and multiple test-compressible-* targets.
Justfile — prover/server
prover/server/justfile
New Justfile with TEST_REDIS_URL, grouped unit/redis/integration test targets and formal verification targets (extract-circuit, lean-build, verify).
Justfile — programs
programs/justfile
New Justfile adding build (cargo build-sbf across program crates) and a compressed-token variant.
Justfile — program-libs
program-libs/justfile
New Justfile orchestrating comprehensive cargo test runs across many crates and feature permutations (test-fast, test-slow, test-simulate).
Justfile — sdk-libs
sdk-libs/justfile
New Justfile adding default and test targets that run cargo test across SDK crates (including --all-features).

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Suggested labels

ai-review

Poem

Out with Nx, in with Just we stride,
Targets, envs, and builds aligned,
Cargo and tests now carefully thrust,
CI sings a simpler song — swift and just ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: migrating from Nx-based build/test commands to Just-based equivalents across multiple configuration files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch sergey/just

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
CLAUDE.md (1)

1-75: Add required CLAUDE.md sections (Summary, Used in, Navigation, Source Code Structure).

This file is missing the mandatory sections for **/CLAUDE.md, which makes it non-compliant with project documentation standards. Please add them near the top. As per coding guidelines, ...

✍️ Minimal template
+# Summary
+- …
+- …
+
+# Used in
+- …
+
+# Navigation
+- …
+
+# Source Code Structure
+- …

Comment thread justfile Outdated
Comment thread justfile Outdated
Copy link
Copy Markdown
Contributor

@ananas-block ananas-block left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice I like it, just 2 comments, but it seems like that command is not used in ci anyway

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@program-libs/justfile`:
- Line 39: The test invocation in the justfile uses an incorrect `--test` flag
passed to the test binary; change the command so the test filter is passed
directly to the test runner (remove the extra `--test` token) — i.e., keep the
cargo-level separator `--` and pass `test_simulate_transactions` as the filter
so the invocation becomes RUST_LOG=... cargo test -p batched-merkle-tree-test --
test_simulate_transactions; update the line containing that command in the
justfile accordingly.

In `@prover/server/justfile`:
- Around line 68-70: The extract-circuit target currently calls ./light-prover
directly and can fail if the binary doesn't exist; update the justfile so the
extract-circuit recipe depends on the build-binary target (i.e., declare
extract-circuit to depend on build-binary) so that build-binary runs first and
produces ./light-prover before extract-circuit executes; reference the
extract-circuit target and the build-binary target when making this change.

Comment thread program-libs/justfile Outdated
Comment thread prover/server/justfile Outdated
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@prover/server/justfile`:
- Around line 42-55: Add a short explanatory comment above the test-integration
(and/or test) target clarifying why test-full is excluded: note that test-full
has a much longer timeout (test-full target with 120m timeout) and is
intentionally omitted from test-integration and test to avoid extremely slow CI
runs, but can be run manually via the test-full target for exhaustive testing;
update the justfile near the test-full, test-integration, and test targets to
include this one-line rationale.
- Around line 57-64: The justfile uses a hardcoded Elan path for lake in the
lean-build target; update lean-build to invoke lake from PATH (replace
"~/.elan/bin/lake" with "lake") so it matches the documented setup, keeping the
existing commands (cd formal-verification && lake exe cache get && lake build)
and leaving the extract-circuit and verify targets (extract-circuit:
build-binary and verify: extract-circuit lean-build) unchanged.

Comment thread prover/server/justfile
Comment thread prover/server/justfile
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@programs/justfile`:
- Around line 12-13: The build target build-compressed-token-small is changing
into the wrong directory (compressed-token/) which is not a Cargo package;
update the target to cd into the actual crate directory compressed-token/program
before running cargo build-sbf so the cpi-without-program-ids feature (defined
in compressed-token/program/Cargo.toml) is available; locate the
build-compressed-token-small target in the justfile and replace the cd path to
compressed-token/program to match the other compressed-token build target.

In `@sdk-libs/justfile`:
- Around line 6-15: The test recipe in the Justfile is missing the
light-token-sdk crate; update the "test" target to include running cargo test -p
light-token-sdk and cargo test -p light-token-sdk --all-features alongside the
existing crate tests (e.g., the other cargo test -p ... lines) so the SDK
coverage matches the pattern used for light-token and other core SDK crates.

Comment thread programs/justfile Outdated
Comment thread sdk-libs/justfile
@sergeytimoshin sergeytimoshin force-pushed the sergey/just branch 2 times, most recently from 41e16ac to b93cf05 Compare January 22, 2026 17:21
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@CLAUDE.md`:
- Around line 139-143: Update the incorrect Justfile command examples in
CLAUDE.md: replace "just build-cli" with "just cli::build", "just
test-stateless-js" with "just js::test-stateless", keep "just
js::test-compressed-token" as-is, and replace "just test-cli" with "just
cli::test"; optionally mention the root-level aggregates "just build" and "just
test" as alternatives that include the cli and js targets.

In `@forester/justfile`:
- Around line 3-8: Add a default RUST_BACKTRACE export to the justfile so tests
get backtraces by default: update the exports block (where TEST_MODE,
TEST_V1_STATE, TEST_V2_STATE, TEST_V1_ADDRESS, TEST_V2_ADDRESS are set) to
include RUST_BACKTRACE using the same env_var_or_default helper, e.g. export
RUST_BACKTRACE := env_var_or_default("RUST_BACKTRACE", "1"), so local CI and dev
runs produce useful backtraces for debugging.
♻️ Duplicate comments (1)
sdk-libs/justfile (1)

6-17: Check whether light-token-sdk still needs coverage in the test target.

If the workspace still contains a light-token-sdk crate, it should likely be exercised alongside the other SDK libs here. Please confirm its presence and add tests if applicable.

#!/bin/bash
# Check whether light-token-sdk exists as a workspace package
rg -n 'name\s*=\s*"light-token-sdk"' -g 'Cargo.toml'
➕ Proposed addition (if the crate exists)
 test:
     cargo test -p light-sdk-macros
     cargo test -p light-sdk-macros --all-features
     cargo test -p light-sdk
     cargo test -p light-sdk --all-features
     cargo test -p light-program-test
     cargo test -p light-client
     cargo test -p light-sparse-merkle-tree
     cargo test -p light-token-types
+    cargo test -p light-token-sdk
+    cargo test -p light-token-sdk --all-features
     cargo test -p light-token --all-features
     cargo test -p light-token-client
     cargo test -p light-token-client --all-features

Comment thread CLAUDE.md Outdated
Comment thread forester/justfile
@sergeytimoshin sergeytimoshin merged commit 57a7f1e into main Jan 22, 2026
45 checks passed
@sergeytimoshin sergeytimoshin deleted the sergey/just branch January 22, 2026 18:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants