chore: use latest clarity-codegen (#19)

This commit is contained in:
Yuanhai He
2023-09-04 11:42:49 +08:00
committed by GitHub
parent 46a7c11c94
commit f34d8742ad
11 changed files with 2086 additions and 293 deletions

7
.github/dependabot.yml vendored Normal file
View File

@@ -0,0 +1,7 @@
version: 2
updates:
# Maintain dependencies for GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"

1
.gitignore vendored
View File

@@ -1,4 +1,3 @@
.cache
node_modules
pnpm-lock.yaml
/bootstrap/config.json

2
.tool-versions Normal file
View File

@@ -0,0 +1,2 @@
nodejs 20.5.1
pnpm 8.7.1

16
.vscode/settings.json vendored
View File

@@ -9,5 +9,19 @@
"editor.autoIndent": "full",
"editor.insertSpaces": false
},
"cSpell.words": ["keccak", "parens", "xbtc", "xusd"]
"cSpell.words": [
"bignumber",
"bitcoinjs",
"clar",
"codegen",
"devenv",
"iarna",
"keccak",
"keychain",
"mocknet",
"parens",
"secretkey",
"xbtc",
"xusd"
]
}

View File

@@ -12,6 +12,18 @@
"indexer": {
"path": "contracts/indexer.clar",
"clarity_version": 2,
"epoch": 2.1
"epoch": 2.1,
"depends_on": [
"clarity-bitcoin",
"indexer-registry"
]
},
"indexer-registry": {
"path": "contracts/indexer-registry.clar",
"clarity_version": 2,
"epoch": 2.1,
"depends_on": [
"clarity-bitcoin"
]
}
}

View File

@@ -1,7 +1,7 @@
import {
defineContract,
numberT,
uintT,
bufferT,
responseSimpleT,
booleanT,
@@ -14,14 +14,14 @@ export const clarityBitcoin = defineContract({
"clarity-bitcoin": {
'mock-add-burnchain-block-header-hash': {
input: [
{ name: 'burn-height', type: numberT },
{ name: 'burn-height', type: uintT },
{ name: 'hash', type: bufferT }
],
output: responseSimpleT(booleanT, ),
mode: 'public'
},
'get-bc-h-hash': {
input: [ { name: 'bh', type: numberT } ],
input: [ { name: 'bh', type: uintT } ],
output: optionalT(bufferT, ),
mode: 'readonly'
},
@@ -47,39 +47,39 @@ export const clarityBitcoin = defineContract({
},
'inner-merkle-proof-verify': {
input: [
{ name: 'ctr', type: numberT },
{ name: 'ctr', type: uintT },
{
name: 'state',
type: tupleT({
'cur-hash': bufferT,
path: numberT,
path: uintT,
'proof-hashes': listT(bufferT, ),
'root-hash': bufferT,
'tree-depth': numberT,
'tree-depth': uintT,
verified: booleanT
}, )
}
],
output: tupleT({
'cur-hash': bufferT,
path: numberT,
path: uintT,
'proof-hashes': listT(bufferT, ),
'root-hash': bufferT,
'tree-depth': numberT,
'tree-depth': uintT,
verified: booleanT
}, ),
mode: 'readonly'
},
'inner-reverse': {
input: [
{ name: 'target-index', type: numberT },
{ name: 'target-index', type: uintT },
{ name: 'hash-input', type: bufferT }
],
output: bufferT,
mode: 'readonly'
},
'is-bit-set': {
input: [ { name: 'val', type: numberT }, { name: 'bit', type: numberT } ],
input: [ { name: 'val', type: uintT }, { name: 'bit', type: uintT } ],
output: booleanT,
mode: 'readonly'
},
@@ -87,11 +87,11 @@ export const clarityBitcoin = defineContract({
input: [ { name: 'headerbuff', type: bufferT } ],
output: responseSimpleT(tupleT({
'merkle-root': bufferT,
nbits: numberT,
nonce: numberT,
nbits: uintT,
nonce: uintT,
parent: bufferT,
timestamp: numberT,
version: numberT
timestamp: uintT,
version: uintT
}, ), ),
mode: 'readonly'
},
@@ -99,13 +99,13 @@ export const clarityBitcoin = defineContract({
input: [ { name: 'tx', type: bufferT } ],
output: responseSimpleT(tupleT({
ins: listT(tupleT({
outpoint: tupleT({ hash: bufferT, index: numberT }, ),
outpoint: tupleT({ hash: bufferT, index: uintT }, ),
scriptSig: bufferT,
sequence: numberT
sequence: uintT
}, ), ),
locktime: numberT,
outs: listT(tupleT({ scriptPubKey: bufferT, value: numberT }, ), ),
version: numberT
locktime: uintT,
outs: listT(tupleT({ scriptPubKey: bufferT, value: uintT }, ), ),
version: uintT
}, ), ),
mode: 'readonly'
},
@@ -113,15 +113,15 @@ export const clarityBitcoin = defineContract({
input: [ { name: 'tx', type: bufferT } ],
output: responseSimpleT(tupleT({
ins: listT(tupleT({
outpoint: tupleT({ hash: bufferT, index: numberT }, ),
outpoint: tupleT({ hash: bufferT, index: uintT }, ),
scriptSig: bufferT,
sequence: numberT
sequence: uintT
}, ), ),
locktime: numberT,
outs: listT(tupleT({ scriptPubKey: bufferT, value: numberT }, ), ),
'segwit-marker': numberT,
'segwit-version': numberT,
version: numberT,
locktime: uintT,
outs: listT(tupleT({ scriptPubKey: bufferT, value: uintT }, ), ),
'segwit-marker': uintT,
'segwit-version': uintT,
version: uintT,
witnesses: listT(listT(bufferT, ), )
}, ), ),
mode: 'readonly'
@@ -130,11 +130,11 @@ export const clarityBitcoin = defineContract({
input: [
{
name: 'old-ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
hashslice: bufferT
}, ), ),
mode: 'readonly'
@@ -145,13 +145,13 @@ export const clarityBitcoin = defineContract({
{
name: 'state-res',
type: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
elements: listT(bufferT, )
}, ), )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
elements: listT(bufferT, )
}, ), ),
mode: 'readonly'
@@ -162,23 +162,23 @@ export const clarityBitcoin = defineContract({
{
name: 'state-res',
type: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
remaining: numberT,
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
remaining: uintT,
txins: listT(tupleT({
outpoint: tupleT({ hash: bufferT, index: numberT }, ),
outpoint: tupleT({ hash: bufferT, index: uintT }, ),
scriptSig: bufferT,
sequence: numberT
sequence: uintT
}, ), )
}, ), )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
remaining: numberT,
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
remaining: uintT,
txins: listT(tupleT({
outpoint: tupleT({ hash: bufferT, index: numberT }, ),
outpoint: tupleT({ hash: bufferT, index: uintT }, ),
scriptSig: bufferT,
sequence: numberT
sequence: uintT
}, ), )
}, ), ),
mode: 'readonly'
@@ -189,14 +189,14 @@ export const clarityBitcoin = defineContract({
{
name: 'state-res',
type: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
txouts: listT(tupleT({ scriptPubKey: bufferT, value: numberT }, ), )
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
txouts: listT(tupleT({ scriptPubKey: bufferT, value: uintT }, ), )
}, ), )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
txouts: listT(tupleT({ scriptPubKey: bufferT, value: numberT }, ), )
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
txouts: listT(tupleT({ scriptPubKey: bufferT, value: uintT }, ), )
}, ), ),
mode: 'readonly'
},
@@ -206,13 +206,13 @@ export const clarityBitcoin = defineContract({
{
name: 'state-res',
type: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
witnesses: listT(listT(bufferT, ), )
}, ), )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
witnesses: listT(listT(bufferT, ), )
}, ), ),
mode: 'readonly'
@@ -221,16 +221,16 @@ export const clarityBitcoin = defineContract({
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
remaining: numberT,
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
remaining: uintT,
txins: listT(tupleT({
outpoint: tupleT({ hash: bufferT, index: numberT }, ),
outpoint: tupleT({ hash: bufferT, index: uintT }, ),
scriptSig: bufferT,
sequence: numberT
sequence: uintT
}, ), )
}, ), ),
mode: 'readonly'
@@ -239,12 +239,12 @@ export const clarityBitcoin = defineContract({
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
txouts: listT(tupleT({ scriptPubKey: bufferT, value: numberT }, ), )
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
txouts: listT(tupleT({ scriptPubKey: bufferT, value: uintT }, ), )
}, ), ),
mode: 'readonly'
},
@@ -252,75 +252,72 @@ export const clarityBitcoin = defineContract({
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({ ctx: tupleT({ index: numberT, txbuff: bufferT }, ), uint16: numberT }, ), ),
output: responseSimpleT(tupleT({ ctx: tupleT({ index: uintT, txbuff: bufferT }, ), uint16: uintT }, ), ),
mode: 'readonly'
},
'read-uint32': {
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({ ctx: tupleT({ index: numberT, txbuff: bufferT }, ), uint32: numberT }, ), ),
output: responseSimpleT(tupleT({ ctx: tupleT({ index: uintT, txbuff: bufferT }, ), uint32: uintT }, ), ),
mode: 'readonly'
},
'read-uint64': {
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({ ctx: tupleT({ index: numberT, txbuff: bufferT }, ), uint64: numberT }, ), ),
output: responseSimpleT(tupleT({ ctx: tupleT({ index: uintT, txbuff: bufferT }, ), uint64: uintT }, ), ),
mode: 'readonly'
},
'read-uint8': {
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({ ctx: tupleT({ index: numberT, txbuff: bufferT }, ), uint8: numberT }, ), ),
output: responseSimpleT(tupleT({ ctx: tupleT({ index: uintT, txbuff: bufferT }, ), uint8: uintT }, ), ),
mode: 'readonly'
},
'read-varint': {
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({ ctx: tupleT({ index: numberT, txbuff: bufferT }, ), varint: numberT }, ), ),
output: responseSimpleT(tupleT({ ctx: tupleT({ index: uintT, txbuff: bufferT }, ), varint: uintT }, ), ),
mode: 'readonly'
},
'read-varslice': {
input: [
{
name: 'old-ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
}
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
varslice: bufferT
}, ), ),
output: responseSimpleT(tupleT({ ctx: tupleT({ index: uintT, txbuff: bufferT }, ), varslice: bufferT }, ), ),
mode: 'readonly'
},
'read-witnesses': {
input: [
{
name: 'ctx',
type: tupleT({ index: numberT, txbuff: bufferT }, )
type: tupleT({ index: uintT, txbuff: bufferT }, )
},
{ name: 'num-txins', type: numberT }
{ name: 'num-txins', type: uintT }
],
output: responseSimpleT(tupleT({
ctx: tupleT({ index: numberT, txbuff: bufferT }, ),
ctx: tupleT({ index: uintT, txbuff: bufferT }, ),
witnesses: listT(listT(bufferT, ), )
}, ), ),
mode: 'readonly'
@@ -333,7 +330,7 @@ export const clarityBitcoin = defineContract({
'verify-block-header': {
input: [
{ name: 'headerbuff', type: bufferT },
{ name: 'expected-block-height', type: numberT }
{ name: 'expected-block-height', type: uintT }
],
output: booleanT,
mode: 'readonly'
@@ -344,11 +341,7 @@ export const clarityBitcoin = defineContract({
{ name: 'merkle-root', type: bufferT },
{
name: 'proof',
type: tupleT({
hashes: listT(bufferT, ),
'tree-depth': numberT,
'tx-index': numberT
}, )
type: tupleT({ hashes: listT(bufferT, ), 'tree-depth': uintT, 'tx-index': uintT }, )
}
],
output: responseSimpleT(booleanT, ),
@@ -358,16 +351,12 @@ export const clarityBitcoin = defineContract({
input: [
{
name: 'block',
type: tupleT({ header: bufferT, height: numberT }, )
type: tupleT({ header: bufferT, height: uintT }, )
},
{ name: 'tx', type: bufferT },
{
name: 'proof',
type: tupleT({
hashes: listT(bufferT, ),
'tree-depth': numberT,
'tx-index': numberT
}, )
type: tupleT({ hashes: listT(bufferT, ), 'tree-depth': uintT, 'tx-index': uintT }, )
}
],
output: responseSimpleT(booleanT, ),
@@ -377,22 +366,18 @@ export const clarityBitcoin = defineContract({
input: [
{
name: 'block',
type: tupleT({ header: bufferT, height: numberT }, )
type: tupleT({ header: bufferT, height: uintT }, )
},
{ name: 'tx', type: bufferT },
{
name: 'proof',
type: tupleT({
hashes: listT(bufferT, ),
'tree-depth': numberT,
'tx-index': numberT
}, )
type: tupleT({ hashes: listT(bufferT, ), 'tree-depth': uintT, 'tx-index': uintT }, )
}
],
output: responseSimpleT(booleanT, ),
mode: 'readonly'
},
'mock-burnchain-header-hashes': { input: numberT, output: optionalT(bufferT, ), mode: 'mapEntry' }
'mock-burnchain-header-hashes': { input: uintT, output: optionalT(bufferT, ), mode: 'mapEntry' }
}
} as const)

View File

@@ -4,7 +4,7 @@ defineContract,
bufferT,
principalT,
responseSimpleT,
numberT,
uintT,
booleanT,
listT,
tupleT,
@@ -20,7 +20,7 @@ export const indexer = defineContract({
{ name: 'validator-pubkey', type: bufferT },
{ name: 'validator', type: principalT }
],
output: responseSimpleT(numberT, ),
output: responseSimpleT(uintT, ),
mode: 'public'
},
'approve-relayer': {
@@ -36,22 +36,19 @@ export const indexer = defineContract({
{
name: 'tx-many',
type: listT(tupleT({
block: tupleT({ header: bufferT, height: numberT }, ),
proof: tupleT({
hashes: listT(bufferT, ),
'tree-depth': numberT,
'tx-index': numberT
}, ),
block: tupleT({ header: bufferT, height: uintT }, ),
proof: tupleT({ hashes: listT(bufferT, ), 'tree-depth': uintT, 'tx-index': uintT }, ),
'signature-packs': listT(tupleT({ signature: bufferT, signer: principalT, 'tx-hash': bufferT }, ), ),
tx: tupleT({
amt: numberT,
amt: uintT,
'bitcoin-tx': bufferT,
from: bufferT,
'from-bal': numberT,
output: numberT,
'from-bal': uintT,
offset: uintT,
output: uintT,
tick: stringT,
to: bufferT,
'to-bal': numberT
'to-bal': uintT
}, )
}, ), )
}
@@ -61,7 +58,7 @@ export const indexer = defineContract({
},
'remove-validator': {
input: [ { name: 'validator', type: principalT } ],
output: responseSimpleT(numberT, ),
output: responseSimpleT(uintT, ),
mode: 'public'
},
'set-contract-owner': {
@@ -75,36 +72,33 @@ export const indexer = defineContract({
mode: 'public'
},
'set-required-validators': {
input: [ { name: 'new-required-validators', type: numberT } ],
output: responseSimpleT(booleanT, ),
mode: 'public'
},
'set-user-balance': {
input: [
{ name: 'user', type: bufferT },
{ name: 'tick', type: stringT },
{ name: 'amt', type: numberT }
],
input: [ { name: 'new-required-validators', type: uintT } ],
output: responseSimpleT(booleanT, ),
mode: 'public'
},
'get-bitcoin-tx-indexed-or-fail': {
input: [
{ name: 'bitcoin-tx', type: bufferT },
{ name: 'output', type: numberT }
{ name: 'output', type: uintT },
{ name: 'offset', type: uintT }
],
output: responseSimpleT(tupleT({ amt: numberT, from: bufferT, tick: stringT, to: bufferT }, ), ),
output: responseSimpleT(tupleT({ amt: uintT, from: bufferT, tick: stringT, to: bufferT }, ), ),
mode: 'readonly'
},
'get-bitcoin-tx-mined-or-default': {
input: [ { name: 'tx', type: bufferT } ],
output: booleanT,
mode: 'readonly'
},
'get-contract-owner': { input: [], output: principalT, mode: 'readonly' },
'get-paused': { input: [], output: booleanT, mode: 'readonly' },
'get-required-validators': { input: [], output: numberT, mode: 'readonly' },
'get-required-validators': { input: [], output: uintT, mode: 'readonly' },
'get-user-balance-or-default': {
input: [
{ name: 'user', type: bufferT },
{ name: 'tick', type: stringT }
],
output: numberT,
output: tupleT({ balance: uintT, 'up-to-block': uintT }, ),
mode: 'readonly'
},
'get-validator-or-fail': {
@@ -117,14 +111,15 @@ export const indexer = defineContract({
{
name: 'tx',
type: tupleT({
amt: numberT,
amt: uintT,
'bitcoin-tx': bufferT,
from: bufferT,
'from-bal': numberT,
output: numberT,
'from-bal': uintT,
offset: uintT,
output: uintT,
tick: stringT,
to: bufferT,
'to-bal': numberT
'to-bal': uintT
}, )
}
],
@@ -147,15 +142,11 @@ export const indexer = defineContract({
{ name: 'tx', type: bufferT },
{
name: 'block',
type: tupleT({ header: bufferT, height: numberT }, )
type: tupleT({ header: bufferT, height: uintT }, )
},
{
name: 'proof',
type: tupleT({
hashes: listT(bufferT, ),
'tree-depth': numberT,
'tx-index': numberT
}, )
type: tupleT({ hashes: listT(bufferT, ), 'tree-depth': uintT, 'tx-index': uintT }, )
}
],
output: responseSimpleT(booleanT, ),
@@ -166,27 +157,17 @@ export const indexer = defineContract({
output: optionalT(booleanT, ),
mode: 'mapEntry'
},
'bitcoin-tx-indexed': {
input: tupleT({ output: numberT, 'tx-hash': bufferT }, ),
output: optionalT(tupleT({ amt: numberT, from: bufferT, tick: stringT, to: bufferT }, ), ),
mode: 'mapEntry'
},
'tx-validated-by': {
input: tupleT({ 'tx-hash': bufferT, validator: principalT }, ),
output: optionalT(booleanT, ),
mode: 'mapEntry'
},
'user-balance': {
input: tupleT({ tick: stringT, user: bufferT }, ),
output: optionalT(numberT, ),
mode: 'mapEntry'
},
validators: { input: principalT, output: optionalT(bufferT, ), mode: 'mapEntry' },
'contract-owner': { input: noneT, output: principalT, mode: 'variable' },
'is-paused': { input: noneT, output: booleanT, mode: 'variable' },
'required-validators': { input: noneT, output: numberT, mode: 'variable' },
'required-validators': { input: noneT, output: uintT, mode: 'variable' },
'tx-hash-to-iter': { input: noneT, output: bufferT, mode: 'variable' },
'validator-count': { input: noneT, output: numberT, mode: 'variable' }
'validator-count': { input: noneT, output: uintT, mode: 'variable' }
}
} as const)

View File

@@ -2,7 +2,7 @@
import {
defineContract,
bufferT,
numberT,
uintT,
booleanT,
stringAsciiT
} from "clarity-codegen"
@@ -11,7 +11,7 @@ export const utils = defineContract({
"utils": {
'byte-to-uint': {
input: [ { name: 'byte', type: bufferT } ],
output: numberT,
output: uintT,
mode: 'readonly'
},
'serialize-bool': {
@@ -30,7 +30,7 @@ export const utils = defineContract({
mode: 'readonly'
},
'serialize-uint': {
input: [ { name: 'value', type: numberT } ],
input: [ { name: 'value', type: uintT } ],
output: bufferT,
mode: 'readonly'
},
@@ -40,17 +40,17 @@ export const utils = defineContract({
mode: 'readonly'
},
'uint-to-byte': {
input: [ { name: 'n', type: numberT } ],
input: [ { name: 'n', type: uintT } ],
output: bufferT,
mode: 'readonly'
},
'uint128-to-buff-be': {
input: [ { name: 'n', type: numberT } ],
input: [ { name: 'n', type: uintT } ],
output: bufferT,
mode: 'readonly'
},
'uint32-to-buff-be': {
input: [ { name: 'n', type: numberT } ],
input: [ { name: 'n', type: uintT } ],
output: bufferT,
mode: 'readonly'
}

View File

@@ -3,9 +3,9 @@
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:108"
},
"377555038": {
"377555039": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:115"
"comment": "clarity-bitcoin.clar:116"
},
"377555067": {
"code": "ERR-OUT-OF-BOUNDS",
@@ -19,133 +19,133 @@
"code": "ERR-TOO-MANY-TXINS",
"comment": "clarity-bitcoin.clar:125"
},
"377555160": {
"377555190": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:153"
},
"377555163": {
"code": "ERR-TOO-MANY-TXINS",
"comment": "clarity-bitcoin.clar:156"
},
"377555191": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:163"
},
"377555192": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:164"
"comment": "clarity-bitcoin.clar:162"
},
"377555193": {
"code": "ERR-TOO-MANY-TXINS",
"comment": "clarity-bitcoin.clar:165"
},
"377555220": {
"377555221": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:172"
},
"377555222": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:173"
},
"377555223": {
"code": "ERR-TOO-MANY-TXINS",
"comment": "clarity-bitcoin.clar:171"
"comment": "clarity-bitcoin.clar:174"
},
"377555225": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:176"
},
"377555226": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:177"
},
"377555227": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:178"
},
"377555285": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:194"
},
"377555287": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:196"
},
"377555964": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:201"
},
"377555965": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:202"
},
"377555966": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:203"
},
"377555972": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:209"
},
"377556028": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:223"
},
"377556030": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:225"
},
"377556213": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:282"
},
"377556214": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:283"
},
"377556215": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:284"
},
"377556216": {
"377555251": {
"code": "ERR-TOO-MANY-TXINS",
"comment": "clarity-bitcoin.clar:285"
"comment": "clarity-bitcoin.clar:181"
},
"377558043": {
"code": "ERR-PROOF-TOO-SHORT",
"comment": "clarity-bitcoin.clar:453"
"377555256": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:186"
},
"377558046": {
"code": "ERR-PROOF-TOO-SHORT",
"comment": "clarity-bitcoin.clar:456"
"377555257": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:187"
},
"377558108": {
"377555258": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:188"
},
"377555971": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:208"
},
"377555994": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:210"
},
"377555999": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:215"
},
"377556000": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:216"
},
"377556001": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:217"
},
"377556029": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:224"
},
"377556088": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:241"
},
"377556090": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:243"
},
"377556248": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:296"
},
"377556249": {
"code": "ERR-VARSLICE-TOO-LONG",
"comment": "clarity-bitcoin.clar:297"
},
"377556250": {
"code": "ERR-TOO-MANY-TXOUTS",
"comment": "clarity-bitcoin.clar:298"
},
"377556251": {
"code": "ERR-TOO-MANY-TXINS",
"comment": "clarity-bitcoin.clar:299"
},
"377558071": {
"code": "ERR-PROOF-TOO-SHORT",
"comment": "clarity-bitcoin.clar:476"
"comment": "clarity-bitcoin.clar:460"
},
"377558074": {
"code": "ERR-PROOF-TOO-SHORT",
"comment": "clarity-bitcoin.clar:463"
},
"377558142": {
"code": "ERR-PROOF-TOO-SHORT",
"comment": "clarity-bitcoin.clar:489"
},
"2090389179": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:15"
},
"2090389183": {
"2090389205": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:19"
"comment": "clarity-bitcoin.clar:20"
},
"2090389209": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:24"
},
"2090389213": {
"2090389214": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:28"
"comment": "clarity-bitcoin.clar:29"
},
"2090389239": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:33"
},
"2090389243": {
"2090389244": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:37"
"comment": "clarity-bitcoin.clar:38"
},
"2090389269": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:42"
},
"2090389273": {
"2090389274": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:46"
"comment": "clarity-bitcoin.clar:47"
},
"2090389299": {
"code": "ERR-OUT-OF-BOUNDS",
@@ -159,72 +159,68 @@
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:77"
},
"2090389395": {
"2090389396": {
"code": "ERR-OUT-OF-BOUNDS",
"comment": "clarity-bitcoin.clar:84"
"comment": "clarity-bitcoin.clar:85"
},
"2894909962": {
"2894909907": {
"code": "ERR-VALIDATOR-ALREADY-REGISTERED",
"comment": "indexer.clar:70"
"comment": "indexer.clar:57"
},
"2894909993": {
"2894909936": {
"code": "ERR-UNKNOWN-VALIDATOR",
"comment": "indexer.clar:80"
"comment": "indexer.clar:65"
},
"2894910031": {
"2894909970": {
"code": "ERR-REQUIRED-VALIDATORS",
"comment": "indexer.clar:97"
"comment": "indexer.clar:78"
},
"3842857249": {
"2894910026": {
"code": "ERR-UNKNOWN-VALIDATOR",
"comment": "indexer.clar:123"
"comment": "indexer.clar:92"
},
"3842857315": {
"3842857193": {
"code": "ERR-DUPLICATE-SIGNATURE",
"comment": "indexer.clar:147"
"comment": "indexer.clar:109"
},
"3842857316": {
"3842857215": {
"code": "ERR-ORDER-HASH-MISMATCH",
"comment": "indexer.clar:148"
"comment": "indexer.clar:110"
},
"3842857317": {
"3842857216": {
"code": "ERR-INVALID-SIGNATURE",
"comment": "indexer.clar:149"
"comment": "indexer.clar:111"
},
"3842857347": {
"code": "ERR-TX-NOT-INDEXED",
"comment": "indexer.clar:158"
"3842857284": {
"code": "ERR-PAUSED",
"comment": "indexer.clar:137"
},
"3842857285": {
"code": "ERR-UKNOWN-RELAYER",
"comment": "indexer.clar:138"
},
"3842857403": {
"code": "ERR-TX-ALREADY-INDEXED",
"comment": "indexer.clar:172"
},
"3842857404": {
"code": "ERR-PAUSED",
"code": "ERR-REQUIRED-VALIDATORS",
"comment": "indexer.clar:173"
},
"3842857405": {
"code": "ERR-UKNOWN-RELAYER",
"comment": "indexer.clar:174"
},
"3842858185": {
"code": "ERR-TX-ALREADY-INDEXED",
"comment": "indexer.clar:219"
},
"3842858207": {
"code": "ERR-REQUIRED-VALIDATORS",
"comment": "indexer.clar:220"
},
"3842858208": {
"code": "ERR-DOUBLE-SPEND",
"comment": "indexer.clar:221"
},
"3842858209": {
"code": "ERR-FROM-BAL-MISMATCH",
"comment": "indexer.clar:222"
},
"3842858210": {
"code": "ERR-TO-BAL-MISMATCH",
"comment": "indexer.clar:223"
},
"3842858269": {
"3842857466": {
"code": "ERR-NOT-AUTHORIZED",
"comment": "indexer.clar:240"
"comment": "indexer.clar:193"
},
"4072773152": {
"code": "ERR-TX-NOT-INDEXED",
"comment": "indexer-registry.clar:58"
},
"4072773241": {
"code": "ERR-NOT-AUTHORIZED",
"comment": "indexer-registry.clar:84"
},
"4072773245": {
"code": "ERR-NOT-AUTHORIZED",
"comment": "indexer-registry.clar:88"
}
}

View File

@@ -12,27 +12,27 @@
},
"dependencies": {
"@iarna/toml": "^2.2.5",
"@noble/hashes": "^1.3.1",
"@noble/hashes": "^1.3.2",
"@stacks/keychain": "^4.3.8",
"@stacks/network": "^6.5.5",
"@stacks/stacks-blockchain-api-types": "^7.3.0",
"@stacks/transactions": "^6.7.0",
"bignumber.js": "^9.1.1",
"bignumber.js": "^9.1.2",
"bitcoinjs-lib": "^6.1.3",
"clarity-codegen": "^0.2.2",
"clarity-codegen": "^0.2.6",
"got-cjs": "^12.5.4",
"lodash": "^4.17.21",
"micro-btc-signer": "^0.4.2",
"micro-stacks": "^1.2.1",
"tsx": "^3.12.7"
"tsx": "^3.12.8"
},
"devDependencies": {
"@swc/core": "^1.3.73",
"@swc/core": "^1.3.82",
"@types/lodash": "^4.14.197",
"@types/node": "^20.4.5",
"prettier": "^3.0.0",
"@types/node": "^20.5.9",
"prettier": "^3.0.3",
"prettier-plugin-organize-imports": "^3.2.3",
"ts-node": "^10.9.1",
"typescript": "^5.1.6"
"typescript": "^5.2.2"
}
}

1797
pnpm-lock.yaml generated Normal file

File diff suppressed because it is too large Load Diff