Archived documentation for
@eco-incorp/sauce@0.99.16. Install this release with npm install --save-exact @eco-incorp/sauce@0.99.16. Links to guides outside this tab open current documentation.@eco-incorp/sauce/svm is the Solana side: the client (createSauceSvmClient), clusters, PDAs, account resolution against the compiler’s account manifest, Kitchen and engine instructions, transactions and sending, token accounts, and compute planning for @sauce/router’s Solana venues. @eco-incorp/sauce/svm/engine exports the engine’s wire format and instruction builders, @eco-incorp/sauce/svm/verify verifies settle programs and engine CPI data, and @eco-incorp/sauce/svm/engine-artifacts (Node only) returns file paths to the packaged engine and Kitchen binaries.
@eco-incorp/sauce.
engineFaultName
Function · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
The fault a Custom(code) from the engine names, or undefined for a code it does not use.
EXECUTE_DISCRIMINATOR
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
The Kitchen-mediated engine instruction discriminators.
Declared here, not generated. The pre-release engine shipped an engine-abi.json these were
derived from; neither that artifact nor the engine it described exists any more - nothing about
the engine is source-controlled now, it is fetched from a pinned release.
EXECUTE_FROM_ACCOUNT_DISCRIMINATOR
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
CLOSE_ACCOUNT_DISCRIMINATOR
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
closeAccount - the third instruction, previously unrepresented here.
COOK_AND_PAY_DISCRIMINATOR
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
The direct paid cooks: sha256("global:<name>")[..8], as the engine declares them.
cookAndPay carries max_execution_fee (u64 LE) and then the bytecode; cookAndPayFromAccount
the fee cap alone, the program being account 0’s data; cookAndPayFromAccountPinned the fee cap
and the SHA-256 that account 0’s whole data must hash to. None carries a Pot gate header.
COOK_AND_PAY_FROM_ACCOUNT_DISCRIMINATOR
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
COOK_AND_PAY_FROM_ACCOUNT_PINNED_DISCRIMINATOR
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
ENGINE_FAULTS
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
The engine’s Custom(n) fault codes, by name - what a failed engine instruction’s
InstructionError carries. Revert (0) is a program’s own throw/require, its payload the
return data; every other code is the engine refusing. The direct cooks add the fee faults
(InvalidFeeConfig … ExecutionFeeExceedsMaximum) and CodeHashMismatch; a legacy instruction
sent by anything but a Kitchen cook is NotCookedByKitchen.
EngineFault
Type · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
HEAP_FRAME_BYTES
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
The 256 KiB BPF heap frame every execute transaction MUST request:
interpreter memory (operand stack, heap, frames) lives above the default
32 KiB Rust bump arena, not in accounts. Attach RequestHeapFrame(262144)
beside SetComputeUnitLimit on every execute/simulate transaction - add-once: duplicate ComputeBudget instruction types fail the whole
transaction. A transaction without it aborts deterministically (SBF
AccessViolation) before any opcode runs. Buffer staging transactions do
not need it - their instructions never touch interpreter memory.
HEAP_FRAME_CU_PER_INVOCATION
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
CU cost of the heap-frame request, charged per program invocation in the transaction.
REQUEST_HEAP_FRAME_WIRE_BYTES
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
Wire cost of the RequestHeapFrame instruction: 8 bytes beside an existing
ComputeBudget instruction (the program key and count byte are already paid),
9 standalone. Measured - engine tests/cu_budget.rs.
MAX_RETURN_DATA
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
MAX_CPI_ACCOUNTS
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
ENGINE_GAS_LIMIT_CU
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
ENGINE_CHAIN_IDS
Variable · @eco-incorp/sauce/svm, @eco-incorp/sauce/svm/engine
Synthetic CHAIN_ID values reported by the engine’s CHAIN_ID opcode. The
devnet id is what a default cargo build-sbf build reports - localnet and
LiteSVM runs use it too; mainnet requires building with --features mainnet.
