@thru/programs 0.3.5 → 0.3.7
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 +2 -3
- package/dist/amm/index.cjs +133 -32
- package/dist/amm/index.cjs.map +1 -1
- package/dist/amm/index.d.cts +1 -1
- package/dist/amm/index.d.ts +1 -1
- package/dist/amm/index.js +4 -1
- package/dist/amm/index.js.map +1 -1
- package/dist/bootstrap-addresses/index.cjs +118 -0
- package/dist/bootstrap-addresses/index.cjs.map +1 -0
- package/dist/bootstrap-addresses/index.d.cts +44 -0
- package/dist/bootstrap-addresses/index.d.ts +44 -0
- package/dist/bootstrap-addresses/index.js +5 -0
- package/dist/bootstrap-addresses/index.js.map +1 -0
- package/dist/chunk-7DHFYBRW.js +51 -0
- package/dist/chunk-7DHFYBRW.js.map +1 -0
- package/dist/{chunk-J7B7XYOI.js → chunk-CYG4PB65.js} +14 -41
- package/dist/chunk-CYG4PB65.js.map +1 -0
- package/dist/chunk-VNTPD4AR.js +37 -0
- package/dist/chunk-VNTPD4AR.js.map +1 -0
- package/dist/{chunk-OODN6LJA.js → chunk-ZHF2PH5H.js} +5 -36
- package/dist/chunk-ZHF2PH5H.js.map +1 -0
- package/dist/clob/index.cjs +225 -151
- package/dist/clob/index.cjs.map +1 -1
- package/dist/clob/index.d.cts +1 -1
- package/dist/clob/index.d.ts +1 -1
- package/dist/clob/index.js +5 -2
- package/dist/clob/index.js.map +1 -1
- package/dist/deploy/index.cjs +55 -38
- package/dist/deploy/index.cjs.map +1 -1
- package/dist/deploy/index.js +9 -6
- package/dist/deploy/index.js.map +1 -1
- package/dist/manager/index.js +2 -1
- package/dist/multicall/index.cjs +117 -40
- package/dist/multicall/index.cjs.map +1 -1
- package/dist/multicall/index.d.cts +5 -2
- package/dist/multicall/index.d.ts +5 -2
- package/dist/multicall/index.js +4 -1
- package/dist/oracle/index.cjs +122 -14
- package/dist/oracle/index.cjs.map +1 -1
- package/dist/oracle/index.d.cts +3 -1
- package/dist/oracle/index.d.ts +3 -1
- package/dist/oracle/index.js +7 -1
- package/dist/oracle/index.js.map +1 -1
- package/dist/passkey-manager/index.cjs +103 -1
- package/dist/passkey-manager/index.cjs.map +1 -1
- package/dist/passkey-manager/index.d.cts +1 -1
- package/dist/passkey-manager/index.d.ts +1 -1
- package/dist/passkey-manager/index.js +4 -1
- package/dist/passkey-manager/index.js.map +1 -1
- package/package.json +7 -2
- package/src/amm/index.test.ts +2 -12
- package/src/amm/index.ts +2 -2
- package/src/bootstrap-addresses/index.test.ts +59 -0
- package/src/bootstrap-addresses/index.ts +58 -0
- package/src/clob/index.test.ts +6 -0
- package/src/clob/index.ts +2 -2
- package/src/deploy/constants.ts +6 -1
- package/src/deploy/deploy.test.ts +3 -3
- package/src/deploy/workflows.test.ts +2 -2
- package/src/deploy/workflows.ts +4 -4
- package/src/multicall/index.test.ts +11 -2
- package/src/multicall/index.ts +12 -5
- package/src/oracle/index.ts +4 -0
- package/src/passkey-manager/constants.ts +2 -1
- package/src/passkey-manager/validate.test.ts +2 -2
- package/tsup.config.ts +1 -0
- package/dist/chunk-J7B7XYOI.js.map +0 -1
- package/dist/chunk-OODN6LJA.js.map +0 -1
package/dist/deploy/index.js
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
|
+
import { deriveProgramABIAddresses, ABI_MANAGER_PROGRAM_ADDRESS, parseABIMetaAccount, parseABIAccount, createOfficialABIMetaInstruction, createOfficialABIInstruction, ABI_STATE_FINALIZED, ABI_STATE_OPEN, createUpgradeOfficialABIInstruction } from '../chunk-6IC6CO5S.js';
|
|
1
2
|
import { deriveUploadAddresses, UPLOADER_DEFAULT_CHUNK_SIZE, UPLOADER_MIN_CHUNK_SIZE, UPLOADER_MAX_CHUNK_SIZE, createUploadBufferInstruction, UPLOADER_PROGRAM_ADDRESS, UPLOADER_STATE_FINALIZED, createWriteUploadInstruction, createFinalizeUploadInstruction, createDestroyUploadInstruction, UPLOADER_STATE_OPEN, parseUploaderProgramMeta } from '../chunk-BNYDH4ZP.js';
|
|
2
3
|
import { bytesEqual, sha256, bytesToHex } from '../chunk-7FBCBZIY.js';
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
4
|
+
import { GENESIS_MULTICALL_PROGRAM_ADDRESS, buildMulticallInstruction } from '../chunk-CYG4PB65.js';
|
|
5
|
+
import '../chunk-7DHFYBRW.js';
|
|
6
|
+
import { validateManagerProgramImage, parseManagerProgramMeta, createEphemeralProgramInstruction, createPermanentProgramInstruction, createUpgradeProgramInstruction } from '../chunk-ZHF2PH5H.js';
|
|
7
|
+
import { deriveManagedProgramAddresses, MANAGER_PROGRAM_ADDRESS, MANAGER_STATE_FINALIZED, MANAGER_STATE_OPEN } from '../chunk-VNTPD4AR.js';
|
|
6
8
|
import { normalizeSeed } from '../chunk-YX7BLFQZ.js';
|
|
7
9
|
import { Pubkey, createThruClient, Signature, SubmissionStatus, ConsensusStatus } from '@thru/sdk';
|
|
8
10
|
import { StateProofType } from '@thru/sdk/proto';
|
|
@@ -58,6 +60,7 @@ async function temporarySeed(seed, suffix) {
|
|
|
58
60
|
}
|
|
59
61
|
|
|
60
62
|
// src/deploy/constants.ts
|
|
63
|
+
var DEPLOYMENT_MULTICALL_PROGRAM_ADDRESS = GENESIS_MULTICALL_PROGRAM_ADDRESS;
|
|
61
64
|
var TRANSACTION_TIMEOUT_MS = 6e4;
|
|
62
65
|
|
|
63
66
|
// src/deploy/accounts.ts
|
|
@@ -1403,7 +1406,7 @@ async function deployProgram(request) {
|
|
|
1403
1406
|
)
|
|
1404
1407
|
]);
|
|
1405
1408
|
transaction = {
|
|
1406
|
-
program:
|
|
1409
|
+
program: DEPLOYMENT_MULTICALL_PROGRAM_ADDRESS,
|
|
1407
1410
|
stateUnits: 1e4,
|
|
1408
1411
|
memoryUnits: 1e4,
|
|
1409
1412
|
readWrite: [
|
|
@@ -1508,7 +1511,7 @@ async function deployProgramABI(request) {
|
|
|
1508
1511
|
)
|
|
1509
1512
|
]);
|
|
1510
1513
|
const transaction = {
|
|
1511
|
-
program:
|
|
1514
|
+
program: DEPLOYMENT_MULTICALL_PROGRAM_ADDRESS,
|
|
1512
1515
|
stateUnits: 1e4,
|
|
1513
1516
|
memoryUnits: 1e4,
|
|
1514
1517
|
readWrite: [
|
|
@@ -1604,7 +1607,7 @@ async function upgradeProgram(request) {
|
|
|
1604
1607
|
);
|
|
1605
1608
|
}
|
|
1606
1609
|
const transaction = abiBytes && abiUpload ? {
|
|
1607
|
-
program:
|
|
1610
|
+
program: DEPLOYMENT_MULTICALL_PROGRAM_ADDRESS,
|
|
1608
1611
|
stateUnits: 1e4,
|
|
1609
1612
|
memoryUnits: 1e4,
|
|
1610
1613
|
readWrite: [
|