@xyo-network/chain-services 1.11.0 → 1.12.1
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/dist/neutral/AccountBalance/BaseAccountBalanceService.d.ts.map +1 -1
- package/dist/neutral/BlockProducer/BaseBlockProducerService.d.ts +17 -3
- package/dist/neutral/BlockProducer/BaseBlockProducerService.d.ts.map +1 -1
- package/dist/neutral/ChainBlockNumberIteration/model/BlockNumberIteration.d.ts +2 -2
- package/dist/neutral/ChainBlockNumberIteration/model/BlockNumberIteration.d.ts.map +1 -1
- package/dist/neutral/ChainValidator/XyoValidator.d.ts +20 -7
- package/dist/neutral/ChainValidator/XyoValidator.d.ts.map +1 -1
- package/dist/neutral/ChainValidator/model/Validator.d.ts +2 -2
- package/dist/neutral/ChainValidator/model/Validator.d.ts.map +1 -1
- package/dist/neutral/PendingTransactions/BasePendingTransactions.d.ts +4 -4
- package/dist/neutral/PendingTransactions/BasePendingTransactions.d.ts.map +1 -1
- package/dist/neutral/PendingTransactions/bundledPayloadToHydratedTransaction.d.ts +2 -2
- package/dist/neutral/PendingTransactions/bundledPayloadToHydratedTransaction.d.ts.map +1 -1
- package/dist/neutral/PendingTransactions/hydratedTransactionToPayloadBundle.d.ts +2 -2
- package/dist/neutral/PendingTransactions/hydratedTransactionToPayloadBundle.d.ts.map +1 -1
- package/dist/neutral/StakeIntent/XyoStakeIntentService.d.ts +5 -1
- package/dist/neutral/StakeIntent/XyoStakeIntentService.d.ts.map +1 -1
- package/dist/neutral/index.mjs +344 -225
- package/dist/neutral/index.mjs.map +1 -1
- package/package.json +37 -37
- package/src/AccountBalance/BaseAccountBalanceService.ts +2 -1
- package/src/BlockProducer/spec/BaseBlockProducerService.spec.ts +3 -3
- package/src/BlockProducer/spec/generateTransactionTransfer.spec.ts +2 -2
- package/src/ChainBlockNumberIteration/model/BlockNumberIteration.ts +2 -2
- package/src/ChainValidator/XyoValidator.ts +4 -4
- package/src/ChainValidator/model/Validator.ts +2 -2
- package/src/PendingTransactions/BasePendingTransactions.ts +8 -7
- package/src/PendingTransactions/bundledPayloadToHydratedTransaction.ts +2 -2
- package/src/PendingTransactions/hydratedTransactionToPayloadBundle.ts +3 -3
- package/src/PendingTransactions/spec/BasePendingTransactions.spec.ts +11 -10
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseAccountBalanceService.d.ts","sourceRoot":"","sources":["../../../src/AccountBalance/BaseAccountBalanceService.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAC3C,OAAO,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAA;AAC5D,OAAO,EACL,uBAAuB,EACvB,OAAO,EAAE,iBAAiB,EAC3B,MAAM,2BAA2B,CAAA;AAClC,OAAO,EACL,mBAAmB,EAEpB,MAAM,+BAA+B,CAAA;AAEtC,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAErD,MAAM,WAAW,+BAAgC,SAAQ,iBAAiB;IACxE,cAAc,EAAE,aAAa,CAAA;IAC7B,iBAAiB,EAAE,iBAAiB,CAAC,IAAI,EAAE,mBAAmB,CAAC,CAAA;CAChE;AAED,qBACa,yBAA0B,SAAQ,WAAW,CAAC,+BAA+B,CAAE,YAAW,uBAAuB;IACtH,QAAQ,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"BaseAccountBalanceService.d.ts","sourceRoot":"","sources":["../../../src/AccountBalance/BaseAccountBalanceService.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAC3C,OAAO,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAA;AAC5D,OAAO,EACL,uBAAuB,EACvB,OAAO,EAAE,iBAAiB,EAC3B,MAAM,2BAA2B,CAAA;AAClC,OAAO,EACL,mBAAmB,EAEpB,MAAM,+BAA+B,CAAA;AAEtC,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAErD,MAAM,WAAW,+BAAgC,SAAQ,iBAAiB;IACxE,cAAc,EAAE,aAAa,CAAA;IAC7B,iBAAiB,EAAE,iBAAiB,CAAC,IAAI,EAAE,mBAAmB,CAAC,CAAA;CAChE;AAED,qBACa,yBAA0B,SAAQ,WAAW,CAAC,+BAA+B,CAAE,YAAW,uBAAuB;IACtH,QAAQ,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;CAW3F"}
|
|
@@ -37,11 +37,25 @@ export declare class BaseBlockProducerService extends BaseService<BaseBlockProdu
|
|
|
37
37
|
* their intent to continue producing blocks
|
|
38
38
|
*/
|
|
39
39
|
static get RedeclarationWindow(): number;
|
|
40
|
-
get address():
|
|
40
|
+
get address(): import("@xylabs/typeof").Brand<import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
41
|
+
readonly __hex: true;
|
|
42
|
+
}>, {
|
|
43
|
+
readonly __address: true;
|
|
44
|
+
}>;
|
|
41
45
|
protected get account(): import("@xyo-network/account-model").AccountInstance;
|
|
42
46
|
protected get balanceService(): AccountBalanceServiceV2;
|
|
43
|
-
protected get chainArchivist(): import("@xyo-network/archivist-model").ReadArchivist<import("@xyo-network/payload-model").Payload, import("@xylabs/
|
|
44
|
-
|
|
47
|
+
protected get chainArchivist(): import("@xyo-network/archivist-model").ReadArchivist<import("@xyo-network/payload-model").Payload, import("@xylabs/typeof").Brand<import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
48
|
+
readonly __hex: true;
|
|
49
|
+
}>, {
|
|
50
|
+
readonly __hash: true;
|
|
51
|
+
}>, import("@xyo-network/payload-model").Sequence>;
|
|
52
|
+
protected get chainId(): import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
53
|
+
readonly __hex: true;
|
|
54
|
+
}> | import("@xylabs/typeof").Brand<import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
55
|
+
readonly __hex: true;
|
|
56
|
+
}>, {
|
|
57
|
+
readonly __address: true;
|
|
58
|
+
}>;
|
|
45
59
|
protected get electionService(): import("@xyo-network/xl1-protocol").ElectionService;
|
|
46
60
|
protected get pendingTransactionsService(): PendingTransactionsService;
|
|
47
61
|
protected get rejectedTransactionsArchivist(): ArchivistInstance<import("@xyo-network/archivist-model").ArchivistParams<import("@xyo-network/module-model").AnyConfigSchema<import("@xyo-network/archivist-model").ArchivistConfig>>, import("@xyo-network/archivist-model").ArchivistModuleEventData, import("@xyo-network/payload-model").Payload>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseBlockProducerService.d.ts","sourceRoot":"","sources":["../../../src/BlockProducer/BaseBlockProducerService.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,OAAO,EACR,MAAM,aAAa,CAAA;AACpB,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAA;AAChE,OAAO,EACL,kBAAkB,EACnB,MAAM,4BAA4B,CAAA;AAGnC,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAA;AAC5D,OAAO,EACL,uBAAuB,EAC4B,iBAAiB,EACpE,oBAAoB,EAAE,gBAAgB,EACtC,aAAa,EAAE,0BAA0B,EAAE,kBAAkB,EAAE,QAAQ,EACxE,MAAM,2BAA2B,CAAA;AAElC,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAA;AAG/D;;GAEG;AACH,eAAO,MAAM,kBAAkB,KAAK,CAAA;AAKpC,eAAO,MAAM,mCAAmC,QAAS,CAAA;AAEzD;;;GAGG;AACH,eAAO,MAAM,iCAAiC,MAAM,CAAA;AAEpD,MAAM,WAAW,8BAA+B,SAAQ,kBAAkB;IACxE,cAAc,EAAE,uBAAuB,CAAA;IACvC,0BAA0B,EAAE,0BAA0B,CAAA;IACtD,6BAA6B,EAAE,iBAAiB,CAAA;IAChD,aAAa,EAAE,OAAO,CAAA;CACvB;AAED,qBACa,wBAAyB,SAAQ,WAAW,CAAC,8BAA8B,CAAE,YAAW,oBAAoB;IACvH,SAAS,CAAC,mBAAmB,EAAE,kBAAkB,GAAG,SAAS,CAAA;IAE7D;;OAEG;IACH,MAAM,KAAK,gBAAgB,IAAI,MAAM,CAEpC;IAED;;;OAGG;IACH,MAAM,KAAK,qBAAqB,IAAI,MAAM,CAEzC;IAED;;;OAGG;IACH,MAAM,KAAK,mBAAmB,IAAI,MAAM,CAEvC;IAED,IAAI,OAAO
|
|
1
|
+
{"version":3,"file":"BaseBlockProducerService.d.ts","sourceRoot":"","sources":["../../../src/BlockProducer/BaseBlockProducerService.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,OAAO,EACR,MAAM,aAAa,CAAA;AACpB,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAA;AAChE,OAAO,EACL,kBAAkB,EACnB,MAAM,4BAA4B,CAAA;AAGnC,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAA;AAC5D,OAAO,EACL,uBAAuB,EAC4B,iBAAiB,EACpE,oBAAoB,EAAE,gBAAgB,EACtC,aAAa,EAAE,0BAA0B,EAAE,kBAAkB,EAAE,QAAQ,EACxE,MAAM,2BAA2B,CAAA;AAElC,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAA;AAG/D;;GAEG;AACH,eAAO,MAAM,kBAAkB,KAAK,CAAA;AAK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,CAAC,GAAG,OAAO,CAAC,gBAAgB,GAAG,SAAS,CAAC;cAiBzG,qBAAqB,CAAC,IAAI,EAAE,eAAe,CAAC,iBAAiB,CAAC,EAAE,gBAAgB,UAAQ,GAAG,OAAO,CAAC,aAAa,GAAG,SAAS,CAAC;CAqD9I"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Promisable } from '@xylabs/promise';
|
|
2
|
-
import type { BlockBoundWitness,
|
|
2
|
+
import type { BlockBoundWitness, SignedHydratedTransactionWithStorageMeta } from '@xyo-network/xl1-protocol';
|
|
3
3
|
export interface BlockNumberIteration {
|
|
4
4
|
validatePendingBlock(block: BlockBoundWitness): Promisable<Error[]>;
|
|
5
|
-
validatePendingTransaction(tx:
|
|
5
|
+
validatePendingTransaction(tx: SignedHydratedTransactionWithStorageMeta): Promise<boolean>;
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=BlockNumberIteration.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BlockNumberIteration.d.ts","sourceRoot":"","sources":["../../../../src/ChainBlockNumberIteration/model/BlockNumberIteration.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AACjD,OAAO,KAAK,EAAE,iBAAiB,EAAE,
|
|
1
|
+
{"version":3,"file":"BlockNumberIteration.d.ts","sourceRoot":"","sources":["../../../../src/ChainBlockNumberIteration/model/BlockNumberIteration.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AACjD,OAAO,KAAK,EAAE,iBAAiB,EAAE,wCAAwC,EAAE,MAAM,2BAA2B,CAAA;AAE5G,MAAM,WAAW,oBAAoB;IACnC,oBAAoB,CAAC,KAAK,EAAE,iBAAiB,GAAG,UAAU,CAAC,KAAK,EAAE,CAAC,CAAA;IACnE,0BAA0B,CAAC,EAAE,EAAE,wCAAwC,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;CAC3F"}
|
|
@@ -1,15 +1,14 @@
|
|
|
1
|
-
import { Address } from '@xylabs/hex';
|
|
2
1
|
import { Promisable } from '@xylabs/promise';
|
|
3
2
|
import { AccountInstance } from '@xyo-network/account-model';
|
|
4
3
|
import { ArchivistInstance, ReadArchivist } from '@xyo-network/archivist-model';
|
|
5
|
-
import { BlockBoundWitness, BlockRewardService, ElectionService, HydratedBlockStateValidationFunctionV2,
|
|
4
|
+
import { BlockBoundWitness, BlockRewardService, Chain, ElectionService, HydratedBlockStateValidationFunctionV2, SignedHydratedTransactionWithStorageMeta, StakeIntentService } from '@xyo-network/xl1-protocol';
|
|
6
5
|
import { BaseService } from '../BaseService.ts';
|
|
7
6
|
import { BaseServiceParams } from '../model/index.ts';
|
|
8
7
|
import { Validator } from './model/index.ts';
|
|
9
8
|
export interface XyoValidatorParams extends BaseServiceParams {
|
|
10
9
|
account: AccountInstance;
|
|
11
10
|
chainArchivist: ReadArchivist;
|
|
12
|
-
chainId:
|
|
11
|
+
chainId: Chain;
|
|
13
12
|
electionService: ElectionService;
|
|
14
13
|
pendingBundledTransactionsArchivist: ArchivistInstance;
|
|
15
14
|
rewardService: BlockRewardService;
|
|
@@ -17,14 +16,28 @@ export interface XyoValidatorParams extends BaseServiceParams {
|
|
|
17
16
|
validateHydratedBlockState: HydratedBlockStateValidationFunctionV2;
|
|
18
17
|
}
|
|
19
18
|
export declare class XyoValidator<TParams extends XyoValidatorParams = XyoValidatorParams> extends BaseService<TParams> implements Validator {
|
|
20
|
-
get address():
|
|
19
|
+
get address(): import("@xylabs/typeof").Brand<import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
20
|
+
readonly __hex: true;
|
|
21
|
+
}>, {
|
|
22
|
+
readonly __address: true;
|
|
23
|
+
}>;
|
|
21
24
|
protected get account(): AccountInstance;
|
|
22
|
-
protected get chainArchivist(): ReadArchivist<import("@xyo-network/payload-model").Payload, import("@xylabs/
|
|
23
|
-
|
|
25
|
+
protected get chainArchivist(): ReadArchivist<import("@xyo-network/payload-model").Payload, import("@xylabs/typeof").Brand<import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
26
|
+
readonly __hex: true;
|
|
27
|
+
}>, {
|
|
28
|
+
readonly __hash: true;
|
|
29
|
+
}>, import("@xyo-network/payload-model").Sequence>;
|
|
30
|
+
protected get chainInfo(): import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
31
|
+
readonly __hex: true;
|
|
32
|
+
}> | import("@xylabs/typeof").Brand<import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
33
|
+
readonly __hex: true;
|
|
34
|
+
}>, {
|
|
35
|
+
readonly __address: true;
|
|
36
|
+
}>;
|
|
24
37
|
protected get electionService(): ElectionService;
|
|
25
38
|
protected get pendingBundledTransactionsArchivist(): ArchivistInstance<import("@xyo-network/archivist-model").ArchivistParams<import("@xyo-network/module-model").AnyConfigSchema<import("@xyo-network/archivist-model").ArchivistConfig>>, import("@xyo-network/archivist-model").ArchivistModuleEventData, import("@xyo-network/payload-model").Payload>;
|
|
26
39
|
protected get rewardService(): BlockRewardService;
|
|
27
40
|
validatePendingBlock(_block: BlockBoundWitness): Promisable<Error[]>;
|
|
28
|
-
validatePendingTransaction(hydratedTransaction:
|
|
41
|
+
validatePendingTransaction(hydratedTransaction: SignedHydratedTransactionWithStorageMeta): Promise<boolean>;
|
|
29
42
|
}
|
|
30
43
|
//# sourceMappingURL=XyoValidator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"XyoValidator.d.ts","sourceRoot":"","sources":["../../../src/ChainValidator/XyoValidator.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"XyoValidator.d.ts","sourceRoot":"","sources":["../../../src/ChainValidator/XyoValidator.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAC5C,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAA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import type { BlockBoundWitness,
|
|
2
|
+
import type { BlockBoundWitness, SignedHydratedTransactionWithStorageMeta } from '@xyo-network/xl1-protocol';
|
|
3
3
|
export interface Validator {
|
|
4
4
|
validatePendingBlock(block: BlockBoundWitness): Promisable<Error[]>;
|
|
5
|
-
validatePendingTransaction(tx:
|
|
5
|
+
validatePendingTransaction(tx: SignedHydratedTransactionWithStorageMeta): Promise<boolean>;
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=Validator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Validator.d.ts","sourceRoot":"","sources":["../../../../src/ChainValidator/model/Validator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AACjD,OAAO,KAAK,EAAE,iBAAiB,EAAE,
|
|
1
|
+
{"version":3,"file":"Validator.d.ts","sourceRoot":"","sources":["../../../../src/ChainValidator/model/Validator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AACjD,OAAO,KAAK,EAAE,iBAAiB,EAAE,wCAAwC,EAAE,MAAM,2BAA2B,CAAA;AAE5G,MAAM,WAAW,SAAS;IACxB,oBAAoB,CAAC,KAAK,EAAE,iBAAiB,GAAG,UAAU,CAAC,KAAK,EAAE,CAAC,CAAA;IACnE,0BAA0B,CAAC,EAAE,EAAE,wCAAwC,GAAG,OAAO,CAAC,OAAO,CAAC,CAAA;CAC3F"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Hash } from '@xylabs/hex';
|
|
2
2
|
import { ArchivistInstance } from '@xyo-network/archivist-model';
|
|
3
|
-
import {
|
|
3
|
+
import { Chain, PendingTransactionsService, SignedHydratedTransactionWithStorageMeta } from '@xyo-network/xl1-protocol';
|
|
4
4
|
import { BaseService } from '../BaseService.ts';
|
|
5
5
|
import { BaseServiceParams } from '../model/index.ts';
|
|
6
6
|
export interface BasePendingTransactionsServiceParams extends BaseServiceParams {
|
|
7
7
|
chainArchivist?: ArchivistInstance;
|
|
8
|
-
chainId?:
|
|
8
|
+
chainId?: Chain;
|
|
9
9
|
pendingBundledTransactionsArchivist?: ArchivistInstance;
|
|
10
10
|
rejectedTransactionsArchivist?: ArchivistInstance;
|
|
11
11
|
}
|
|
@@ -43,7 +43,7 @@ export declare class BasePendingTransactionsService extends BaseService<BasePend
|
|
|
43
43
|
private get pendingTransactionsCount();
|
|
44
44
|
private get rejectedTransactionsArchivist();
|
|
45
45
|
createHandler(): Promise<void>;
|
|
46
|
-
getPendingTransactions(head: Hash, limit: number): Promise<
|
|
46
|
+
getPendingTransactions(head: Hash, limit: number): Promise<SignedHydratedTransactionWithStorageMeta[]>;
|
|
47
47
|
private cleanupWorker;
|
|
48
48
|
private countPendingTransactions;
|
|
49
49
|
private filterAlreadyFinalizedTransactions;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BasePendingTransactions.d.ts","sourceRoot":"","sources":["../../../src/PendingTransactions/BasePendingTransactions.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"BasePendingTransactions.d.ts","sourceRoot":"","sources":["../../../src/PendingTransactions/BasePendingTransactions.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAGlC,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAA;AAKhE,OAAO,EACmC,KAAK,EAA4C,0BAA0B,EACnH,wCAAwC,EACzC,MAAM,2BAA2B,CAAA;AAIlC,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAIrD,MAAM,WAAW,oCAAqC,SAAQ,iBAAiB;IAC7E,cAAc,CAAC,EAAE,iBAAiB,CAAA;IAClC,OAAO,CAAC,EAAE,KAAK,CAAA;IACf,mCAAmC,CAAC,EAAE,iBAAiB,CAAA;IACvD,6BAA6B,CAAC,EAAE,iBAAiB,CAAA;CAClD;AAED,qBACa,8BAA+B,SAAQ,WAAW,CAAC,oCAAoC,CAAE,YAAW,0BAA0B;IACzI,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,aAAa,CAa3B;IAEV;;;OAGG;IACH,OAAO,CAAC,8BAA8B,CAAc;IAEpD;;;OAGG;IACH,OAAO,CAAC,2CAA2C,CAA6B;IAEhF;;OAEG;IACH,OAAO,CAAC,yBAAyB,CAAY;IAE7C;;;;OAIG;IACH,OAAO,CAAC,kCAAkC,CAAuB;IAEjE;;;OAGG;IACH,OAAO,CAAC,+CAA+C,CAAc;IAErE,OAAO,KAAK,cAAc,GAEzB;IAED,OAAO,KAAK,OAAO,GAElB;IAED,OAAO,KAAK,mCAAmC,GAE9C;IAED,OAAO,KAAK,wCAAwC,GAEnD;IAED,OAAO,KAAK,wBAAwB,GAGnC;IAED,OAAO,KAAK,6BAA6B,GAExC;IAEc,aAAa;IAgCtB,sBAAsB,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,wCAAwC,EAAE,CAAC;YAyD9F,aAAa;YAOb,wBAAwB;YAQxB,kCAAkC;YAUlC,qBAAqB;IA0BnC;;;;;OAKG;IACH,OAAO,CAAC,qCAAqC;YAO/B,wCAAwC;CAsEvD"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { PayloadBundle, WithStorageMeta } from '@xyo-network/payload-model';
|
|
2
|
-
import type {
|
|
3
|
-
export declare const bundledPayloadToHydratedTransaction: (payload: WithStorageMeta<PayloadBundle>) => Promise<
|
|
2
|
+
import type { SignedHydratedTransactionWithStorageMeta } from '@xyo-network/xl1-protocol';
|
|
3
|
+
export declare const bundledPayloadToHydratedTransaction: (payload: WithStorageMeta<PayloadBundle>) => Promise<SignedHydratedTransactionWithStorageMeta | undefined>;
|
|
4
4
|
//# sourceMappingURL=bundledPayloadToHydratedTransaction.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bundledPayloadToHydratedTransaction.d.ts","sourceRoot":"","sources":["../../../src/PendingTransactions/bundledPayloadToHydratedTransaction.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAA;AAChF,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"bundledPayloadToHydratedTransaction.d.ts","sourceRoot":"","sources":["../../../src/PendingTransactions/bundledPayloadToHydratedTransaction.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAA;AAChF,OAAO,KAAK,EAAE,wCAAwC,EAAE,MAAM,2BAA2B,CAAA;AAGzF,eAAO,MAAM,mCAAmC,GAC9C,SAAS,eAAe,CAAC,aAAa,CAAC,KACtC,OAAO,CAAC,wCAAwC,GAAG,SAAS,CAM9D,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { PayloadBundle } from '@xyo-network/payload-model';
|
|
2
|
-
import type {
|
|
3
|
-
export declare const hydratedTransactionToPayloadBundle: (transaction:
|
|
2
|
+
import type { SignedHydratedTransactionWithStorageMeta } from '@xyo-network/xl1-protocol';
|
|
3
|
+
export declare const hydratedTransactionToPayloadBundle: (transaction: SignedHydratedTransactionWithStorageMeta) => PayloadBundle;
|
|
4
4
|
//# sourceMappingURL=hydratedTransactionToPayloadBundle.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hydratedTransactionToPayloadBundle.d.ts","sourceRoot":"","sources":["../../../src/PendingTransactions/hydratedTransactionToPayloadBundle.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAE/D,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"hydratedTransactionToPayloadBundle.d.ts","sourceRoot":"","sources":["../../../src/PendingTransactions/hydratedTransactionToPayloadBundle.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAE/D,OAAO,KAAK,EAAE,wCAAwC,EAAE,MAAM,2BAA2B,CAAA;AAGzF,eAAO,MAAM,kCAAkC,GAAI,aAAa,wCAAwC,KAAG,aAG1G,CAAA"}
|
|
@@ -17,7 +17,11 @@ export interface XyoStakeIntentServiceParams extends BaseServiceParams {
|
|
|
17
17
|
export declare class XyoStakeIntentService extends BaseService<XyoStakeIntentServiceParams> implements StakeIntentService {
|
|
18
18
|
protected _lastIndexedBlockHash: Hash | undefined;
|
|
19
19
|
protected _producers: IntervalMap<Address>;
|
|
20
|
-
protected _stakeCache: LRUCache<
|
|
20
|
+
protected _stakeCache: LRUCache<import("@xylabs/typeof").Brand<import("@xylabs/typeof").Brand<Lowercase<string>, {
|
|
21
|
+
readonly __hex: true;
|
|
22
|
+
}>, {
|
|
23
|
+
readonly __address: true;
|
|
24
|
+
}>, bigint, unknown>;
|
|
21
25
|
protected _updateMutex: Mutex;
|
|
22
26
|
protected get chainArchivist(): ArchivistInstance<import("@xyo-network/archivist-model").ArchivistParams<import("@xyo-network/module-model").AnyConfigSchema<import("@xyo-network/archivist-model").ArchivistConfig>>, import("@xyo-network/archivist-model").ArchivistModuleEventData, Payload>;
|
|
23
27
|
protected get chainIterator(): EventingChainBlockNumberIteratorService;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"XyoStakeIntentService.d.ts","sourceRoot":"","sources":["../../../src/StakeIntent/XyoStakeIntentService.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,OAAO,EAAa,IAAI,EACzB,MAAM,aAAa,CAAA;AAEpB,OAAO,EAAE,iBAAiB,EAAwB,MAAM,8BAA8B,CAAA;AAKtF,OAAO,EAEc,WAAW,EAE/B,MAAM,0BAA0B,CAAA;AAEjC,OAAO,EAAE,OAAO,EAAmB,MAAM,4BAA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