Toolchain
Programs
target/deploy/<name>-keypair.json belongs to a different address, build with anchor build --ignore-keys. Don’t run anchor keys sync unless you mean to change the program IDs.
Tests
The tests run in LiteSVM (no validator) and load all three programs fromtarget/deploy/, so build first and rebuild after any program change.
The basis-vault tests live in their own crate (
tests/basis) because Phoenix’s Hawkeye program needs a newer LiteSVM:
Local mainnet fork
bootstrap-fork.sh becomes the protocol admin. npm run devnet -- <command> has one command per core instruction. npm run integrations-fork -- <command> covers funding, Kamino, Jupiter, Titan, Phoenix, Perena and the basis vaults. Run either with no command to print its list.
App
.env.example: NEXT_PUBLIC_SOLANA_RPC_URL, NEXT_PUBLIC_SOLANA_WS_URL, FORK_RPC_URL, NEXT_PUBLIC_VANNA_PROGRAM_ID, ACCESS_CODE (the code the site asks for once; required, the site stays locked without it), and server-only API keys for Jupiter and Titan. Titan quotes are skipped when the server has no Titan key. Point your wallet’s custom RPC at http://127.0.0.1:8899 and open http://localhost:3000.
Hosted layout
surfnet-version and solana-core version.
Common problems
The app’s end-to-end scripts (
npm run e2e, scripts/e2e-*.ts) run against the fork through the app’s own services. Avoid scripts that overwrite shared fixtures on the hosted node.
