Skip to content

Commit 0b5b196

Browse files
offline-replay: update agave-ledger-tool build (#7447)
1 parent 2d1449f commit 0b5b196

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

contrib/offline-replay/offline_replay_template.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ export FD_BRANCH="main"
66

77
# Agave Repo
88
export AGAVE_REPO="/path/to/agave"
9-
export AGAVE_LEDGER_TOOL="${AGAVE_REPO}/target/release/agave-ledger-tool"
109

1110
# Network Specific Parameters
1211
export NETWORK="mainnet"

contrib/offline-replay/run_offline_replay_backtest.sh

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,17 @@ while true; do
5959
cd $AGAVE_REPO
6060
git pull
6161
git checkout $AGAVE_TAG
62-
cargo build --release
62+
63+
AGAVE_VERSION=$(echo "$AGAVE_TAG" | sed 's/^v//')
64+
if [ "$(printf '%s\n' "$AGAVE_VERSION" "3.1.0" | sort -V | head -n1)" = "3.1.0" ]; then
65+
cargo clean
66+
cargo build --manifest-path dev-bins/Cargo.toml -p agave-ledger-tool --release
67+
AGAVE_LEDGER_TOOL="${AGAVE_REPO}/dev-bins/target/release/agave-ledger-tool"
68+
else
69+
cargo clean
70+
cargo build --release
71+
AGAVE_LEDGER_TOOL="${AGAVE_REPO}/target/release/agave-ledger-tool"
72+
fi
6373

6474
send_slack_message "Bucket Slot \`$NEWEST_BUCKET_SLOT\` is greater than the last run bucket slot \`$LATEST_RUN_BUCKET_SLOT\`"
6575

0 commit comments

Comments
 (0)