@usesigil/kit 0.16.0 → 0.18.0
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 +56 -0
- package/dist/advanced-analytics.d.ts +3 -2
- package/dist/advanced-analytics.d.ts.map +1 -1
- package/dist/advanced-analytics.js +9 -42
- package/dist/advanced-analytics.js.map +1 -1
- package/dist/agent-bootstrap.d.ts +1 -2
- package/dist/agent-bootstrap.d.ts.map +1 -1
- package/dist/agent-bootstrap.js.map +1 -1
- package/dist/agent-errors.d.ts +20 -4
- package/dist/agent-errors.d.ts.map +1 -1
- package/dist/agent-errors.js +864 -367
- package/dist/agent-errors.js.map +1 -1
- package/dist/audit-log.d.ts +101 -0
- package/dist/audit-log.d.ts.map +1 -0
- package/dist/audit-log.js +145 -0
- package/dist/audit-log.js.map +1 -0
- package/dist/caip2-network.d.ts +171 -0
- package/dist/caip2-network.d.ts.map +1 -0
- package/dist/caip2-network.js +202 -0
- package/dist/caip2-network.js.map +1 -0
- package/dist/canonical-encode.d.ts +59 -0
- package/dist/canonical-encode.d.ts.map +1 -0
- package/dist/canonical-encode.js +141 -0
- package/dist/canonical-encode.js.map +1 -0
- package/dist/cosign-helper.d.ts +264 -0
- package/dist/cosign-helper.d.ts.map +1 -0
- package/dist/cosign-helper.js +147 -0
- package/dist/cosign-helper.js.map +1 -0
- package/dist/create-vault.d.ts +92 -0
- package/dist/create-vault.d.ts.map +1 -1
- package/dist/create-vault.js +108 -7
- package/dist/create-vault.js.map +1 -1
- package/dist/dashboard/close-vault.d.ts +110 -0
- package/dist/dashboard/close-vault.d.ts.map +1 -0
- package/dist/dashboard/close-vault.js +165 -0
- package/dist/dashboard/close-vault.js.map +1 -0
- package/dist/dashboard/errors.d.ts +2 -2
- package/dist/dashboard/errors.d.ts.map +1 -1
- package/dist/dashboard/errors.js +11 -7
- package/dist/dashboard/errors.js.map +1 -1
- package/dist/dashboard/index.d.ts +190 -34
- package/dist/dashboard/index.d.ts.map +1 -1
- package/dist/dashboard/index.js +282 -52
- package/dist/dashboard/index.js.map +1 -1
- package/dist/dashboard/mutations.d.ts +153 -24
- package/dist/dashboard/mutations.d.ts.map +1 -1
- package/dist/dashboard/mutations.js +680 -114
- package/dist/dashboard/mutations.js.map +1 -1
- package/dist/dashboard/post-assertion-validation.d.ts +1 -1
- package/dist/dashboard/post-assertion-validation.d.ts.map +1 -1
- package/dist/dashboard/post-assertion-validation.js +169 -48
- package/dist/dashboard/post-assertion-validation.js.map +1 -1
- package/dist/dashboard/reads.d.ts +3 -4
- package/dist/dashboard/reads.d.ts.map +1 -1
- package/dist/dashboard/reads.js +11 -22
- package/dist/dashboard/reads.js.map +1 -1
- package/dist/dashboard/types.d.ts +56 -19
- package/dist/dashboard/types.d.ts.map +1 -1
- package/dist/errors/agent-errors.generated.d.ts +21 -0
- package/dist/errors/agent-errors.generated.d.ts.map +1 -0
- package/dist/errors/agent-errors.generated.js +134 -0
- package/dist/errors/agent-errors.generated.js.map +1 -0
- package/dist/errors/codes.d.ts +21 -2
- package/dist/errors/codes.d.ts.map +1 -1
- package/dist/errors/codes.js +19 -0
- package/dist/errors/codes.js.map +1 -1
- package/dist/errors/context.d.ts +9 -1
- package/dist/errors/context.d.ts.map +1 -1
- package/dist/event-analytics.d.ts +1 -3
- package/dist/event-analytics.d.ts.map +1 -1
- package/dist/event-analytics.js +28 -81
- package/dist/event-analytics.js.map +1 -1
- package/dist/events.d.ts.map +1 -1
- package/dist/events.js +23 -14
- package/dist/events.js.map +1 -1
- package/dist/generated/accounts/agentSpendOverlay.d.ts +60 -0
- package/dist/generated/accounts/agentSpendOverlay.d.ts.map +1 -1
- package/dist/generated/accounts/agentSpendOverlay.js +6 -2
- package/dist/generated/accounts/agentSpendOverlay.js.map +1 -1
- package/dist/generated/accounts/agentVault.d.ts +168 -4
- package/dist/generated/accounts/agentVault.d.ts.map +1 -1
- package/dist/generated/accounts/agentVault.js +11 -3
- package/dist/generated/accounts/agentVault.js.map +1 -1
- package/dist/generated/accounts/auditLogRejected.d.ts +66 -0
- package/dist/generated/accounts/auditLogRejected.d.ts.map +1 -0
- package/dist/generated/accounts/auditLogRejected.js +68 -0
- package/dist/generated/accounts/auditLogRejected.js.map +1 -0
- package/dist/generated/accounts/auditLogSuccess.d.ts +78 -0
- package/dist/generated/accounts/auditLogSuccess.d.ts.map +1 -0
- package/dist/generated/accounts/auditLogSuccess.js +68 -0
- package/dist/generated/accounts/auditLogSuccess.js.map +1 -0
- package/dist/generated/accounts/index.d.ts +4 -4
- package/dist/generated/accounts/index.d.ts.map +1 -1
- package/dist/generated/accounts/index.js +4 -4
- package/dist/generated/accounts/index.js.map +1 -1
- package/dist/generated/accounts/pendingAgentGrant.d.ts +199 -0
- package/dist/generated/accounts/pendingAgentGrant.d.ts.map +1 -0
- package/dist/generated/accounts/pendingAgentGrant.js +75 -0
- package/dist/generated/accounts/pendingAgentGrant.js.map +1 -0
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.d.ts +64 -0
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.d.ts.map +1 -1
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.js +7 -1
- package/dist/generated/accounts/pendingAgentPermissionsUpdate.js.map +1 -1
- package/dist/generated/accounts/pendingOwnershipTransfer.d.ts +131 -0
- package/dist/generated/accounts/pendingOwnershipTransfer.d.ts.map +1 -0
- package/dist/generated/accounts/pendingOwnershipTransfer.js +76 -0
- package/dist/generated/accounts/pendingOwnershipTransfer.js.map +1 -0
- package/dist/generated/accounts/pendingPolicyUpdate.d.ts +200 -4
- package/dist/generated/accounts/pendingPolicyUpdate.d.ts.map +1 -1
- package/dist/generated/accounts/pendingPolicyUpdate.js +19 -1
- package/dist/generated/accounts/pendingPolicyUpdate.js.map +1 -1
- package/dist/generated/accounts/policyConfig.d.ts +479 -36
- package/dist/generated/accounts/policyConfig.d.ts.map +1 -1
- package/dist/generated/accounts/policyConfig.js +30 -3
- package/dist/generated/accounts/policyConfig.js.map +1 -1
- package/dist/generated/accounts/postExecutionAssertions.d.ts +2 -2
- package/dist/generated/accounts/postExecutionAssertions.d.ts.map +1 -1
- package/dist/generated/accounts/postExecutionAssertions.js +3 -3
- package/dist/generated/accounts/sessionAuthority.d.ts +140 -12
- package/dist/generated/accounts/sessionAuthority.d.ts.map +1 -1
- package/dist/generated/accounts/sessionAuthority.js +9 -7
- package/dist/generated/accounts/sessionAuthority.js.map +1 -1
- package/dist/generated/accounts/spendTracker.d.ts +83 -3
- package/dist/generated/accounts/spendTracker.d.ts.map +1 -1
- package/dist/generated/accounts/spendTracker.js +14 -2
- package/dist/generated/accounts/spendTracker.js.map +1 -1
- package/dist/generated/errors/sigil.d.ts +131 -83
- package/dist/generated/errors/sigil.d.ts.map +1 -1
- package/dist/generated/errors/sigil.js +178 -106
- package/dist/generated/errors/sigil.js.map +1 -1
- package/dist/generated/event-discriminators.d.ts.map +1 -1
- package/dist/generated/event-discriminators.js +11 -14
- package/dist/generated/event-discriminators.js.map +1 -1
- package/dist/generated/instructions/acceptOwnershipTransfer.d.ts +142 -0
- package/dist/generated/instructions/acceptOwnershipTransfer.d.ts.map +1 -0
- package/dist/generated/instructions/acceptOwnershipTransfer.js +171 -0
- package/dist/generated/instructions/acceptOwnershipTransfer.js.map +1 -0
- package/dist/generated/instructions/acceptOwnershipTransferMultisig.d.ts +85 -0
- package/dist/generated/instructions/acceptOwnershipTransferMultisig.d.ts.map +1 -0
- package/dist/generated/instructions/acceptOwnershipTransferMultisig.js +171 -0
- package/dist/generated/instructions/acceptOwnershipTransferMultisig.js.map +1 -0
- package/dist/generated/instructions/applyAgentGrant.d.ts +100 -0
- package/dist/generated/instructions/applyAgentGrant.d.ts.map +1 -0
- package/dist/generated/instructions/{applyConstraintsUpdate.js → applyAgentGrant.js} +66 -42
- package/dist/generated/instructions/applyAgentGrant.js.map +1 -0
- package/dist/generated/instructions/applyAgentPermissionsUpdate.d.ts +31 -8
- package/dist/generated/instructions/applyAgentPermissionsUpdate.d.ts.map +1 -1
- package/dist/generated/instructions/applyAgentPermissionsUpdate.js +38 -2
- package/dist/generated/instructions/applyAgentPermissionsUpdate.js.map +1 -1
- package/dist/generated/instructions/applyPendingPolicy.d.ts +18 -7
- package/dist/generated/instructions/applyPendingPolicy.d.ts.map +1 -1
- package/dist/generated/instructions/applyPendingPolicy.js +38 -2
- package/dist/generated/instructions/applyPendingPolicy.js.map +1 -1
- package/dist/generated/instructions/cancelAgentGrant.d.ts +106 -0
- package/dist/generated/instructions/cancelAgentGrant.d.ts.map +1 -0
- package/dist/generated/instructions/{allocatePendingConstraintsPda.js → cancelAgentGrant.js} +54 -42
- package/dist/generated/instructions/cancelAgentGrant.js.map +1 -0
- package/dist/generated/instructions/cancelOwnershipTransfer.d.ts +121 -0
- package/dist/generated/instructions/cancelOwnershipTransfer.d.ts.map +1 -0
- package/dist/generated/instructions/{queueCloseConstraints.js → cancelOwnershipTransfer.js} +58 -44
- package/dist/generated/instructions/cancelOwnershipTransfer.js.map +1 -0
- package/dist/generated/instructions/closePostAssertions.d.ts +6 -1
- package/dist/generated/instructions/closePostAssertions.d.ts.map +1 -1
- package/dist/generated/instructions/closePostAssertions.js +11 -3
- package/dist/generated/instructions/closePostAssertions.js.map +1 -1
- package/dist/generated/instructions/closeVault.d.ts +40 -8
- package/dist/generated/instructions/closeVault.d.ts.map +1 -1
- package/dist/generated/instructions/closeVault.js +40 -2
- package/dist/generated/instructions/closeVault.js.map +1 -1
- package/dist/generated/instructions/createPostAssertions.d.ts +4 -0
- package/dist/generated/instructions/createPostAssertions.d.ts.map +1 -1
- package/dist/generated/instructions/createPostAssertions.js +2 -0
- package/dist/generated/instructions/createPostAssertions.js.map +1 -1
- package/dist/generated/instructions/depositFunds.d.ts +21 -10
- package/dist/generated/instructions/depositFunds.d.ts.map +1 -1
- package/dist/generated/instructions/depositFunds.js +37 -2
- package/dist/generated/instructions/depositFunds.js.map +1 -1
- package/dist/generated/instructions/finalizeSession.d.ts +49 -7
- package/dist/generated/instructions/finalizeSession.d.ts.map +1 -1
- package/dist/generated/instructions/finalizeSession.js +59 -2
- package/dist/generated/instructions/finalizeSession.js.map +1 -1
- package/dist/generated/instructions/freezeVault.d.ts +36 -5
- package/dist/generated/instructions/freezeVault.d.ts.map +1 -1
- package/dist/generated/instructions/freezeVault.js +65 -4
- package/dist/generated/instructions/freezeVault.js.map +1 -1
- package/dist/generated/instructions/index.d.ts +10 -15
- package/dist/generated/instructions/index.d.ts.map +1 -1
- package/dist/generated/instructions/index.js +10 -15
- package/dist/generated/instructions/index.js.map +1 -1
- package/dist/generated/instructions/initializeVault.d.ts +79 -9
- package/dist/generated/instructions/initializeVault.d.ts.map +1 -1
- package/dist/generated/instructions/initializeVault.js +57 -3
- package/dist/generated/instructions/initializeVault.js.map +1 -1
- package/dist/generated/instructions/initiateOwnershipTransfer.d.ts +106 -0
- package/dist/generated/instructions/initiateOwnershipTransfer.d.ts.map +1 -0
- package/dist/generated/instructions/initiateOwnershipTransfer.js +181 -0
- package/dist/generated/instructions/initiateOwnershipTransfer.js.map +1 -0
- package/dist/generated/instructions/pauseAgent.d.ts +49 -5
- package/dist/generated/instructions/pauseAgent.d.ts.map +1 -1
- package/dist/generated/instructions/pauseAgent.js +80 -5
- package/dist/generated/instructions/pauseAgent.js.map +1 -1
- package/dist/generated/instructions/promoteGraylistDestination.d.ts +56 -0
- package/dist/generated/instructions/promoteGraylistDestination.d.ts.map +1 -0
- package/dist/generated/instructions/{createInstructionConstraints.js → promoteGraylistDestination.js} +23 -40
- package/dist/generated/instructions/promoteGraylistDestination.js.map +1 -0
- package/dist/generated/instructions/queueAgentGrant.d.ts +113 -0
- package/dist/generated/instructions/queueAgentGrant.d.ts.map +1 -0
- package/dist/generated/instructions/queueAgentGrant.js +181 -0
- package/dist/generated/instructions/queueAgentGrant.js.map +1 -0
- package/dist/generated/instructions/queueAgentPermissionsUpdate.d.ts +8 -0
- package/dist/generated/instructions/queueAgentPermissionsUpdate.d.ts.map +1 -1
- package/dist/generated/instructions/queueAgentPermissionsUpdate.js +4 -0
- package/dist/generated/instructions/queueAgentPermissionsUpdate.js.map +1 -1
- package/dist/generated/instructions/queuePolicyUpdate.d.ts +32 -0
- package/dist/generated/instructions/queuePolicyUpdate.d.ts.map +1 -1
- package/dist/generated/instructions/queuePolicyUpdate.js +17 -1
- package/dist/generated/instructions/queuePolicyUpdate.js.map +1 -1
- package/dist/generated/instructions/reactivateVault.d.ts +71 -5
- package/dist/generated/instructions/reactivateVault.d.ts.map +1 -1
- package/dist/generated/instructions/reactivateVault.js +80 -5
- package/dist/generated/instructions/reactivateVault.js.map +1 -1
- package/dist/generated/instructions/recordAgentViolation.d.ts +89 -0
- package/dist/generated/instructions/recordAgentViolation.d.ts.map +1 -0
- package/dist/generated/instructions/recordAgentViolation.js +152 -0
- package/dist/generated/instructions/recordAgentViolation.js.map +1 -0
- package/dist/generated/instructions/registerAgent.d.ts +84 -6
- package/dist/generated/instructions/registerAgent.d.ts.map +1 -1
- package/dist/generated/instructions/registerAgent.js +81 -4
- package/dist/generated/instructions/registerAgent.js.map +1 -1
- package/dist/generated/instructions/revokeAgent.d.ts +49 -6
- package/dist/generated/instructions/revokeAgent.d.ts.map +1 -1
- package/dist/generated/instructions/revokeAgent.js +81 -4
- package/dist/generated/instructions/revokeAgent.js.map +1 -1
- package/dist/generated/instructions/setObserveOnly.d.ts +56 -0
- package/dist/generated/instructions/setObserveOnly.d.ts.map +1 -0
- package/dist/generated/instructions/setObserveOnly.js +111 -0
- package/dist/generated/instructions/setObserveOnly.js.map +1 -0
- package/dist/generated/instructions/unpauseAgent.d.ts +46 -5
- package/dist/generated/instructions/unpauseAgent.d.ts.map +1 -1
- package/dist/generated/instructions/unpauseAgent.js +80 -5
- package/dist/generated/instructions/unpauseAgent.js.map +1 -1
- package/dist/generated/instructions/validateAndAuthorize.d.ts +29 -0
- package/dist/generated/instructions/validateAndAuthorize.d.ts.map +1 -1
- package/dist/generated/instructions/validateAndAuthorize.js +4 -0
- package/dist/generated/instructions/validateAndAuthorize.js.map +1 -1
- package/dist/generated/instructions/withdrawFunds.d.ts +53 -11
- package/dist/generated/instructions/withdrawFunds.d.ts.map +1 -1
- package/dist/generated/instructions/withdrawFunds.js +51 -2
- package/dist/generated/instructions/withdrawFunds.js.map +1 -1
- package/dist/generated/programs/sigil.d.ts +79 -99
- package/dist/generated/programs/sigil.d.ts.map +1 -1
- package/dist/generated/programs/sigil.js +139 -199
- package/dist/generated/programs/sigil.js.map +1 -1
- package/dist/generated/types/actionAuthorized.d.ts +0 -2
- package/dist/generated/types/actionAuthorized.d.ts.map +1 -1
- package/dist/generated/types/actionAuthorized.js +0 -2
- package/dist/generated/types/actionAuthorized.js.map +1 -1
- package/dist/generated/types/agentAutoRevoked.d.ts +31 -0
- package/dist/generated/types/agentAutoRevoked.d.ts.map +1 -0
- package/dist/generated/types/{orphanConstraintsPdaCleaned.js → agentAutoRevoked.js} +12 -8
- package/dist/generated/types/agentAutoRevoked.js.map +1 -0
- package/dist/generated/types/agentEntry.d.ts +48 -0
- package/dist/generated/types/agentEntry.d.ts.map +1 -1
- package/dist/generated/types/agentEntry.js +4 -2
- package/dist/generated/types/agentEntry.js.map +1 -1
- package/dist/generated/types/agentGrantApplied.d.ts +38 -0
- package/dist/generated/types/agentGrantApplied.d.ts.map +1 -0
- package/dist/generated/types/agentGrantApplied.js +34 -0
- package/dist/generated/types/agentGrantApplied.js.map +1 -0
- package/dist/generated/types/agentGrantCancelled.d.ts +33 -0
- package/dist/generated/types/agentGrantCancelled.d.ts.map +1 -0
- package/dist/generated/types/agentGrantCancelled.js +28 -0
- package/dist/generated/types/agentGrantCancelled.js.map +1 -0
- package/dist/generated/types/agentGrantQueued.d.ts +38 -0
- package/dist/generated/types/agentGrantQueued.d.ts.map +1 -0
- package/dist/generated/types/agentGrantQueued.js +32 -0
- package/dist/generated/types/agentGrantQueued.js.map +1 -0
- package/dist/generated/types/auditEntry.d.ts +120 -0
- package/dist/generated/types/auditEntry.d.ts.map +1 -0
- package/dist/generated/types/auditEntry.js +34 -0
- package/dist/generated/types/auditEntry.js.map +1 -0
- package/dist/generated/types/destinationGraylistEntry.d.ts +32 -0
- package/dist/generated/types/destinationGraylistEntry.d.ts.map +1 -0
- package/dist/generated/types/destinationGraylistEntry.js +24 -0
- package/dist/generated/types/destinationGraylistEntry.js.map +1 -0
- package/dist/generated/types/graylistEntered.d.ts +31 -0
- package/dist/generated/types/graylistEntered.d.ts.map +1 -0
- package/dist/generated/types/graylistEntered.js +30 -0
- package/dist/generated/types/graylistEntered.js.map +1 -0
- package/dist/generated/types/graylistPromoted.d.ts +29 -0
- package/dist/generated/types/graylistPromoted.d.ts.map +1 -0
- package/dist/generated/types/graylistPromoted.js +28 -0
- package/dist/generated/types/graylistPromoted.js.map +1 -0
- package/dist/generated/types/index.d.ts +13 -22
- package/dist/generated/types/index.d.ts.map +1 -1
- package/dist/generated/types/index.js +13 -22
- package/dist/generated/types/index.js.map +1 -1
- package/dist/generated/types/observeOnlyChanged.d.ts +33 -0
- package/dist/generated/types/observeOnlyChanged.d.ts.map +1 -0
- package/dist/generated/types/observeOnlyChanged.js +32 -0
- package/dist/generated/types/observeOnlyChanged.js.map +1 -0
- package/dist/generated/types/ownershipTransferAccepted.d.ts +32 -0
- package/dist/generated/types/ownershipTransferAccepted.d.ts.map +1 -0
- package/dist/generated/types/ownershipTransferAccepted.js +30 -0
- package/dist/generated/types/ownershipTransferAccepted.js.map +1 -0
- package/dist/generated/types/ownershipTransferCancelled.d.ts +29 -0
- package/dist/generated/types/ownershipTransferCancelled.d.ts.map +1 -0
- package/dist/generated/types/ownershipTransferCancelled.js +28 -0
- package/dist/generated/types/ownershipTransferCancelled.js.map +1 -0
- package/dist/generated/types/ownershipTransferInitiated.d.ts +33 -0
- package/dist/generated/types/ownershipTransferInitiated.d.ts.map +1 -0
- package/dist/generated/types/ownershipTransferInitiated.js +30 -0
- package/dist/generated/types/ownershipTransferInitiated.js.map +1 -0
- package/dist/generated/types/perRecipientCounter.d.ts +61 -0
- package/dist/generated/types/perRecipientCounter.d.ts.map +1 -0
- package/dist/generated/types/perRecipientCounter.js +26 -0
- package/dist/generated/types/perRecipientCounter.js.map +1 -0
- package/dist/generated/types/postAssertionEntry.d.ts +14 -7
- package/dist/generated/types/postAssertionEntry.d.ts.map +1 -1
- package/dist/generated/types/postAssertionEntry.js +5 -7
- package/dist/generated/types/postAssertionEntry.js.map +1 -1
- package/dist/generated/types/postAssertionEntryZC.d.ts +53 -22
- package/dist/generated/types/postAssertionEntryZC.d.ts.map +1 -1
- package/dist/generated/types/postAssertionEntryZC.js +4 -6
- package/dist/generated/types/postAssertionEntryZC.js.map +1 -1
- package/dist/generated/types/sessionFinalized.d.ts +0 -4
- package/dist/generated/types/sessionFinalized.d.ts.map +1 -1
- package/dist/generated/types/sessionFinalized.js +0 -2
- package/dist/generated/types/sessionFinalized.js.map +1 -1
- package/dist/generated/types/vaultFrozen.d.ts +14 -0
- package/dist/generated/types/vaultFrozen.d.ts.map +1 -1
- package/dist/generated/types/vaultFrozen.js +2 -0
- package/dist/generated/types/vaultFrozen.js.map +1 -1
- package/dist/index.d.ts +31 -9
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +67 -11
- package/dist/index.js.map +1 -1
- package/dist/inspector.d.ts +0 -23
- package/dist/inspector.d.ts.map +1 -1
- package/dist/inspector.js +0 -52
- package/dist/inspector.js.map +1 -1
- package/dist/kit-adapter.d.ts +1 -1
- package/dist/kit-adapter.d.ts.map +1 -1
- package/dist/kit-adapter.js +1 -1
- package/dist/kit-adapter.js.map +1 -1
- package/dist/multisig-detection.d.ts +83 -0
- package/dist/multisig-detection.d.ts.map +1 -0
- package/dist/multisig-detection.js +128 -0
- package/dist/multisig-detection.js.map +1 -0
- package/dist/ownership-transfer.d.ts +79 -0
- package/dist/ownership-transfer.d.ts.map +1 -0
- package/dist/ownership-transfer.js +66 -0
- package/dist/ownership-transfer.js.map +1 -0
- package/dist/policy/compute-agent-perms-cosign-digest.d.ts +51 -0
- package/dist/policy/compute-agent-perms-cosign-digest.d.ts.map +1 -0
- package/dist/policy/compute-agent-perms-cosign-digest.js +55 -0
- package/dist/policy/compute-agent-perms-cosign-digest.js.map +1 -0
- package/dist/policy/compute-cosign-digest.d.ts +193 -0
- package/dist/policy/compute-cosign-digest.d.ts.map +1 -0
- package/dist/policy/compute-cosign-digest.js +318 -0
- package/dist/policy/compute-cosign-digest.js.map +1 -0
- package/dist/policy/compute-policy-preview-digest.d.ts +279 -0
- package/dist/policy/compute-policy-preview-digest.d.ts.map +1 -0
- package/dist/policy/compute-policy-preview-digest.js +373 -0
- package/dist/policy/compute-policy-preview-digest.js.map +1 -0
- package/dist/policy-attestation.d.ts +51 -0
- package/dist/policy-attestation.d.ts.map +1 -0
- package/dist/policy-attestation.js +43 -0
- package/dist/policy-attestation.js.map +1 -0
- package/dist/preview-create-vault.d.ts.map +1 -1
- package/dist/preview-create-vault.js +37 -16
- package/dist/preview-create-vault.js.map +1 -1
- package/dist/resolve-accounts.d.ts +75 -10
- package/dist/resolve-accounts.d.ts.map +1 -1
- package/dist/resolve-accounts.js +68 -32
- package/dist/resolve-accounts.js.map +1 -1
- package/dist/rpc-helpers.d.ts +29 -3
- package/dist/rpc-helpers.d.ts.map +1 -1
- package/dist/rpc-helpers.js +51 -12
- package/dist/rpc-helpers.js.map +1 -1
- package/dist/seal/intent-digest.d.ts +195 -0
- package/dist/seal/intent-digest.d.ts.map +1 -0
- package/dist/seal/intent-digest.js +372 -0
- package/dist/seal/intent-digest.js.map +1 -0
- package/dist/seal.d.ts +166 -3
- package/dist/seal.d.ts.map +1 -1
- package/dist/seal.js +428 -32
- package/dist/seal.js.map +1 -1
- package/dist/security-analytics.d.ts +3 -3
- package/dist/security-analytics.d.ts.map +1 -1
- package/dist/security-analytics.js +13 -128
- package/dist/security-analytics.js.map +1 -1
- package/dist/session-mint.d.ts +72 -0
- package/dist/session-mint.d.ts.map +1 -0
- package/dist/session-mint.js +59 -0
- package/dist/session-mint.js.map +1 -0
- package/dist/simulation.d.ts +19 -0
- package/dist/simulation.d.ts.map +1 -1
- package/dist/simulation.js +187 -95
- package/dist/simulation.js.map +1 -1
- package/dist/squads-detection.d.ts +135 -0
- package/dist/squads-detection.d.ts.map +1 -0
- package/dist/squads-detection.js +124 -0
- package/dist/squads-detection.js.map +1 -0
- package/dist/state-resolver.d.ts +0 -16
- package/dist/state-resolver.d.ts.map +1 -1
- package/dist/state-resolver.js +162 -97
- package/dist/state-resolver.js.map +1 -1
- package/dist/testing/devnet.d.ts +40 -1
- package/dist/testing/devnet.d.ts.map +1 -1
- package/dist/testing/devnet.js +333 -44
- package/dist/testing/devnet.js.map +1 -1
- package/dist/testing/errors/expect.d.ts +1 -1
- package/dist/testing/errors/expect.js +1 -1
- package/dist/testing/errors/names.generated.d.ts +82 -58
- package/dist/testing/errors/names.generated.d.ts.map +1 -1
- package/dist/testing/errors/names.generated.js +83 -59
- package/dist/testing/errors/names.generated.js.map +1 -1
- package/dist/testing/mock-rpc.d.ts +8 -0
- package/dist/testing/mock-rpc.d.ts.map +1 -1
- package/dist/testing/mock-rpc.js +13 -0
- package/dist/testing/mock-rpc.js.map +1 -1
- package/dist/testing/mock-state.d.ts +2 -0
- package/dist/testing/mock-state.d.ts.map +1 -1
- package/dist/testing/mock-state.js +43 -4
- package/dist/testing/mock-state.js.map +1 -1
- package/dist/types.d.ts +5 -15
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +11 -69
- package/dist/types.js.map +1 -1
- package/dist/vault-analytics.d.ts +0 -2
- package/dist/vault-analytics.d.ts.map +1 -1
- package/dist/vault-analytics.js +1 -9
- package/dist/vault-analytics.js.map +1 -1
- package/package.json +7 -12
- package/dist/constraints/index.d.ts +0 -23
- package/dist/constraints/index.d.ts.map +0 -1
- package/dist/constraints/index.js +0 -24
- package/dist/constraints/index.js.map +0 -1
- package/dist/dashboard/constraint-builders.d.ts +0 -82
- package/dist/dashboard/constraint-builders.d.ts.map +0 -1
- package/dist/dashboard/constraint-builders.js +0 -204
- package/dist/dashboard/constraint-builders.js.map +0 -1
- package/dist/dashboard/constraint-reads.d.ts +0 -50
- package/dist/dashboard/constraint-reads.d.ts.map +0 -1
- package/dist/dashboard/constraint-reads.js +0 -119
- package/dist/dashboard/constraint-reads.js.map +0 -1
- package/dist/generated/accounts/escrowDeposit.d.ts +0 -50
- package/dist/generated/accounts/escrowDeposit.d.ts.map +0 -1
- package/dist/generated/accounts/escrowDeposit.js +0 -76
- package/dist/generated/accounts/escrowDeposit.js.map +0 -1
- package/dist/generated/accounts/instructionConstraints.d.ts +0 -46
- package/dist/generated/accounts/instructionConstraints.d.ts.map +0 -1
- package/dist/generated/accounts/instructionConstraints.js +0 -73
- package/dist/generated/accounts/instructionConstraints.js.map +0 -1
- package/dist/generated/accounts/pendingCloseConstraints.d.ts +0 -49
- package/dist/generated/accounts/pendingCloseConstraints.d.ts.map +0 -1
- package/dist/generated/accounts/pendingCloseConstraints.js +0 -68
- package/dist/generated/accounts/pendingCloseConstraints.js.map +0 -1
- package/dist/generated/accounts/pendingConstraintsUpdate.d.ts +0 -76
- package/dist/generated/accounts/pendingConstraintsUpdate.d.ts.map +0 -1
- package/dist/generated/accounts/pendingConstraintsUpdate.js +0 -77
- package/dist/generated/accounts/pendingConstraintsUpdate.js.map +0 -1
- package/dist/generated/instructions/allocateConstraintsPda.d.ts +0 -62
- package/dist/generated/instructions/allocateConstraintsPda.d.ts.map +0 -1
- package/dist/generated/instructions/allocateConstraintsPda.js +0 -134
- package/dist/generated/instructions/allocateConstraintsPda.js.map +0 -1
- package/dist/generated/instructions/allocatePendingConstraintsPda.d.ts +0 -66
- package/dist/generated/instructions/allocatePendingConstraintsPda.d.ts.map +0 -1
- package/dist/generated/instructions/allocatePendingConstraintsPda.js.map +0 -1
- package/dist/generated/instructions/applyCloseConstraints.d.ts +0 -59
- package/dist/generated/instructions/applyCloseConstraints.d.ts.map +0 -1
- package/dist/generated/instructions/applyCloseConstraints.js +0 -143
- package/dist/generated/instructions/applyCloseConstraints.js.map +0 -1
- package/dist/generated/instructions/applyConstraintsUpdate.d.ts +0 -62
- package/dist/generated/instructions/applyConstraintsUpdate.d.ts.map +0 -1
- package/dist/generated/instructions/applyConstraintsUpdate.js.map +0 -1
- package/dist/generated/instructions/cancelCloseConstraints.d.ts +0 -51
- package/dist/generated/instructions/cancelCloseConstraints.d.ts.map +0 -1
- package/dist/generated/instructions/cancelCloseConstraints.js +0 -115
- package/dist/generated/instructions/cancelCloseConstraints.js.map +0 -1
- package/dist/generated/instructions/cancelConstraintsUpdate.d.ts +0 -51
- package/dist/generated/instructions/cancelConstraintsUpdate.d.ts.map +0 -1
- package/dist/generated/instructions/cancelConstraintsUpdate.js +0 -115
- package/dist/generated/instructions/cancelConstraintsUpdate.js.map +0 -1
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.d.ts +0 -67
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.d.ts.map +0 -1
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.js +0 -120
- package/dist/generated/instructions/cleanupOrphanConstraintsPda.js.map +0 -1
- package/dist/generated/instructions/closeSettledEscrow.d.ts +0 -72
- package/dist/generated/instructions/closeSettledEscrow.d.ts.map +0 -1
- package/dist/generated/instructions/closeSettledEscrow.js +0 -127
- package/dist/generated/instructions/closeSettledEscrow.js.map +0 -1
- package/dist/generated/instructions/createEscrow.d.ts +0 -131
- package/dist/generated/instructions/createEscrow.d.ts.map +0 -1
- package/dist/generated/instructions/createEscrow.js +0 -272
- package/dist/generated/instructions/createEscrow.js.map +0 -1
- package/dist/generated/instructions/createInstructionConstraints.d.ts +0 -68
- package/dist/generated/instructions/createInstructionConstraints.d.ts.map +0 -1
- package/dist/generated/instructions/createInstructionConstraints.js.map +0 -1
- package/dist/generated/instructions/extendPda.d.ts +0 -52
- package/dist/generated/instructions/extendPda.d.ts.map +0 -1
- package/dist/generated/instructions/extendPda.js +0 -86
- package/dist/generated/instructions/extendPda.js.map +0 -1
- package/dist/generated/instructions/queueCloseConstraints.d.ts +0 -66
- package/dist/generated/instructions/queueCloseConstraints.d.ts.map +0 -1
- package/dist/generated/instructions/queueCloseConstraints.js.map +0 -1
- package/dist/generated/instructions/queueConstraintsUpdate.d.ts +0 -75
- package/dist/generated/instructions/queueConstraintsUpdate.d.ts.map +0 -1
- package/dist/generated/instructions/queueConstraintsUpdate.js +0 -154
- package/dist/generated/instructions/queueConstraintsUpdate.js.map +0 -1
- package/dist/generated/instructions/refundEscrow.d.ts +0 -74
- package/dist/generated/instructions/refundEscrow.d.ts.map +0 -1
- package/dist/generated/instructions/refundEscrow.js +0 -142
- package/dist/generated/instructions/refundEscrow.js.map +0 -1
- package/dist/generated/instructions/settleEscrow.d.ts +0 -80
- package/dist/generated/instructions/settleEscrow.d.ts.map +0 -1
- package/dist/generated/instructions/settleEscrow.js +0 -173
- package/dist/generated/instructions/settleEscrow.js.map +0 -1
- package/dist/generated/types/accountConstraint.d.ts +0 -33
- package/dist/generated/types/accountConstraint.d.ts.map +0 -1
- package/dist/generated/types/accountConstraint.js +0 -26
- package/dist/generated/types/accountConstraint.js.map +0 -1
- package/dist/generated/types/accountConstraintZC.d.ts +0 -25
- package/dist/generated/types/accountConstraintZC.d.ts.map +0 -1
- package/dist/generated/types/accountConstraintZC.js +0 -28
- package/dist/generated/types/accountConstraintZC.js.map +0 -1
- package/dist/generated/types/closeConstraintsApplied.d.ts +0 -20
- package/dist/generated/types/closeConstraintsApplied.d.ts.map +0 -1
- package/dist/generated/types/closeConstraintsApplied.js +0 -24
- package/dist/generated/types/closeConstraintsApplied.js.map +0 -1
- package/dist/generated/types/closeConstraintsCancelled.d.ts +0 -16
- package/dist/generated/types/closeConstraintsCancelled.d.ts.map +0 -1
- package/dist/generated/types/closeConstraintsCancelled.js +0 -18
- package/dist/generated/types/closeConstraintsCancelled.js.map +0 -1
- package/dist/generated/types/closeConstraintsQueued.d.ts +0 -20
- package/dist/generated/types/closeConstraintsQueued.d.ts.map +0 -1
- package/dist/generated/types/closeConstraintsQueued.js +0 -24
- package/dist/generated/types/closeConstraintsQueued.js.map +0 -1
- package/dist/generated/types/constraintEntry.d.ts +0 -35
- package/dist/generated/types/constraintEntry.d.ts.map +0 -1
- package/dist/generated/types/constraintEntry.js +0 -29
- package/dist/generated/types/constraintEntry.js.map +0 -1
- package/dist/generated/types/constraintEntryZC.d.ts +0 -73
- package/dist/generated/types/constraintEntryZC.d.ts.map +0 -1
- package/dist/generated/types/constraintEntryZC.js +0 -49
- package/dist/generated/types/constraintEntryZC.js.map +0 -1
- package/dist/generated/types/constraintOperator.d.ts +0 -22
- package/dist/generated/types/constraintOperator.d.ts.map +0 -1
- package/dist/generated/types/constraintOperator.js +0 -28
- package/dist/generated/types/constraintOperator.js.map +0 -1
- package/dist/generated/types/constraintsChangeApplied.d.ts +0 -30
- package/dist/generated/types/constraintsChangeApplied.d.ts.map +0 -1
- package/dist/generated/types/constraintsChangeApplied.js +0 -32
- package/dist/generated/types/constraintsChangeApplied.js.map +0 -1
- package/dist/generated/types/constraintsChangeCancelled.d.ts +0 -16
- package/dist/generated/types/constraintsChangeCancelled.d.ts.map +0 -1
- package/dist/generated/types/constraintsChangeCancelled.js +0 -18
- package/dist/generated/types/constraintsChangeCancelled.js.map +0 -1
- package/dist/generated/types/constraintsChangeQueued.d.ts +0 -30
- package/dist/generated/types/constraintsChangeQueued.d.ts.map +0 -1
- package/dist/generated/types/constraintsChangeQueued.js +0 -32
- package/dist/generated/types/constraintsChangeQueued.js.map +0 -1
- package/dist/generated/types/dataConstraint.d.ts +0 -23
- package/dist/generated/types/dataConstraint.d.ts.map +0 -1
- package/dist/generated/types/dataConstraint.js +0 -27
- package/dist/generated/types/dataConstraint.js.map +0 -1
- package/dist/generated/types/dataConstraintZC.d.ts +0 -20
- package/dist/generated/types/dataConstraintZC.d.ts.map +0 -1
- package/dist/generated/types/dataConstraintZC.js +0 -30
- package/dist/generated/types/dataConstraintZC.js.map +0 -1
- package/dist/generated/types/discriminatorFormat.d.ts +0 -25
- package/dist/generated/types/discriminatorFormat.d.ts.map +0 -1
- package/dist/generated/types/discriminatorFormat.js +0 -31
- package/dist/generated/types/discriminatorFormat.js.map +0 -1
- package/dist/generated/types/escrowCreated.d.ts +0 -30
- package/dist/generated/types/escrowCreated.d.ts.map +0 -1
- package/dist/generated/types/escrowCreated.js +0 -34
- package/dist/generated/types/escrowCreated.js.map +0 -1
- package/dist/generated/types/escrowRefunded.d.ts +0 -26
- package/dist/generated/types/escrowRefunded.d.ts.map +0 -1
- package/dist/generated/types/escrowRefunded.js +0 -30
- package/dist/generated/types/escrowRefunded.js.map +0 -1
- package/dist/generated/types/escrowSettled.d.ts +0 -26
- package/dist/generated/types/escrowSettled.d.ts.map +0 -1
- package/dist/generated/types/escrowSettled.js +0 -30
- package/dist/generated/types/escrowSettled.js.map +0 -1
- package/dist/generated/types/escrowStatus.d.ts +0 -18
- package/dist/generated/types/escrowStatus.d.ts.map +0 -1
- package/dist/generated/types/escrowStatus.js +0 -24
- package/dist/generated/types/escrowStatus.js.map +0 -1
- package/dist/generated/types/instructionConstraintsCreated.d.ts +0 -34
- package/dist/generated/types/instructionConstraintsCreated.d.ts.map +0 -1
- package/dist/generated/types/instructionConstraintsCreated.js +0 -36
- package/dist/generated/types/instructionConstraintsCreated.js.map +0 -1
- package/dist/generated/types/orphanConstraintsPdaCleaned.d.ts +0 -22
- package/dist/generated/types/orphanConstraintsPdaCleaned.d.ts.map +0 -1
- package/dist/generated/types/orphanConstraintsPdaCleaned.js.map +0 -1
- package/dist/generated/types/pdaAllocated.d.ts +0 -24
- package/dist/generated/types/pdaAllocated.d.ts.map +0 -1
- package/dist/generated/types/pdaAllocated.js +0 -28
- package/dist/generated/types/pdaAllocated.js.map +0 -1
- package/dist/generated/types/pdaExtended.d.ts +0 -24
- package/dist/generated/types/pdaExtended.d.ts.map +0 -1
- package/dist/generated/types/pdaExtended.js +0 -28
- package/dist/generated/types/pdaExtended.js.map +0 -1
- package/dist/post-assertions/cross-field-lte.d.ts +0 -134
- package/dist/post-assertions/cross-field-lte.d.ts.map +0 -1
- package/dist/post-assertions/cross-field-lte.js +0 -129
- package/dist/post-assertions/cross-field-lte.js.map +0 -1
- package/dist/post-assertions/index.d.ts +0 -28
- package/dist/post-assertions/index.d.ts.map +0 -1
- package/dist/post-assertions/index.js +0 -28
- package/dist/post-assertions/index.js.map +0 -1
- package/dist/post-assertions/presets/flash-trade.d.ts +0 -139
- package/dist/post-assertions/presets/flash-trade.d.ts.map +0 -1
- package/dist/post-assertions/presets/flash-trade.js +0 -154
- package/dist/post-assertions/presets/flash-trade.js.map +0 -1
- package/dist/protocol-registry/annotations/drift.json +0 -7
- package/dist/protocol-registry/annotations/flash-trade.json +0 -7
- package/dist/protocol-registry/annotations/jupiter-borrow.json +0 -7
- package/dist/protocol-registry/annotations/jupiter-earn.json +0 -7
- package/dist/protocol-registry/annotations/jupiter-lend.json +0 -7
- package/dist/protocol-registry/annotations/jupiter.json +0 -7
- package/dist/protocol-registry/annotations/kamino.json +0 -7
- package/dist/protocol-registry/index.d.ts +0 -45
- package/dist/protocol-registry/index.d.ts.map +0 -1
- package/dist/protocol-registry/index.js +0 -76
- package/dist/protocol-registry/index.js.map +0 -1
- package/dist/protocol-tier.d.ts +0 -157
- package/dist/protocol-tier.d.ts.map +0 -1
- package/dist/protocol-tier.js +0 -104
- package/dist/protocol-tier.js.map +0 -1
package/dist/types.js
CHANGED
|
@@ -8,11 +8,13 @@ import { SigilSdkDomainError } from "./errors/sdk.js";
|
|
|
8
8
|
import { SIGIL_ERROR__SDK__INVALID_NETWORK } from "./errors/codes.js";
|
|
9
9
|
// Re-export the program address from generated code
|
|
10
10
|
export { SIGIL_PROGRAM_ADDRESS } from "./generated/programs/sigil.js";
|
|
11
|
+
// M1-04: ConstraintEntry/DataConstraint/AccountConstraint/ConstraintOperator
|
|
12
|
+
// re-exports removed with the constraints engine (generated types deleted).
|
|
11
13
|
// ─── Fee Constants ────────────────────────────────────────────────────────────
|
|
12
14
|
export const FEE_RATE_DENOMINATOR = 1_000_000;
|
|
13
15
|
export const PROTOCOL_FEE_RATE = 200; // 2 BPS
|
|
14
16
|
export const MAX_DEVELOPER_FEE_RATE = 500; // 5 BPS
|
|
15
|
-
export const PROTOCOL_TREASURY = "
|
|
17
|
+
export const PROTOCOL_TREASURY = "6wrkKTM2pjkcCAbMfRz2j3AXspavu6pq3ePcuJUE3Azp";
|
|
16
18
|
/** Construct a branded USD base-units amount. Zero runtime cost. */
|
|
17
19
|
export function usd(amount) {
|
|
18
20
|
return amount;
|
|
@@ -55,8 +57,7 @@ export const FULL_PERMISSIONS = FULL_CAPABILITY;
|
|
|
55
57
|
// pre-v6 permission model the on-chain program no longer supports. Use
|
|
56
58
|
// FULL_CAPABILITY (2n) for operator agents and put granular per-action
|
|
57
59
|
// restrictions in InstructionConstraints.
|
|
58
|
-
//
|
|
59
|
-
export const MAX_ESCROW_DURATION = 2_592_000; // 30 days in seconds
|
|
60
|
+
// Escrow constants REMOVED in v2 revamp Stage 1 (escrow feature deleted).
|
|
60
61
|
// ─── u64 Boundary ────────────────────────────────────────────────────────────
|
|
61
62
|
/** Maximum u64 value — used for BigInt clamping to match on-chain Rust math. */
|
|
62
63
|
export const U64_MAX = BigInt("18446744073709551615");
|
|
@@ -164,71 +165,12 @@ export function isStablecoinMint(mint, network) {
|
|
|
164
165
|
}
|
|
165
166
|
return mint === USDC_MINT_MAINNET || mint === USDT_MINT_MAINNET;
|
|
166
167
|
}
|
|
167
|
-
// ─── ActionType Parsing ──────────────────────────────────────────────────────
|
|
168
|
-
//
|
|
169
|
-
// The v6 on-chain program eliminated per-action permission bits in favor of a
|
|
170
|
-
// 2-bit capability enum. `parseActionType` is preserved because
|
|
171
|
-
// `event-analytics.ts` still reads numeric ActionType values from on-chain
|
|
172
|
-
// events and needs the string label for UI display. It does NOT grant or
|
|
173
|
-
// check any permission — the v6 program enforces capability (0/1/2), not
|
|
174
|
-
// ActionType.
|
|
175
|
-
/**
|
|
176
|
-
* Canonical action-type names indexed by the v6 on-chain ActionType enum
|
|
177
|
-
* variant. Index 0 = `Swap`, index 20 = `RefundEscrow`. This is the ONLY
|
|
178
|
-
* permission-related state still in this file post-A11 — it powers
|
|
179
|
-
* `parseActionType` for event decoding and nothing else.
|
|
180
|
-
*/
|
|
181
|
-
const ACTION_TYPE_NAMES_BY_INDEX = [
|
|
182
|
-
"swap", // 0
|
|
183
|
-
"openPosition", // 1
|
|
184
|
-
"closePosition", // 2
|
|
185
|
-
"increasePosition", // 3
|
|
186
|
-
"decreasePosition", // 4
|
|
187
|
-
"deposit", // 5
|
|
188
|
-
"withdraw", // 6
|
|
189
|
-
"transfer", // 7
|
|
190
|
-
"addCollateral", // 8
|
|
191
|
-
"removeCollateral", // 9
|
|
192
|
-
"placeTriggerOrder", // 10
|
|
193
|
-
"editTriggerOrder", // 11
|
|
194
|
-
"cancelTriggerOrder", // 12
|
|
195
|
-
"placeLimitOrder", // 13
|
|
196
|
-
"editLimitOrder", // 14
|
|
197
|
-
"cancelLimitOrder", // 15
|
|
198
|
-
"swapAndOpenPosition", // 16
|
|
199
|
-
"closeAndSwapPosition", // 17
|
|
200
|
-
"createEscrow", // 18
|
|
201
|
-
"settleEscrow", // 19
|
|
202
|
-
"refundEscrow", // 20
|
|
203
|
-
];
|
|
204
|
-
/**
|
|
205
|
-
* Parse an action type to its string key.
|
|
206
|
-
* Accepts either a numeric ActionType enum value (0-20) or an
|
|
207
|
-
* Anchor-style `{ Swap: {} }` object. Returns `undefined` for
|
|
208
|
-
* out-of-range numeric values or empty objects.
|
|
209
|
-
*/
|
|
210
|
-
export function parseActionType(actionType) {
|
|
211
|
-
if (typeof actionType === "number") {
|
|
212
|
-
return ACTION_TYPE_NAMES_BY_INDEX[actionType];
|
|
213
|
-
}
|
|
214
|
-
return Object.keys(actionType)[0];
|
|
215
|
-
}
|
|
216
168
|
// ─── Spending Classification ─────────────────────────────────────────────────
|
|
217
|
-
//
|
|
218
|
-
//
|
|
219
|
-
//
|
|
220
|
-
//
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
"openPosition",
|
|
225
|
-
"increasePosition",
|
|
226
|
-
"deposit",
|
|
227
|
-
"transfer",
|
|
228
|
-
"addCollateral",
|
|
229
|
-
"placeLimitOrder",
|
|
230
|
-
"swapAndOpenPosition",
|
|
231
|
-
"createEscrow",
|
|
232
|
-
].includes(actionType);
|
|
233
|
-
}
|
|
169
|
+
//
|
|
170
|
+
// V2 Option A: spending is always derived from `amount > 0`. The on-chain
|
|
171
|
+
// session no longer carries an `is_spending` field, and ActionType + 21-bit
|
|
172
|
+
// permission bits were deleted (council 9-1 vote, 2026-04-19). The
|
|
173
|
+
// `ACTION_TYPE_NAMES_BY_INDEX` / `parseActionType` / `isSpendingAction`
|
|
174
|
+
// helpers that mapped enum indices to labels for UI display were removed
|
|
175
|
+
// along with the on-chain field they decoded.
|
|
234
176
|
//# sourceMappingURL=types.js.map
|
package/dist/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,iCAAiC,EAAE,MAAM,mBAAmB,CAAC;AAEtE,oDAAoD;AACpD,OAAO,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,iCAAiC,EAAE,MAAM,mBAAmB,CAAC;AAEtE,oDAAoD;AACpD,OAAO,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;AAYtE,6EAA6E;AAC7E,4EAA4E;AAE5E,iFAAiF;AAEjF,MAAM,CAAC,MAAM,oBAAoB,GAAG,SAAS,CAAC;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AE;gBACP,QAAQ,EAAE,OAAO;gBACjB,KAAK,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,cAAc,CAAC;aAC7C;SACF,CACF,CAAC;IACJ,CAAC;AACH,CAAC;AAKD;2DAC2D;AAC3D,MAAM,UAAU,gBAAgB,CAAC,OAAqB;IACpD,OAAO,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAE,OAAmB,CAAC;AACvE,CAAC;AAED,6DAA6D;AAC7D,MAAM,UAAU,aAAa,CAAC,EAI7B;IACC,OAAO,EAAiB,CAAC;AAC3B,CAAC;AAED,0EAA0E;AAC1E,MAAM,UAAU,gBAAgB,CAAC,IAAa,EAAE,OAAgB;IAC9D,IAAI,OAAO,KAAK,QAAQ,EAAE,CAAC;QACzB,OAAO,IAAI,KAAK,gBAAgB,IAAI,IAAI,KAAK,gBAAgB,CAAC;IAChE,CAAC;IACD,OAAO,IAAI,KAAK,iBAAiB,IAAI,IAAI,KAAK,iBAAiB,CAAC;AAClE,CAAC;AAED,gFAAgF;AAChF,EAAE;AACF,0EAA0E;AAC1E,4EAA4E;AAC5E,mEAAmE;AACnE,wEAAwE;AACxE,yEAAyE;AACzE,8CAA8C"}
|
|
@@ -23,7 +23,6 @@ export interface VaultHealth {
|
|
|
23
23
|
isHealthy: boolean;
|
|
24
24
|
agentCount: number;
|
|
25
25
|
pausedAgentCount: number;
|
|
26
|
-
activeEscrowCount: number;
|
|
27
26
|
/** 0-100 percentage of daily cap used */
|
|
28
27
|
capUtilization: number;
|
|
29
28
|
/** USD base units remaining in 24h window */
|
|
@@ -32,7 +31,6 @@ export interface VaultHealth {
|
|
|
32
31
|
capResetsIn: number;
|
|
33
32
|
/** Seconds until cap would be hit at current rate. null = safe. */
|
|
34
33
|
timeToCapAtCurrentRate: number | null;
|
|
35
|
-
hasConstraints: boolean;
|
|
36
34
|
hasTimelock: boolean;
|
|
37
35
|
timelockDuration: number;
|
|
38
36
|
hasPendingPolicyChange: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vault-analytics.d.ts","sourceRoot":"","sources":["../src/vault-analytics.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAEnE,OAAO,KAAK,EACV,kBAAkB,EAClB,0BAA0B,EAC3B,MAAM,qBAAqB,CAAC;AAO7B,OAAO,EAGL,KAAK,QAAQ,EACb,KAAK,YAAY,EAClB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAKL,KAAK,OAAO,EACb,MAAM,YAAY,CAAC;AAIpB,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,UAAU,GAAG,SAAS,GAAG,MAAM,CAAC;CAC3C;AAED,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,QAAQ,GAAG,QAAQ,GAAG,QAAQ,CAAC;IACvC,iDAAiD;IACjD,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB,EAAE,MAAM,CAAC;IACzB,
|
|
1
|
+
{"version":3,"file":"vault-analytics.d.ts","sourceRoot":"","sources":["../src/vault-analytics.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAEnE,OAAO,KAAK,EACV,kBAAkB,EAClB,0BAA0B,EAC3B,MAAM,qBAAqB,CAAC;AAO7B,OAAO,EAGL,KAAK,QAAQ,EACb,KAAK,YAAY,EAClB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAKL,KAAK,OAAO,EACb,MAAM,YAAY,CAAC;AAIpB,MAAM,WAAW,kBAAkB;IACjC,EAAE,EAAE,MAAM,C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W,CAAC;IACpB,GAAG,EAAE,QAAQ,CAAC;IACd,aAAa,EAAE,YAAY,EAAE,CAAC;IAC9B,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,0BAA0B,CAAC;IAClC,KAAK,EAAE,UAAU,CAAC;CACnB;AAID;;;;;GAKG;AACH,wBAAgB,cAAc,CAC5B,KAAK,EAAE,kBAAkB,GAAG,0BAA0B,EACtD,OAAO,EAAE,MAAM,GACd,WAAW,CAkHb;AAID;;;GAGG;AACH,wBAAsB,eAAe,CACnC,GAAG,EAAE,GAAG,CAAC,YAAY,CAAC,EACtB,KAAK,EAAE,OAAO,EACd,OAAO,GAAE,OAAwB,GAChC,OAAO,CAAC,YAAY,CAAC,CAuDvB"}
|
package/dist/vault-analytics.js
CHANGED
|
@@ -22,7 +22,7 @@ import { FULL_CAPABILITY, PROTOCOL_MODE_ALLOWLIST, EPOCH_DURATION, NUM_EPOCHS, }
|
|
|
22
22
|
* already-resolved vault state. The dashboard vault card renders this directly.
|
|
23
23
|
*/
|
|
24
24
|
export function getVaultHealth(state, nowUnix) {
|
|
25
|
-
const { vault, policy, tracker, globalBudget
|
|
25
|
+
const { vault, policy, tracker, globalBudget } = state;
|
|
26
26
|
// VaultStatus is a numeric enum (Active=0, Frozen=1, Closed=2).
|
|
27
27
|
// Use reverse mapping for display string.
|
|
28
28
|
const STATUS_NAMES = {
|
|
@@ -92,12 +92,6 @@ export function getVaultHealth(state, nowUnix) {
|
|
|
92
92
|
passed: policy.maxSlippageBps < 1000,
|
|
93
93
|
severity: "warning",
|
|
94
94
|
},
|
|
95
|
-
{
|
|
96
|
-
id: "constraints-configured",
|
|
97
|
-
label: "Instruction constraints are set",
|
|
98
|
-
passed: constraints !== null,
|
|
99
|
-
severity: "info",
|
|
100
|
-
},
|
|
101
95
|
];
|
|
102
96
|
const criticalFailures = securityChecks.filter((c) => c.severity === "critical" && !c.passed);
|
|
103
97
|
const isHealthy = status === "Active" &&
|
|
@@ -110,12 +104,10 @@ export function getVaultHealth(state, nowUnix) {
|
|
|
110
104
|
isHealthy,
|
|
111
105
|
agentCount,
|
|
112
106
|
pausedAgentCount,
|
|
113
|
-
activeEscrowCount: vault.activeEscrowCount,
|
|
114
107
|
capUtilization,
|
|
115
108
|
capRemaining: globalBudget.remaining,
|
|
116
109
|
capResetsIn,
|
|
117
110
|
timeToCapAtCurrentRate: velocity.timeToCapSeconds,
|
|
118
|
-
hasConstraints: constraints !== null,
|
|
119
111
|
hasTimelock: policy.timelockDuration > 0n,
|
|
120
112
|
timelockDuration: Number(policy.timelockDuration),
|
|
121
113
|
hasPendingPolicyChange: false, // Overridden by getVaultSummary()
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vault-analytics.js","sourceRoot":"","sources":["../src/vault-analytics.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,EAAE,yBAAyB,EAAE,MAAM,iBAAiB,CAAC;AAK5D,OAAO,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAC;AAC/D,OAAO,EACL,yBAAyB,EACzB,wBAAwB,GACzB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EACL,WAAW,EACX,qBAAqB,GAGtB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,EACL,eAAe,EACf,uBAAuB,EACvB,cAAc,EACd,UAAU,GAEX,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"vault-analytics.js","sourceRoot":"","sources":["../src/vault-analytics.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,EAAE,yBAAyB,EAAE,MAAM,iBAAiB,CAAC;AAK5D,OAAO,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAC;AAC/D,OAAO,EACL,yBAAyB,EACzB,wBAAwB,GACzB,MAAM,qBAAqB,CAAC;AA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;IAE3E,MAAM,KAAK,GAAe;QACxB,iBAAiB,EAAE,CAAC,CAAC,iBAAiB;QACtC,WAAW,EAAE,CAAC,CAAC,WAAW;QAC1B,kBAAkB,EAAE,CAAC,CAAC,kBAAkB;QACxC,cAAc,EAAE,CAAC,CAAC,iBAAiB;QACnC,cAAc,EAAE,CAAC,CAAC,iBAAiB;QACnC,SAAS,EAAE,CAAC,CAAC,SAAS;QACtB,SAAS;QACT,cAAc,EAAE,SAAS,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAAE;QACtE,kBAAkB,EAChB,CAAC,CAAC,iBAAiB,GAAG,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,CAAC,CAAC,iBAAiB,CAAC,CAAC,CAAC,EAAE;QACrE,OAAO,EACL,CAAC,CAAC,WAAW,GAAG,EAAE;YAChB,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,WAAW,CAAC;YACzD,CAAC,CAAC,CAAC;KACR,CAAC;IAEF,MAAM,aAAa,GACjB,KAAK,CAAC,kBAAkB,CAAC,IAAI,GAAG,KAAK,CAAC,kBAAkB,CAAC,IAAI,CAAC;IAEhE,OAAO;QACL,OAAO,EAAE,KAAK;QACd,KAAK,EAAE,CAAC,CAAC,KAAK;QACd,OAAO,EAAE,CAAC,CAAC,OAAO;QAClB,MAAM;QACN,GAAG;QACH,aAAa;QACb,aAAa;QACb,KAAK;QACL,KAAK;KACN,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@usesigil/kit",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.18.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"author": "Kaleb Rupe (https://x.com/MightieMags)",
|
|
6
6
|
"homepage": "https://github.com/Sigil-Trade/sigil#readme",
|
|
@@ -37,10 +37,6 @@
|
|
|
37
37
|
"import": "./dist/dashboard/index.js",
|
|
38
38
|
"types": "./dist/dashboard/index.d.ts"
|
|
39
39
|
},
|
|
40
|
-
"./constraints": {
|
|
41
|
-
"import": "./dist/constraints/index.js",
|
|
42
|
-
"types": "./dist/constraints/index.d.ts"
|
|
43
|
-
},
|
|
44
40
|
"./errors": {
|
|
45
41
|
"import": "./dist/errors/public.js",
|
|
46
42
|
"types": "./dist/errors/public.d.ts"
|
|
@@ -48,10 +44,6 @@
|
|
|
48
44
|
"./react": {
|
|
49
45
|
"import": "./dist/react/index.js",
|
|
50
46
|
"types": "./dist/react/index.d.ts"
|
|
51
|
-
},
|
|
52
|
-
"./post-assertions": {
|
|
53
|
-
"import": "./dist/post-assertions/index.js",
|
|
54
|
-
"types": "./dist/post-assertions/index.d.ts"
|
|
55
47
|
}
|
|
56
48
|
},
|
|
57
49
|
"files": [
|
|
@@ -64,6 +56,7 @@
|
|
|
64
56
|
"node": ">=20.10.0"
|
|
65
57
|
},
|
|
66
58
|
"dependencies": {
|
|
59
|
+
"@noble/hashes": "^1.8.0",
|
|
67
60
|
"@solana-program/compute-budget": "^0.15.0"
|
|
68
61
|
},
|
|
69
62
|
"peerDependencies": {
|
|
@@ -93,7 +86,6 @@
|
|
|
93
86
|
"codama": "1.5.1",
|
|
94
87
|
"fast-check": "^3.23.2",
|
|
95
88
|
"mocha": "^11.7.5",
|
|
96
|
-
"ts-node": "^10.9.2",
|
|
97
89
|
"tsx": "^4.21.0",
|
|
98
90
|
"typescript": "^5.3.3",
|
|
99
91
|
"@solana/web3.js": "^1.95.0",
|
|
@@ -126,8 +118,11 @@
|
|
|
126
118
|
"codama:flash": "node codama.mjs --protocol=flash-trade",
|
|
127
119
|
"codama:kamino": "node codama.mjs --protocol=kamino",
|
|
128
120
|
"codama:all": "node codama.mjs --all",
|
|
129
|
-
"
|
|
130
|
-
"
|
|
121
|
+
"codegen:errors": "node --import tsx scripts/gen-error-map.ts",
|
|
122
|
+
"check-surface": "node --import tsx scripts/check-surface.ts",
|
|
123
|
+
"verify-lockfile-pins": "node --import tsx scripts/verify-lockfile-pins.ts",
|
|
124
|
+
"pretest": "pnpm run codegen:errors && tsc -p tsconfig.test.json --noEmit",
|
|
125
|
+
"test": "mocha --require tsx --require tests/global-setup.ts 'tests/*.test.ts' 'tests/al-envelope/*.test.ts' 'tests/core/*.test.ts' 'tests/dashboard/*.test.ts' 'tests/errors/*.test.ts' 'tests/experimental/*.test.ts' 'tests/helpers/*.test.ts' 'tests/policy/*.test.ts' --timeout 30000",
|
|
131
126
|
"test:devnet": "mocha --require tsx tests/devnet/**/*.test.ts --timeout 300000",
|
|
132
127
|
"test:experimental": "mocha --require tsx tests/experimental/**/*.test.ts --timeout 30000",
|
|
133
128
|
"check:examples": "tsc -p tsconfig.examples.json"
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @usesigil/kit/constraints — Constraint authoring subpath.
|
|
3
|
-
*
|
|
4
|
-
* Re-export module exposing the constraint PDA derivation, fetch, and
|
|
5
|
-
* multi-instruction builder helpers under a stable public surface.
|
|
6
|
-
*
|
|
7
|
-
* The dashboard frontend imports from this subpath per the
|
|
8
|
-
* FRONTEND-BACKEND-CONTRACT.md D1 covenant. Internally these symbols live
|
|
9
|
-
* in `src/dashboard/` (PDA reads) and `src/dashboard/constraint-builders.ts`
|
|
10
|
-
* (5-instruction allocation chain). This module flattens them into one
|
|
11
|
-
* stable import path so consumers don't need to know the internal layout.
|
|
12
|
-
*
|
|
13
|
-
* **Firewall invariant (protocol-tier.ts:32):** kit must NEVER import from
|
|
14
|
-
* `@sigil-trade/constraints` (a private GitHub Packages parser package).
|
|
15
|
-
* Everything exported here is sourced from kit's own modules. The
|
|
16
|
-
* `tests/firewall-invariant.test.ts` test enforces this at CI time.
|
|
17
|
-
*
|
|
18
|
-
* No new logic — pure re-export.
|
|
19
|
-
*/
|
|
20
|
-
export { findConstraintsPda, findPendingConstraintsPda, findPendingCloseConstraintsPda, fetchConstraints, fetchPendingConstraintsUpdate, fetchPendingCloseConstraints, type ConstraintsPdaInfo, } from "../dashboard/constraint-reads.js";
|
|
21
|
-
export { buildCreateConstraintsIxs, buildQueueConstraintsUpdateIxs, type BuildCreateConstraintsInput, } from "../dashboard/constraint-builders.js";
|
|
22
|
-
export type { ConstraintEntry } from "../dashboard/types.js";
|
|
23
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/constraints/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EACL,kBAAkB,EAClB,yBAAyB,EACzB,8BAA8B,EAC9B,gBAAgB,EAChB,6BAA6B,EAC7B,4BAA4B,EAC5B,KAAK,kBAAkB,GACxB,MAAM,kCAAkC,CAAC;AAG1C,OAAO,EACL,yBAAyB,EACzB,8BAA8B,EAC9B,KAAK,2BAA2B,GACjC,MAAM,qCAAqC,CAAC;AAG7C,YAAY,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @usesigil/kit/constraints — Constraint authoring subpath.
|
|
3
|
-
*
|
|
4
|
-
* Re-export module exposing the constraint PDA derivation, fetch, and
|
|
5
|
-
* multi-instruction builder helpers under a stable public surface.
|
|
6
|
-
*
|
|
7
|
-
* The dashboard frontend imports from this subpath per the
|
|
8
|
-
* FRONTEND-BACKEND-CONTRACT.md D1 covenant. Internally these symbols live
|
|
9
|
-
* in `src/dashboard/` (PDA reads) and `src/dashboard/constraint-builders.ts`
|
|
10
|
-
* (5-instruction allocation chain). This module flattens them into one
|
|
11
|
-
* stable import path so consumers don't need to know the internal layout.
|
|
12
|
-
*
|
|
13
|
-
* **Firewall invariant (protocol-tier.ts:32):** kit must NEVER import from
|
|
14
|
-
* `@sigil-trade/constraints` (a private GitHub Packages parser package).
|
|
15
|
-
* Everything exported here is sourced from kit's own modules. The
|
|
16
|
-
* `tests/firewall-invariant.test.ts` test enforces this at CI time.
|
|
17
|
-
*
|
|
18
|
-
* No new logic — pure re-export.
|
|
19
|
-
*/
|
|
20
|
-
// ─── PDA derivation + fetch helpers ────────────────────────────────────────
|
|
21
|
-
export { findConstraintsPda, findPendingConstraintsPda, findPendingCloseConstraintsPda, fetchConstraints, fetchPendingConstraintsUpdate, fetchPendingCloseConstraints, } from "../dashboard/constraint-reads.js";
|
|
22
|
-
// ─── Multi-instruction builders (PR 1's Day-0 fix) ─────────────────────────
|
|
23
|
-
export { buildCreateConstraintsIxs, buildQueueConstraintsUpdateIxs, } from "../dashboard/constraint-builders.js";
|
|
24
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/constraints/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,8EAA8E;AAC9E,OAAO,EACL,kBAAkB,EAClB,yBAAyB,EACzB,8BAA8B,EAC9B,gBAAgB,EAChB,6BAA6B,EAC7B,4BAA4B,GAE7B,MAAM,kCAAkC,CAAC;AAE1C,8EAA8E;AAC9E,OAAO,EACL,yBAAyB,EACzB,8BAA8B,GAE/B,MAAM,qCAAqC,CAAC"}
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @usesigil/kit/dashboard — Constraint instruction-chain builders.
|
|
3
|
-
*
|
|
4
|
-
* The on-chain `create_instruction_constraints` and `queue_constraints_update`
|
|
5
|
-
* handlers require their target PDA to already be allocated to a fixed size
|
|
6
|
-
* before the populate instruction runs (35,888 bytes for `InstructionConstraints`,
|
|
7
|
-
* 35,904 bytes for `PendingConstraintsUpdate`). The runtime CPI realloc cap is
|
|
8
|
-
* 10,240 bytes per call, so the PDA must be grown across multiple instructions
|
|
9
|
-
* batched into a single transaction.
|
|
10
|
-
*
|
|
11
|
-
* This module composes the full 5-instruction chain:
|
|
12
|
-
*
|
|
13
|
-
* 1. `allocate_constraints_pda` (or `allocate_pending_constraints_pda`)
|
|
14
|
-
* — initial 10,240-byte allocation
|
|
15
|
-
* 2. `extend_pda` to 20,480 bytes
|
|
16
|
-
* 3. `extend_pda` to 30,720 bytes
|
|
17
|
-
* 4. `extend_pda` to 35,888 (constraints) or 35,904 (pending) bytes
|
|
18
|
-
* 5. `create_instruction_constraints` (or `queue_constraints_update`)
|
|
19
|
-
* — populate with the caller-provided entries
|
|
20
|
-
*
|
|
21
|
-
* **Why this matters (Day-0 bug):** before this module existed, `mutations.ts`
|
|
22
|
-
* sent only step 5. Every owner call hit `InvalidConstraintsPda` on-chain
|
|
23
|
-
* because step-5's `require!(info.data_len() == InstructionConstraints::SIZE)`
|
|
24
|
-
* could never be satisfied — the PDA didn't exist.
|
|
25
|
-
*
|
|
26
|
-
* **Tx-size guardrail:** all 5 instructions ride in one transaction (atomic —
|
|
27
|
-
* partial allocation is unsafe). Solana's 1232-byte wire limit means the
|
|
28
|
-
* realistic ceiling is ~3 fully-populated `ConstraintEntry`s per call. Past
|
|
29
|
-
* that, this module throws `SIGIL_ERROR__RPC__TX_TOO_LARGE` at build time
|
|
30
|
-
* rather than letting the RPC reject it. Splitting across transactions is not
|
|
31
|
-
* an option — a half-allocated PDA leaves the vault wedged until manual cleanup.
|
|
32
|
-
*
|
|
33
|
-
* The builders return `Instruction[]`; callers (typically `mutations.ts`)
|
|
34
|
-
* pass that array straight into `run()` for blockhash/signing/submission.
|
|
35
|
-
* Address lookup tables compress the recurring vault/owner accounts and let
|
|
36
|
-
* us fit 3 fully-populated entries within the limit.
|
|
37
|
-
*/
|
|
38
|
-
import type { Address, Instruction, TransactionSigner } from "../kit-adapter.js";
|
|
39
|
-
import type { ConstraintEntry } from "./types.js";
|
|
40
|
-
/** `InstructionConstraints::SIZE` — full byte length of the populated PDA. */
|
|
41
|
-
export declare const CONSTRAINTS_SIZE = 35888;
|
|
42
|
-
/** `PendingConstraintsUpdate::SIZE` — full byte length of the populated PDA. */
|
|
43
|
-
export declare const PENDING_CONSTRAINTS_SIZE = 35904;
|
|
44
|
-
/**
|
|
45
|
-
* `MAX_CPI_ACCOUNT_SIZE` — initial alloc + max growth per `extend_pda` call.
|
|
46
|
-
* Solana's runtime caps a single CPI realloc to this many bytes.
|
|
47
|
-
*/
|
|
48
|
-
export declare const MAX_CPI_ACCOUNT_SIZE = 10240;
|
|
49
|
-
export interface BuildCreateConstraintsInput {
|
|
50
|
-
owner: TransactionSigner;
|
|
51
|
-
vault: Address;
|
|
52
|
-
/**
|
|
53
|
-
* Policy PDA address. Callers normally derive this via `getPolicyPDA(vault)`
|
|
54
|
-
* and pass the result. The codama generators auto-derive from `vault` if
|
|
55
|
-
* omitted, but we keep `policy` explicit here to match the on-chain struct
|
|
56
|
-
* and to avoid a hidden async PDA derivation inside the builder.
|
|
57
|
-
*/
|
|
58
|
-
policy: Address;
|
|
59
|
-
entries: ConstraintEntry[];
|
|
60
|
-
strictMode: boolean;
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* Build the 5-instruction chain that allocates the constraints PDA and writes
|
|
64
|
-
* the caller-provided entries. Pass the returned array into `run()` (or any
|
|
65
|
-
* other transaction submitter) — all 5 instructions must ride in one tx.
|
|
66
|
-
*
|
|
67
|
-
* Throws `SIGIL_ERROR__RPC__TX_TOO_LARGE` if the entries do not fit within
|
|
68
|
-
* Solana's 1232-byte wire limit. Catch and split entries across multiple
|
|
69
|
-
* owner calls in that case (no automatic fallback — partial PDA allocation
|
|
70
|
-
* is unsafe and would wedge the vault).
|
|
71
|
-
*/
|
|
72
|
-
export declare function buildCreateConstraintsIxs(input: BuildCreateConstraintsInput): Promise<Instruction[]>;
|
|
73
|
-
/**
|
|
74
|
-
* Build the 5-instruction chain for `queueConstraintsUpdate`. Targets the
|
|
75
|
-
* `pending_constraints` PDA (seed `b"pending_constraints"`) at 35,904 bytes
|
|
76
|
-
* — 16 more than `InstructionConstraints` to accommodate the extra timestamp
|
|
77
|
-
* fields in `PendingConstraintsUpdate`.
|
|
78
|
-
*
|
|
79
|
-
* Same tx-size contract as `buildCreateConstraintsIxs`.
|
|
80
|
-
*/
|
|
81
|
-
export declare function buildQueueConstraintsUpdateIxs(input: BuildCreateConstraintsInput): Promise<Instruction[]>;
|
|
82
|
-
//# sourceMappingURL=constraint-builders.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"constraint-builders.d.ts","sourceRoot":"","sources":["../../src/dashboard/constraint-builders.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAEH,OAAO,KAAK,EACV,OAAO,EACP,WAAW,EACX,iBAAiB,EAClB,MAAM,mBAAmB,CAAC;AAqB3B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAWlD,8EAA8E;AAC9E,eAAO,MAAM,gBAAgB,QAAS,CAAC;AAEvC,gFAAgF;AAChF,eAAO,MAAM,wBAAwB,QAAS,CAAC;AAE/C;;;GAGG;AACH,eAAO,MAAM,oBAAoB,QAAS,CAAC;AAoE3C,MAAM,WAAW,2BAA2B;IAC1C,KAAK,EAAE,iBAAiB,CAAC;IACzB,KAAK,EAAE,OAAO,CAAC;IACf;;;;;OAKG;IACH,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,eAAe,EAAE,CAAC;IAC3B,UAAU,EAAE,OAAO,CAAC;CACrB;AAID;;;;;;;;;GASG;AACH,wBAAsB,yBAAyB,CAC7C,KAAK,EAAE,2BAA2B,GACjC,OAAO,CAAC,WAAW,EAAE,CAAC,CA6CxB;AAED;;;;;;;GAOG;AACH,wBAAsB,8BAA8B,CAClD,KAAK,EAAE,2BAA2B,GACjC,OAAO,CAAC,WAAW,EAAE,CAAC,CAqDxB"}
|
|
@@ -1,204 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @usesigil/kit/dashboard — Constraint instruction-chain builders.
|
|
3
|
-
*
|
|
4
|
-
* The on-chain `create_instruction_constraints` and `queue_constraints_update`
|
|
5
|
-
* handlers require their target PDA to already be allocated to a fixed size
|
|
6
|
-
* before the populate instruction runs (35,888 bytes for `InstructionConstraints`,
|
|
7
|
-
* 35,904 bytes for `PendingConstraintsUpdate`). The runtime CPI realloc cap is
|
|
8
|
-
* 10,240 bytes per call, so the PDA must be grown across multiple instructions
|
|
9
|
-
* batched into a single transaction.
|
|
10
|
-
*
|
|
11
|
-
* This module composes the full 5-instruction chain:
|
|
12
|
-
*
|
|
13
|
-
* 1. `allocate_constraints_pda` (or `allocate_pending_constraints_pda`)
|
|
14
|
-
* — initial 10,240-byte allocation
|
|
15
|
-
* 2. `extend_pda` to 20,480 bytes
|
|
16
|
-
* 3. `extend_pda` to 30,720 bytes
|
|
17
|
-
* 4. `extend_pda` to 35,888 (constraints) or 35,904 (pending) bytes
|
|
18
|
-
* 5. `create_instruction_constraints` (or `queue_constraints_update`)
|
|
19
|
-
* — populate with the caller-provided entries
|
|
20
|
-
*
|
|
21
|
-
* **Why this matters (Day-0 bug):** before this module existed, `mutations.ts`
|
|
22
|
-
* sent only step 5. Every owner call hit `InvalidConstraintsPda` on-chain
|
|
23
|
-
* because step-5's `require!(info.data_len() == InstructionConstraints::SIZE)`
|
|
24
|
-
* could never be satisfied — the PDA didn't exist.
|
|
25
|
-
*
|
|
26
|
-
* **Tx-size guardrail:** all 5 instructions ride in one transaction (atomic —
|
|
27
|
-
* partial allocation is unsafe). Solana's 1232-byte wire limit means the
|
|
28
|
-
* realistic ceiling is ~3 fully-populated `ConstraintEntry`s per call. Past
|
|
29
|
-
* that, this module throws `SIGIL_ERROR__RPC__TX_TOO_LARGE` at build time
|
|
30
|
-
* rather than letting the RPC reject it. Splitting across transactions is not
|
|
31
|
-
* an option — a half-allocated PDA leaves the vault wedged until manual cleanup.
|
|
32
|
-
*
|
|
33
|
-
* The builders return `Instruction[]`; callers (typically `mutations.ts`)
|
|
34
|
-
* pass that array straight into `run()` for blockhash/signing/submission.
|
|
35
|
-
* Address lookup tables compress the recurring vault/owner accounts and let
|
|
36
|
-
* us fit 3 fully-populated entries within the limit.
|
|
37
|
-
*/
|
|
38
|
-
import { pipe, appendTransactionMessageInstructions, compileTransaction, createTransactionMessage, setTransactionMessageFeePayer, setTransactionMessageLifetimeUsingBlockhash, } from "../kit-adapter.js";
|
|
39
|
-
import { measureTransactionSize, MAX_TX_SIZE } from "../composer.js";
|
|
40
|
-
import { SigilRpcError } from "../errors/rpc.js";
|
|
41
|
-
import { SIGIL_ERROR__RPC__TX_TOO_LARGE } from "../errors/codes.js";
|
|
42
|
-
import { getAllocateConstraintsPdaInstructionAsync } from "../generated/instructions/allocateConstraintsPda.js";
|
|
43
|
-
import { getAllocatePendingConstraintsPdaInstructionAsync } from "../generated/instructions/allocatePendingConstraintsPda.js";
|
|
44
|
-
import { getCreateInstructionConstraintsInstructionAsync } from "../generated/instructions/createInstructionConstraints.js";
|
|
45
|
-
import { getExtendPdaInstruction } from "../generated/instructions/extendPda.js";
|
|
46
|
-
import { getQueueConstraintsUpdateInstructionAsync } from "../generated/instructions/queueConstraintsUpdate.js";
|
|
47
|
-
import { findConstraintsPda, findPendingConstraintsPda, } from "./constraint-reads.js";
|
|
48
|
-
// ─── On-chain layout constants ──────────────────────────────────────────────
|
|
49
|
-
//
|
|
50
|
-
// Mirror the Rust constants in `programs/sigil/src/state/constraints.rs` and
|
|
51
|
-
// `programs/sigil/src/instructions/allocate_constraints_pda.rs`. If the on-chain
|
|
52
|
-
// layout grows, regenerate Codama AND update these. The on-chain
|
|
53
|
-
// `assert_size_in_sync` test ensures the Rust SIZE constant stays in sync with
|
|
54
|
-
// the computed layout — but TypeScript has no such cross-language assertion,
|
|
55
|
-
// so any change here MUST be paired with a deliberate audit of the chain.
|
|
56
|
-
/** `InstructionConstraints::SIZE` — full byte length of the populated PDA. */
|
|
57
|
-
export const CONSTRAINTS_SIZE = 35_888;
|
|
58
|
-
/** `PendingConstraintsUpdate::SIZE` — full byte length of the populated PDA. */
|
|
59
|
-
export const PENDING_CONSTRAINTS_SIZE = 35_904;
|
|
60
|
-
/**
|
|
61
|
-
* `MAX_CPI_ACCOUNT_SIZE` — initial alloc + max growth per `extend_pda` call.
|
|
62
|
-
* Solana's runtime caps a single CPI realloc to this many bytes.
|
|
63
|
-
*/
|
|
64
|
-
export const MAX_CPI_ACCOUNT_SIZE = 10_240;
|
|
65
|
-
// ─── Internal helpers ───────────────────────────────────────────────────────
|
|
66
|
-
/**
|
|
67
|
-
* Compute the sequence of `target_size` values for the extend chain.
|
|
68
|
-
* Starts at MAX_CPI_ACCOUNT_SIZE (the initial alloc) and grows by at most
|
|
69
|
-
* MAX_CPI_ACCOUNT_SIZE per step until reaching `fullSize`.
|
|
70
|
-
*/
|
|
71
|
-
function extendSteps(fullSize) {
|
|
72
|
-
const steps = [];
|
|
73
|
-
let current = MAX_CPI_ACCOUNT_SIZE;
|
|
74
|
-
while (current < fullSize) {
|
|
75
|
-
current = Math.min(current + MAX_CPI_ACCOUNT_SIZE, fullSize);
|
|
76
|
-
steps.push(current);
|
|
77
|
-
}
|
|
78
|
-
return steps;
|
|
79
|
-
}
|
|
80
|
-
/**
|
|
81
|
-
* Best-effort tx-size check on the in-progress instruction list.
|
|
82
|
-
*
|
|
83
|
-
* Compiles a stub transaction (zero blockhash, owner as fee payer) and asks
|
|
84
|
-
* Kit to measure the wire bytes. The signature/blockhash bytes are fixed
|
|
85
|
-
* size, so this is a faithful upper-bound check at build time — no RPC.
|
|
86
|
-
*
|
|
87
|
-
* Throws `SIGIL_ERROR__RPC__TX_TOO_LARGE` so the existing dashboard error
|
|
88
|
-
* pipeline recognizes the failure category.
|
|
89
|
-
*/
|
|
90
|
-
function assertWithinTxSize(owner, instructions) {
|
|
91
|
-
// Use a fixed all-zero blockhash for the measurement. Real submission
|
|
92
|
-
// replaces this; the wire-size delta is zero.
|
|
93
|
-
const stubBlockhash = {
|
|
94
|
-
blockhash: "11111111111111111111111111111111",
|
|
95
|
-
lastValidBlockHeight: 0n,
|
|
96
|
-
};
|
|
97
|
-
const message = pipe(createTransactionMessage({ version: 0 }), (tx) => setTransactionMessageFeePayer(owner.address, tx), (tx) => setTransactionMessageLifetimeUsingBlockhash(stubBlockhash, tx), (tx) => appendTransactionMessageInstructions(instructions, tx));
|
|
98
|
-
const compiled = compileTransaction(message);
|
|
99
|
-
const { byteLength, withinLimit } = measureTransactionSize(compiled);
|
|
100
|
-
if (!withinLimit) {
|
|
101
|
-
throw new SigilRpcError(SIGIL_ERROR__RPC__TX_TOO_LARGE, `Constraint chain wire size ${byteLength} bytes exceeds limit of ${MAX_TX_SIZE} bytes. ` +
|
|
102
|
-
`Reduce ConstraintEntry payload size or split entries across multiple owner calls.`, { context: { byteLength, limit: MAX_TX_SIZE } });
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
// ─── Public builders ────────────────────────────────────────────────────────
|
|
106
|
-
/**
|
|
107
|
-
* Build the 5-instruction chain that allocates the constraints PDA and writes
|
|
108
|
-
* the caller-provided entries. Pass the returned array into `run()` (or any
|
|
109
|
-
* other transaction submitter) — all 5 instructions must ride in one tx.
|
|
110
|
-
*
|
|
111
|
-
* Throws `SIGIL_ERROR__RPC__TX_TOO_LARGE` if the entries do not fit within
|
|
112
|
-
* Solana's 1232-byte wire limit. Catch and split entries across multiple
|
|
113
|
-
* owner calls in that case (no automatic fallback — partial PDA allocation
|
|
114
|
-
* is unsafe and would wedge the vault).
|
|
115
|
-
*/
|
|
116
|
-
export async function buildCreateConstraintsIxs(input) {
|
|
117
|
-
const { owner, vault, policy, entries, strictMode } = input;
|
|
118
|
-
if (!entries || entries.length === 0) {
|
|
119
|
-
// Match the validation already performed in `mutations.createConstraints`.
|
|
120
|
-
// Putting it here too means direct callers of the builder get the same
|
|
121
|
-
// guard, and the mutation wrapper becomes trivially correct.
|
|
122
|
-
throw new Error("Constraint entries must be a non-empty array");
|
|
123
|
-
}
|
|
124
|
-
const constraintsPda = await findConstraintsPda(vault);
|
|
125
|
-
// Step 1: initial 10,240-byte allocation (single CPI alloc).
|
|
126
|
-
const allocateIx = await getAllocateConstraintsPdaInstructionAsync({
|
|
127
|
-
owner,
|
|
128
|
-
vault,
|
|
129
|
-
policy,
|
|
130
|
-
constraints: constraintsPda,
|
|
131
|
-
});
|
|
132
|
-
// Steps 2..N-1: extend in 10,240-byte increments until we reach full size.
|
|
133
|
-
const extendIxs = extendSteps(CONSTRAINTS_SIZE).map((targetSize) => getExtendPdaInstruction({
|
|
134
|
-
owner,
|
|
135
|
-
vault,
|
|
136
|
-
pda: constraintsPda,
|
|
137
|
-
targetSize,
|
|
138
|
-
}));
|
|
139
|
-
// Step N: populate (the original instruction the SDK was sending alone).
|
|
140
|
-
const populateIx = await getCreateInstructionConstraintsInstructionAsync({
|
|
141
|
-
owner,
|
|
142
|
-
vault,
|
|
143
|
-
policy,
|
|
144
|
-
constraints: constraintsPda,
|
|
145
|
-
entries,
|
|
146
|
-
strictMode,
|
|
147
|
-
});
|
|
148
|
-
const ixs = [allocateIx, ...extendIxs, populateIx];
|
|
149
|
-
assertWithinTxSize(owner, ixs);
|
|
150
|
-
return ixs;
|
|
151
|
-
}
|
|
152
|
-
/**
|
|
153
|
-
* Build the 5-instruction chain for `queueConstraintsUpdate`. Targets the
|
|
154
|
-
* `pending_constraints` PDA (seed `b"pending_constraints"`) at 35,904 bytes
|
|
155
|
-
* — 16 more than `InstructionConstraints` to accommodate the extra timestamp
|
|
156
|
-
* fields in `PendingConstraintsUpdate`.
|
|
157
|
-
*
|
|
158
|
-
* Same tx-size contract as `buildCreateConstraintsIxs`.
|
|
159
|
-
*/
|
|
160
|
-
export async function buildQueueConstraintsUpdateIxs(input) {
|
|
161
|
-
const { owner, vault, policy, entries, strictMode } = input;
|
|
162
|
-
if (!entries || entries.length === 0) {
|
|
163
|
-
throw new Error("Constraint entries must be a non-empty array");
|
|
164
|
-
}
|
|
165
|
-
// Both PDAs must exist for queueing: constraints (the live config) and
|
|
166
|
-
// pendingConstraints (the freshly allocated buffer we're about to write).
|
|
167
|
-
const [constraintsPda, pendingConstraintsPda] = await Promise.all([
|
|
168
|
-
findConstraintsPda(vault),
|
|
169
|
-
findPendingConstraintsPda(vault),
|
|
170
|
-
]);
|
|
171
|
-
// Step 1: initial alloc on the *pending* PDA. The on-chain handler verifies
|
|
172
|
-
// that `constraints` already exists — i.e. there is something to update —
|
|
173
|
-
// before allocating `pending_constraints`.
|
|
174
|
-
const allocateIx = await getAllocatePendingConstraintsPdaInstructionAsync({
|
|
175
|
-
owner,
|
|
176
|
-
vault,
|
|
177
|
-
policy,
|
|
178
|
-
constraints: constraintsPda,
|
|
179
|
-
pendingConstraints: pendingConstraintsPda,
|
|
180
|
-
});
|
|
181
|
-
// Steps 2..N-1: grow the pending PDA to 35,904 bytes. The on-chain
|
|
182
|
-
// `extend_pda` handler keys on the `vault` field stored in the PDA at
|
|
183
|
-
// bytes 8..40, so a single instruction works for both PDA types.
|
|
184
|
-
const extendIxs = extendSteps(PENDING_CONSTRAINTS_SIZE).map((targetSize) => getExtendPdaInstruction({
|
|
185
|
-
owner,
|
|
186
|
-
vault,
|
|
187
|
-
pda: pendingConstraintsPda,
|
|
188
|
-
targetSize,
|
|
189
|
-
}));
|
|
190
|
-
// Step N: queue the update payload onto the pre-allocated buffer.
|
|
191
|
-
const populateIx = await getQueueConstraintsUpdateInstructionAsync({
|
|
192
|
-
owner,
|
|
193
|
-
vault,
|
|
194
|
-
policy,
|
|
195
|
-
constraints: constraintsPda,
|
|
196
|
-
pendingConstraints: pendingConstraintsPda,
|
|
197
|
-
entries,
|
|
198
|
-
strictMode,
|
|
199
|
-
});
|
|
200
|
-
const ixs = [allocateIx, ...extendIxs, populateIx];
|
|
201
|
-
assertWithinTxSize(owner, ixs);
|
|
202
|
-
return ixs;
|
|
203
|
-
}
|
|
204
|
-
//# sourceMappingURL=constraint-builders.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"constraint-builders.js","sourceRoot":"","sources":["../../src/dashboard/constraint-builders.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAOH,OAAO,EACL,IAAI,EACJ,oCAAoC,EACpC,kBAAkB,EAClB,wBAAwB,EACxB,6BAA6B,EAC7B,2CAA2C,GAC5C,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,sBAAsB,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,8BAA8B,EAAE,MAAM,oBAAoB,CAAC;AACpE,OAAO,EAAE,yCAAyC,EAAE,MAAM,qDAAqD,CAAC;AAChH,OAAO,EAAE,gDAAgD,EAAE,MAAM,4DAA4D,CAAC;AAC9H,OAAO,EAAE,+CAA+C,EAAE,MAAM,2DAA2D,CAAC;AAC5H,OAAO,EAAE,uBAAuB,EAAE,MAAM,wCAAwC,CAAC;AACjF,OAAO,EAAE,yCAAyC,EAAE,MAAM,qDAAqD,CAAC;AAChH,OAAO,EACL,kBAAkB,EAClB,yBAAyB,GAC1B,MAAM,uBAAuB,CAAC;AAG/B,+EAA+E;AAC/E,EAAE;AACF,6EAA6E;AAC7E,iFAAiF;AACjF,iEAAiE;AACjE,+EAA+E;AAC/E,6EAA6E;AAC7E,0EAA0E;AAE1E,8EAA8E;AAC9E,MAAM,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC;AAEvC,gFAAgF;AAChF,MAAM,CAAC,MAAM,wBAAwB,GAAG,MAAM,CAAC;AAE/C;;;GAGG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC;AAE3C,+EAA+E;AAE/E;;;;GAIG;AACH,SAAS,WAAW,CAAC,QAAgB;IACnC,MAAM,KAAK,GAAa,EAAE,CAAC;IAC3B,IAA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