@eco-incorp/sauce 0.99.3 → 0.99.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -15
- package/dev-tools/README.md +3 -3
- package/docs/api/routes.md +1 -1
- package/docs/guides/solana.md +4 -3
- package/docs/guides/verification.md +1 -1
- package/package.json +1 -1
- package/sdk/dist/artifacts/V12Deployments.json +4 -4
- package/sdk/dist/artifacts/svm/engine-devnet.so +0 -0
- package/sdk/dist/artifacts/svm/engine-mainnet.so +0 -0
- package/sdk/dist/artifacts/svm/engine-wire-devnet.json +6 -0
- package/sdk/dist/artifacts/svm/engine-wire-mainnet.json +6 -0
package/README.md
CHANGED
|
@@ -8,8 +8,8 @@ tokens, and builds the calls that execute your program.
|
|
|
8
8
|
npm install @eco-incorp/sauce
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
[Documentation](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
12
|
-
[Examples](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
11
|
+
[Documentation](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/README.md) · [Quick start](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/quick-start.md) ·
|
|
12
|
+
[Examples](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/examples/README.md) · [API reference](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/api/README.md)
|
|
13
13
|
|
|
14
14
|
Use Node.js **24 or newer**. The links open the Markdown manual and examples included in this package version. After installation, you can also open `node_modules/@eco-incorp/sauce/docs/README.md` locally.
|
|
15
15
|
|
|
@@ -48,14 +48,14 @@ const built = Base(() => {
|
|
|
48
48
|
console.log(built.hash().intentHash);
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
-
The [quick start](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
51
|
+
The [quick start](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/quick-start.md) explains the setup, and the [examples](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/examples/README.md) are checked
|
|
52
52
|
against the SDK. The callback is compiled as source. Token and protocol names resolve on Base;
|
|
53
53
|
values from surrounding JavaScript must be supplied through compile-time `defines`.
|
|
54
54
|
|
|
55
55
|
Use `USDC.transfer(...)`, `USDC.balanceOf(...)`, `Token(address).approve(...)`, and linked protocol
|
|
56
56
|
methods in the same program. `Uniswap.UniversalRouter` is the family alias for
|
|
57
57
|
`UniswapV4.UniversalRouter`; available contracts and methods come from the
|
|
58
|
-
[accessor registry](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
58
|
+
[accessor registry](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/api/coverage.md). The compiler checks chain availability and ABI fidelity.
|
|
59
59
|
|
|
60
60
|
## From a program to an intent
|
|
61
61
|
|
|
@@ -66,31 +66,31 @@ submits those requests. Direct Portal execution requires an Executor-owned Pot a
|
|
|
66
66
|
Use the direct Kitchen client for Solana execution. The legacy SVM intent helper is incompatible
|
|
67
67
|
with the released gated engine; the Solana guide below describes this boundary.
|
|
68
68
|
|
|
69
|
-
- [Create and fund an intent](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
70
|
-
- [Compose nested intents](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
71
|
-
- [Build programs with token, swap, deposit, and action helpers](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
72
|
-
- [Execute on Solana](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
73
|
-
- [Verify settlement programs](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
69
|
+
- [Create and fund an intent](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/intents.md)
|
|
70
|
+
- [Compose nested intents](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/nested-intents.md)
|
|
71
|
+
- [Build programs with token, swap, deposit, and action helpers](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/builders-and-actions.md)
|
|
72
|
+
- [Execute on Solana](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/solana.md)
|
|
73
|
+
- [Verify settlement programs](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/verification.md)
|
|
74
74
|
|
|
75
75
|
## Compiler and runtime
|
|
76
76
|
|
|
77
77
|
The SDK includes **`@eco-incorp/sauce-compiler`**, the Rust/WebAssembly SauceScript compiler, and
|
|
78
78
|
exposes it through `@eco-incorp/sauce/compiler`. Compile directly when you need entry arguments,
|
|
79
|
-
custom module resolution, or SVM account manifests. See the [compiler guide](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
80
|
-
and [compiler API](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
79
|
+
custom module resolution, or SVM account manifests. See the [compiler guide](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/compiling.md)
|
|
80
|
+
and [compiler API](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/api/compiler.md).
|
|
81
81
|
|
|
82
82
|
SauceScript supports contract calls, arithmetic, control flow, and composition within the
|
|
83
|
-
[compiler's language subset](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
83
|
+
[compiler's language subset](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/concepts/saucescript.md). A program executes atomically in one
|
|
84
84
|
transaction on its target chain. Cross-chain intents coordinate separate transactions.
|
|
85
85
|
|
|
86
86
|
The root SDK and its compiler integration require Node.js **24 or newer**. The compiler dependency also has its
|
|
87
|
-
own browser entry point. See [architecture](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
87
|
+
own browser entry point. See [architecture](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/concepts/architecture.md) for how the SDK,
|
|
88
88
|
compiler, and deployed runtime work together.
|
|
89
89
|
|
|
90
|
-
Current release pins: compiler **2.3.0**, EVM engine **1.0.1**, SVM engine **1.
|
|
90
|
+
Current release pins: compiler **2.3.0**, EVM engine **1.0.1**, SVM engine **1.2.0**, both Kitchens
|
|
91
91
|
**1.0.0**. Release addresses do not establish on-chain deployment status.
|
|
92
92
|
|
|
93
93
|
The EVM settle program compiles to **356 bytes** with a new verification hash. Recompile and
|
|
94
94
|
invalidate cached programs when upgrading; to verify existing 362-byte payloads, pass their
|
|
95
95
|
historical `{ hash, bytes: 362 }` pin to `validateSettleProgram` (see
|
|
96
|
-
[verification](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
96
|
+
[verification](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/verification.md)).
|
package/dev-tools/README.md
CHANGED
|
@@ -6,11 +6,11 @@ To build an application with Sauce, install the SDK:
|
|
|
6
6
|
pnpm add @eco-incorp/sauce
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Follow the [quick start](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
10
|
-
and [executable examples](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
9
|
+
Follow the [quick start](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/quick-start.md)
|
|
10
|
+
and [executable examples](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/examples/README.md)
|
|
11
11
|
for compiling programs and constructing Eco intents in your own project. You can also open the installed manual at `node_modules/@eco-incorp/sauce/docs/README.md`.
|
|
12
12
|
|
|
13
13
|
The `sauce-dev-tools` scaffold contains older local deployment and execution scripts. Those scripts
|
|
14
14
|
target an earlier EVM contract interface and are incompatible with current Kitchen/Pot deployments.
|
|
15
|
-
Use the SDK's [execution guides](https://unpkg.com/@eco-incorp/sauce@0.99.
|
|
15
|
+
Use the SDK's [execution guides](https://unpkg.com/@eco-incorp/sauce@0.99.4/docs/guides/compiling.md)
|
|
16
16
|
for current programs.
|
package/docs/api/routes.md
CHANGED
|
@@ -79,7 +79,7 @@ The route wrapper has no runtime argument-payload parameter. Use compile-time de
|
|
|
79
79
|
|
|
80
80
|
`sauceEvmDeployPotCall({ owner, salt, kitchen })` encodes Pot deployment through the supplied Kitchen; direct intent routes use the destination `Portal.executor()` as owner. Its `chainId` alternative selects the pinned release Kitchen only for chains in the historical successful-deployment roster. `v12Deployment` and `requireV12Deployment` also return current release addresses under that historical filter; none of these helpers verifies current on-chain deployment. Prefer explicit `v12KitchenAddress()` after checking the target chain. `V12_EVM_CONTRACTS` and `v12SvmProgramId` are legacy addresses; use the current `/deployments` address functions. [evm-execution.ts](../examples/evm-execution.ts) demonstrates prediction, deployment, and owner/Kitchen checks.
|
|
81
81
|
|
|
82
|
-
`buildSauceSvmCall` and the SVM route path emit a legacy 8-byte staged-engine instruction, which is **incompatible with engine 1.
|
|
82
|
+
`buildSauceSvmCall` and the SVM route path emit a legacy 8-byte staged-engine instruction, which is **incompatible with engine 1.2.0** even when supplied a code account and the current engine ID. They do not construct the required Kitchen call. Use the direct Kitchen client for Solana execution; see [the SVM intent limitation](../guides/solana.md#svm-destinations-in-eco-intents).
|
|
83
83
|
|
|
84
84
|
## Built intents
|
|
85
85
|
|
package/docs/guides/solana.md
CHANGED
|
@@ -71,10 +71,11 @@ After successful simulation, `client.execute(bytecode, manifest, resolution, { c
|
|
|
71
71
|
|
|
72
72
|
### Select the released programs and quote the fee
|
|
73
73
|
|
|
74
|
-
The pinned SVM engine **1.
|
|
74
|
+
The pinned SVM engine **1.2.0** is `HB8b1oD5PB2ptkLH6EV56Rr9RHevutEfvG2YdA7an6rK`;
|
|
75
75
|
Kitchen **1.0.0** is `SauceYLdWyabKFwtevSAgsSDoMjCoTKtx1HTb63eJot`.
|
|
76
76
|
These are release addresses; confirm deployment on your cluster before use.
|
|
77
|
-
Engine 1.
|
|
77
|
+
Engine 1.2.0 adds a code-hash-pinned staged variant of the direct paid calls introduced
|
|
78
|
+
in 1.1.0. The SDK clients use Kitchen-mediated cooks;
|
|
78
79
|
builders for the direct paid instructions are not yet exposed.
|
|
79
80
|
Use the deployment helpers and read the Kitchen's fee configuration on the selected
|
|
80
81
|
cluster. This example checks a caller-selected lamport budget before signing:
|
|
@@ -152,7 +153,7 @@ The low-level instruction builders return instructions; the application groups,
|
|
|
152
153
|
For an SVM destination, `Solana(body, { execution, ... }).reward(...)`,
|
|
153
154
|
`routes.compileSauceRoute()`, `buildSauceSvmCall()`, and `buildSauceSvmCalls()` emit
|
|
154
155
|
a legacy `execute_from_account` instruction containing only its 8-byte
|
|
155
|
-
discriminator. Engine 1.
|
|
156
|
+
discriminator. Engine 1.2.0 still requires another 65 bytes of Pot derivation material
|
|
156
157
|
and a trailing Pot signer supplied by the Kitchen.
|
|
157
158
|
|
|
158
159
|
The [SVM Portal fulfillment implementation](https://github.com/eco/eco-routes-svm/blob/5e544b72d368d9d1f0ee5269e2a1a5d2a9f8c2f2/programs/portal/src/instructions/fulfill.rs#L139-L192)
|
|
@@ -182,7 +182,7 @@ instruction are the ones the application expects.
|
|
|
182
182
|
|
|
183
183
|
`decodeSvmSettleExecution({ instructionData, accounts })` resolves accounts
|
|
184
184
|
positionally against the canonical settlement refs. The default `wireFormat: "gated-v1"` accepts raw **engine CPI instructions** produced by Kitchen 1.0.0 for
|
|
185
|
-
engine 1.
|
|
185
|
+
engine 1.2.0:
|
|
186
186
|
|
|
187
187
|
| Instruction | Data | Full CPI account list |
|
|
188
188
|
| ---------------------- | ------------------------------------------------------------------ | -------------------------------------- |
|
package/package.json
CHANGED
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
"commit": "f2f6dfbe38809304d83ca755eb7975c19d35ceab"
|
|
12
12
|
},
|
|
13
13
|
"v12-svm": {
|
|
14
|
-
"version": "1.
|
|
15
|
-
"commit": "
|
|
14
|
+
"version": "1.2.0",
|
|
15
|
+
"commit": "a65ede3f42149bfe35ff22d8765e878e849914ae"
|
|
16
16
|
},
|
|
17
17
|
"kitchen-svm": {
|
|
18
18
|
"version": "1.0.0",
|
|
@@ -67,8 +67,8 @@
|
|
|
67
67
|
"clusterIndependent": true,
|
|
68
68
|
"programs": {
|
|
69
69
|
"engine": {
|
|
70
|
-
"programId": "
|
|
71
|
-
"label": "engine@1.
|
|
70
|
+
"programId": "HB8b1oD5PB2ptkLH6EV56Rr9RHevutEfvG2YdA7an6rK",
|
|
71
|
+
"label": "engine@1.2.0",
|
|
72
72
|
"derivation": "ed25519 keypair from sha256(SOLANA_PROGRAM_KEY_SEED, label)",
|
|
73
73
|
"upgradeAuthority": "none — deployed --final, so this program can never be upgraded or closed"
|
|
74
74
|
},
|
|
Binary file
|
|
Binary file
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
"AccountNotSigner": 66,
|
|
10
10
|
"AccountNotWritable": 62,
|
|
11
11
|
"BytecodeOutOfBounds": 12,
|
|
12
|
+
"CodeHashMismatch": 72,
|
|
12
13
|
"DataTooLarge": 41,
|
|
13
14
|
"DivisionByZero": 50,
|
|
14
15
|
"ExecutionFeeExceedsMaximum": 84,
|
|
@@ -51,6 +52,11 @@
|
|
|
51
52
|
"bytecode": "account 0's data verbatim; instruction data is discriminator(8), max_execution_fee(u64 LE, 8), with no trailing bytes",
|
|
52
53
|
"discriminator": "44d5e0657b813006"
|
|
53
54
|
},
|
|
55
|
+
"cookAndPayFromAccountPinned": {
|
|
56
|
+
"accounts": "account 0 is the code; the caller's tail follows, then writable signer fee payer, executable System Program, canonical Kitchen ExecutionFeeConfig PDA (writable for a positive fee); code and payment accounts are excluded from the interpreter tail; SHA-256 of all code account data must equal the mandatory expected_sha256 before fee validation, payment or bytecode; holds the checked data borrow through execution; requires execution_fee <= max_execution_fee and validates config and payer even at zero fee; no Pot signing or code-buffer metadata validation",
|
|
57
|
+
"bytecode": "account 0's entire data verbatim, including appended arguments; instruction data is discriminator(8), max_execution_fee(u64 LE, 8), expected_sha256(32), with no trailing bytes",
|
|
58
|
+
"discriminator": "8dea491aee52402f"
|
|
59
|
+
},
|
|
54
60
|
"execute": {
|
|
55
61
|
"accounts": "the caller's tail at its natural indices, followed by the kitchen-signed acting Pot; the engine strips the acting Pot before execution",
|
|
56
62
|
"bytecode": "instruction data, after discriminator(8), owner(32), salt(32), bump(1)",
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
"AccountNotSigner": 66,
|
|
10
10
|
"AccountNotWritable": 62,
|
|
11
11
|
"BytecodeOutOfBounds": 12,
|
|
12
|
+
"CodeHashMismatch": 72,
|
|
12
13
|
"DataTooLarge": 41,
|
|
13
14
|
"DivisionByZero": 50,
|
|
14
15
|
"ExecutionFeeExceedsMaximum": 84,
|
|
@@ -51,6 +52,11 @@
|
|
|
51
52
|
"bytecode": "account 0's data verbatim; instruction data is discriminator(8), max_execution_fee(u64 LE, 8), with no trailing bytes",
|
|
52
53
|
"discriminator": "44d5e0657b813006"
|
|
53
54
|
},
|
|
55
|
+
"cookAndPayFromAccountPinned": {
|
|
56
|
+
"accounts": "account 0 is the code; the caller's tail follows, then writable signer fee payer, executable System Program, canonical Kitchen ExecutionFeeConfig PDA (writable for a positive fee); code and payment accounts are excluded from the interpreter tail; SHA-256 of all code account data must equal the mandatory expected_sha256 before fee validation, payment or bytecode; holds the checked data borrow through execution; requires execution_fee <= max_execution_fee and validates config and payer even at zero fee; no Pot signing or code-buffer metadata validation",
|
|
57
|
+
"bytecode": "account 0's entire data verbatim, including appended arguments; instruction data is discriminator(8), max_execution_fee(u64 LE, 8), expected_sha256(32), with no trailing bytes",
|
|
58
|
+
"discriminator": "8dea491aee52402f"
|
|
59
|
+
},
|
|
54
60
|
"execute": {
|
|
55
61
|
"accounts": "the caller's tail at its natural indices, followed by the kitchen-signed acting Pot; the engine strips the acting Pot before execution",
|
|
56
62
|
"bytecode": "instruction data, after discriminator(8), owner(32), salt(32), bump(1)",
|