Skip to content
Merged
Show file tree
Hide file tree
Changes from 13 commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
e3ac7b6
fix: add integration-tests cache key
TomasArrachea Feb 23, 2026
c33a625
feat: improve caching
TomasArrachea Feb 23, 2026
4e00807
test: cmoment out save-if
TomasArrachea Feb 23, 2026
80ed7c4
fix: remove yarn cache
TomasArrachea Feb 23, 2026
7746277
feat: note transport cache
TomasArrachea Feb 23, 2026
182f4fa
fix: node builder binary name
TomasArrachea Feb 23, 2026
5ffbed4
fix: note-transport cache
TomasArrachea Feb 24, 2026
edc6fa9
test CI
TomasArrachea Feb 24, 2026
8b06ba0
add cache key nightly
TomasArrachea Feb 24, 2026
b421779
feat: restore yarn cache
TomasArrachea Feb 24, 2026
d53f601
feat: uncomment save-if
TomasArrachea Feb 24, 2026
1087704
chore: simplify note-transport cache
TomasArrachea Feb 24, 2026
f64aac1
chore: simplify start binary script
TomasArrachea Feb 24, 2026
bfd1577
review: add separate cache for prover binary
TomasArrachea Feb 24, 2026
91c0c25
chore: build node and note-transport once on miss
TomasArrachea Feb 25, 2026
235681c
chore: adjust path
TomasArrachea Feb 25, 2026
37c5aab
chore: rename jobs
TomasArrachea Feb 25, 2026
77afa7c
chore: avoid rebuilding binaries on cache hit
TomasArrachea Feb 25, 2026
8d0d217
chore: install note-transport via git install
TomasArrachea Feb 25, 2026
0b2d975
review: add TODO comment
TomasArrachea Feb 25, 2026
556d455
chore: restore rust cache for wasm tests
TomasArrachea Feb 25, 2026
1bcf57e
test: temporarily write to cache
TomasArrachea Feb 25, 2026
7d83c46
Revert "test: temporarily write to cache"
TomasArrachea Feb 25, 2026
d62e01d
chore: remove rust-wasm, rust-debug, rust-nightly-release cache entries
TomasArrachea Feb 25, 2026
b1df45a
chore: restore rust-wasm
TomasArrachea Feb 25, 2026
cb9c63a
chore: save rust-wasm cache
TomasArrachea Feb 25, 2026
e673a6e
chore: add build-remote-prover job
TomasArrachea Feb 27, 2026
c724d28
chore: add rust cache for prover and node-builder jobs
TomasArrachea Mar 2, 2026
cffd514
chore: format
TomasArrachea Mar 2, 2026
69cc9a1
chore: lint
TomasArrachea Mar 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
shared-key: rust-release
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: make - build
Expand All @@ -51,7 +51,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build-wasm
shared-key: rust-wasm
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: make - build-wasm
Expand Down
14 changes: 4 additions & 10 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
shared-key: rust-debug
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: make - clippy
Expand All @@ -107,7 +107,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build-wasm
shared-key: rust-wasm
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: make - clippy-wasm
Expand All @@ -122,12 +122,6 @@ jobs:
run: |
rustup update --no-self-update nightly
rustup +nightly component add rustfmt
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: Install prettier
run: yarn install
- name: make - format-check
Expand All @@ -153,7 +147,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build-wasm
shared-key: rust-wasm
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: Install dependencies
Expand Down Expand Up @@ -181,7 +175,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
shared-key: rust-nightly-release
Comment thread
TomasArrachea marked this conversation as resolved.
Outdated
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: make - doc
Expand Down
34 changes: 24 additions & 10 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
shared-key: rust-release
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- uses: taiki-e/install-action@v2
Expand All @@ -50,7 +50,7 @@ jobs:
- uses: actions/checkout@v6
- uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
shared-key: rust-debug
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: Install rust
Expand Down Expand Up @@ -133,9 +133,19 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
shared-key: rust-release
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: Restore node-builder binary
uses: actions/cache@v4
with:
path: target/release/testing-node-builder
key: ${{ runner.os }}-node-builder-${{ hashFiles('Cargo.lock') }}
- name: Restore note-transport binary
uses: actions/cache@v4
with:
path: target/note-transport/release/miden-note-transport-node-bin
key: ${{ runner.os }}-note-transport-${{ hashFiles('Cargo.lock') }}
- name: Start test node
run: make start-node-background
- name: Start note transport
Expand Down Expand Up @@ -164,7 +174,7 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build-wasm
shared-key: rust-wasm
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}

Expand Down Expand Up @@ -240,12 +250,11 @@ jobs:
node-version: "20"
- name: Configure setuid sandbox
run: . ./scripts/configure-sandbox.sh
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
- name: Restore node-builder binary
uses: actions/cache@v4
with:
shared-key: rust-build
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
path: target/release/testing-node-builder
key: ${{ runner.os }}-node-builder-${{ hashFiles('Cargo.lock') }}
- name: Start test node
run: make start-node-background
- name: Run web client tests
Expand Down Expand Up @@ -283,9 +292,14 @@ jobs:
- name: Add Rust Cache
uses: Swatinem/rust-cache@v2
with:
shared-key: rust-build
shared-key: rust-release
prefix-key: ${{ env.RUST_CACHE_KEY }}
save-if: ${{ github.ref == 'refs/heads/next' }}
- name: Restore node-builder binary
Comment thread
igamigo marked this conversation as resolved.
uses: actions/cache@v4
with:
path: target/release/testing-node-builder
key: ${{ runner.os }}-node-builder-${{ hashFiles('Cargo.lock') }}
- name: Start test node
run: make start-node-background
- name: Start prover
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/wallet-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ jobs:
node-version: "20"
cache: yarn
cache-dependency-path: |
yarn.lock
packages/react-sdk/yarn.lock
packages/react-sdk/examples/wallet/yarn.lock
- name: Install root dependencies
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ start-node: ## Start the testing node server

.PHONY: start-node-background
start-node-background: ## Start the testing node server in background
./scripts/start-binary-bg.sh node-builder
./scripts/start-binary-bg.sh testing-node-builder

.PHONY: stop-node
stop-node: ## Stop the testing node server
Expand Down
29 changes: 19 additions & 10 deletions scripts/start-binary-bg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,31 @@
# Starts the binary in the background and checks that it has not exited

if [ -z "$1" ]; then
echo "Usage: $0 <package-name>"
echo "Usage: $0 <binary-name>"
exit 1
fi;

PACKAGE_NAME="$1"
BINARY_NAME="$1"

if ! cargo build --release --package "$PACKAGE_NAME" --locked; then
echo "Failed to build $PACKAGE_NAME"
exit 1
# Resolve the workspace target directory (handles being called from subcrates)
TARGET_DIR=$(cargo metadata --format-version 1 --no-deps 2>/dev/null | grep -o '"target_directory":"[^"]*"' | head -1 | cut -d'"' -f4)
TARGET_DIR="${TARGET_DIR:-target}"
BINARY_PATH="$TARGET_DIR/release/$BINARY_NAME"

if [ -x "$BINARY_PATH" ]; then
echo "$BINARY_NAME binary found, skipping build"
else
if ! cargo build --release --bin "$BINARY_NAME" --locked; then
echo "Failed to build $BINARY_NAME"
exit 1
fi;
fi;

RUST_LOG=none cargo run --release --package "$PACKAGE_NAME" --locked & echo $! > .$PACKAGE_NAME.pid;
RUST_LOG=none "$BINARY_PATH" & echo $! > .$BINARY_NAME.pid;
sleep 4;
if ! ps -p $(cat .$PACKAGE_NAME.pid) > /dev/null; then
echo "Failed to start $PACKAGE_NAME";
rm -f .$PACKAGE_NAME.pid;
if ! ps -p $(cat .$BINARY_NAME.pid) > /dev/null; then
echo "Failed to start $BINARY_NAME";
rm -f .$BINARY_NAME.pid;
exit 1;
fi;
rm -f .$PACKAGE_NAME.pid
rm -f .$BINARY_NAME.pid
13 changes: 9 additions & 4 deletions scripts/start-note-transport-bg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ BRANCH=${TRANSPORT_BRANCH:-main}

TRANSPORT_DIR=${TRANSPORT_DIR:-.tmp/miden-note-transport}
REPO_URL=${REPO_URL:-https://github.com/0xMiden/miden-note-transport}
RUN_CMD=${TRANSPORT_RUN_CMD:-cargo run --release --locked}

# Shared target directory (important for CI speed: ends up under repo `target/` which is cached)
TRANSPORT_CARGO_TARGET_DIR=${TRANSPORT_CARGO_TARGET_DIR:-"$REPO_ROOT/target/note-transport"}
Expand All @@ -33,11 +32,17 @@ else
git -C "$TRANSPORT_DIR" reset --hard "origin/$BRANCH"
fi

echo "Building note transport service..."
( cd "$TRANSPORT_DIR" && CARGO_TARGET_DIR="$TRANSPORT_CARGO_TARGET_DIR" cargo build --release --locked )
BINARY_PATH="$TRANSPORT_CARGO_TARGET_DIR/release/miden-note-transport-node-bin"

if [ -x "$BINARY_PATH" ]; then
echo "Note transport binary found, skipping build"
else
echo "Building note transport service..."
( cd "$TRANSPORT_DIR" && CARGO_TARGET_DIR="$TRANSPORT_CARGO_TARGET_DIR" cargo build --release --locked )
fi

echo "Starting note transport service in background..."
( cd "$TRANSPORT_DIR" && RUST_LOG=info CARGO_TARGET_DIR="$TRANSPORT_CARGO_TARGET_DIR" $RUN_CMD ) & echo $! > "$PID_FILE"
RUST_LOG=info "$BINARY_PATH" & echo $! > "$PID_FILE"

sleep 4

Expand Down