@aztec/archiver 0.0.0-test.1 → 0.0.1-commit.0208eb9

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.
Files changed (225) hide show
  1. package/README.md +164 -9
  2. package/dest/archiver.d.ts +136 -0
  3. package/dest/archiver.d.ts.map +1 -0
  4. package/dest/archiver.js +781 -0
  5. package/dest/config.d.ts +30 -0
  6. package/dest/config.d.ts.map +1 -0
  7. package/dest/config.js +71 -0
  8. package/dest/errors.d.ts +41 -0
  9. package/dest/errors.d.ts.map +1 -0
  10. package/dest/errors.js +62 -0
  11. package/dest/factory.d.ts +13 -16
  12. package/dest/factory.d.ts.map +1 -1
  13. package/dest/factory.js +103 -55
  14. package/dest/index.d.ts +10 -4
  15. package/dest/index.d.ts.map +1 -1
  16. package/dest/index.js +8 -3
  17. package/dest/interfaces.d.ts +9 -0
  18. package/dest/interfaces.d.ts.map +1 -0
  19. package/dest/interfaces.js +3 -0
  20. package/dest/l1/bin/retrieve-calldata.d.ts +3 -0
  21. package/dest/l1/bin/retrieve-calldata.d.ts.map +1 -0
  22. package/dest/l1/bin/retrieve-calldata.js +149 -0
  23. package/dest/l1/calldata_retriever.d.ts +112 -0
  24. package/dest/l1/calldata_retriever.d.ts.map +1 -0
  25. package/dest/l1/calldata_retriever.js +471 -0
  26. package/dest/l1/data_retrieval.d.ts +88 -0
  27. package/dest/l1/data_retrieval.d.ts.map +1 -0
  28. package/dest/l1/data_retrieval.js +312 -0
  29. package/dest/l1/debug_tx.d.ts +19 -0
  30. package/dest/l1/debug_tx.d.ts.map +1 -0
  31. package/dest/l1/debug_tx.js +73 -0
  32. package/dest/l1/spire_proposer.d.ts +70 -0
  33. package/dest/l1/spire_proposer.d.ts.map +1 -0
  34. package/dest/l1/spire_proposer.js +157 -0
  35. package/dest/l1/trace_tx.d.ts +97 -0
  36. package/dest/l1/trace_tx.d.ts.map +1 -0
  37. package/dest/l1/trace_tx.js +91 -0
  38. package/dest/l1/types.d.ts +12 -0
  39. package/dest/l1/types.d.ts.map +1 -0
  40. package/dest/l1/types.js +3 -0
  41. package/dest/l1/validate_trace.d.ts +32 -0
  42. package/dest/l1/validate_trace.d.ts.map +1 -0
  43. package/dest/l1/validate_trace.js +154 -0
  44. package/dest/modules/data_source_base.d.ts +84 -0
  45. package/dest/modules/data_source_base.d.ts.map +1 -0
  46. package/dest/modules/data_source_base.js +260 -0
  47. package/dest/modules/data_store_updater.d.ts +73 -0
  48. package/dest/modules/data_store_updater.d.ts.map +1 -0
  49. package/dest/modules/data_store_updater.js +302 -0
  50. package/dest/modules/instrumentation.d.ts +37 -0
  51. package/dest/modules/instrumentation.d.ts.map +1 -0
  52. package/dest/modules/instrumentation.js +110 -0
  53. package/dest/modules/l1_synchronizer.d.ts +75 -0
  54. package/dest/modules/l1_synchronizer.d.ts.map +1 -0
  55. package/dest/modules/l1_synchronizer.js +1112 -0
  56. package/dest/modules/validation.d.ts +17 -0
  57. package/dest/modules/validation.d.ts.map +1 -0
  58. package/dest/modules/validation.js +104 -0
  59. package/dest/store/block_store.d.ts +192 -0
  60. package/dest/store/block_store.d.ts.map +1 -0
  61. package/dest/store/block_store.js +721 -0
  62. package/dest/store/contract_class_store.d.ts +18 -0
  63. package/dest/store/contract_class_store.d.ts.map +1 -0
  64. package/dest/{archiver/kv_archiver_store → store}/contract_class_store.js +25 -27
  65. package/dest/store/contract_instance_store.d.ts +24 -0
  66. package/dest/store/contract_instance_store.d.ts.map +1 -0
  67. package/dest/store/contract_instance_store.js +77 -0
  68. package/dest/store/kv_archiver_store.d.ts +340 -0
  69. package/dest/store/kv_archiver_store.d.ts.map +1 -0
  70. package/dest/store/kv_archiver_store.js +446 -0
  71. package/dest/store/log_store.d.ts +54 -0
  72. package/dest/store/log_store.d.ts.map +1 -0
  73. package/dest/store/log_store.js +436 -0
  74. package/dest/store/message_store.d.ts +40 -0
  75. package/dest/store/message_store.d.ts.map +1 -0
  76. package/dest/store/message_store.js +188 -0
  77. package/dest/structs/data_retrieval.d.ts +27 -0
  78. package/dest/structs/data_retrieval.d.ts.map +1 -0
  79. package/dest/structs/inbox_message.d.ts +15 -0
  80. package/dest/structs/inbox_message.d.ts.map +1 -0
  81. package/dest/structs/inbox_message.js +39 -0
  82. package/dest/structs/published.d.ts +2 -0
  83. package/dest/structs/published.d.ts.map +1 -0
  84. package/dest/structs/published.js +1 -0
  85. package/dest/test/fake_l1_state.d.ts +190 -0
  86. package/dest/test/fake_l1_state.d.ts.map +1 -0
  87. package/dest/test/fake_l1_state.js +383 -0
  88. package/dest/test/index.d.ts +2 -1
  89. package/dest/test/index.d.ts.map +1 -1
  90. package/dest/test/index.js +4 -1
  91. package/dest/test/mock_archiver.d.ts +16 -8
  92. package/dest/test/mock_archiver.d.ts.map +1 -1
  93. package/dest/test/mock_archiver.js +18 -14
  94. package/dest/test/mock_l1_to_l2_message_source.d.ts +9 -6
  95. package/dest/test/mock_l1_to_l2_message_source.d.ts.map +1 -1
  96. package/dest/test/mock_l1_to_l2_message_source.js +30 -7
  97. package/dest/test/mock_l2_block_source.d.ts +62 -16
  98. package/dest/test/mock_l2_block_source.d.ts.map +1 -1
  99. package/dest/test/mock_l2_block_source.js +263 -32
  100. package/dest/test/mock_structs.d.ts +85 -0
  101. package/dest/test/mock_structs.d.ts.map +1 -0
  102. package/dest/test/mock_structs.js +171 -0
  103. package/dest/test/noop_l1_archiver.d.ts +23 -0
  104. package/dest/test/noop_l1_archiver.d.ts.map +1 -0
  105. package/dest/test/noop_l1_archiver.js +68 -0
  106. package/package.json +31 -33
  107. package/src/archiver.ts +543 -0
  108. package/src/config.ts +95 -0
  109. package/src/errors.ts +102 -0
  110. package/src/factory.ts +144 -71
  111. package/src/index.ts +10 -3
  112. package/src/interfaces.ts +9 -0
  113. package/src/l1/README.md +98 -0
  114. package/src/l1/bin/retrieve-calldata.ts +187 -0
  115. package/src/l1/calldata_retriever.ts +641 -0
  116. package/src/l1/data_retrieval.ts +495 -0
  117. package/src/l1/debug_tx.ts +99 -0
  118. package/src/l1/spire_proposer.ts +160 -0
  119. package/src/l1/trace_tx.ts +128 -0
  120. package/src/l1/types.ts +13 -0
  121. package/src/l1/validate_trace.ts +229 -0
  122. package/src/modules/data_source_base.ts +367 -0
  123. package/src/modules/data_store_updater.ts +423 -0
  124. package/src/modules/instrumentation.ts +157 -0
  125. package/src/modules/l1_synchronizer.ts +930 -0
  126. package/src/modules/validation.ts +129 -0
  127. package/src/store/block_store.ts +966 -0
  128. package/src/{archiver/kv_archiver_store → store}/contract_class_store.ts +26 -32
  129. package/src/{archiver/kv_archiver_store → store}/contract_instance_store.ts +37 -29
  130. package/src/store/kv_archiver_store.ts +639 -0
  131. package/src/store/log_store.ts +575 -0
  132. package/src/store/message_store.ts +261 -0
  133. package/src/structs/inbox_message.ts +41 -0
  134. package/src/structs/published.ts +1 -0
  135. package/src/test/fake_l1_state.ts +599 -0
  136. package/src/test/fixtures/debug_traceTransaction-multicall3.json +88 -0
  137. package/src/test/fixtures/debug_traceTransaction-multiplePropose.json +153 -0
  138. package/src/test/fixtures/debug_traceTransaction-proxied.json +122 -0
  139. package/src/test/fixtures/trace_transaction-multicall3.json +65 -0
  140. package/src/test/fixtures/trace_transaction-multiplePropose.json +319 -0
  141. package/src/test/fixtures/trace_transaction-proxied.json +128 -0
  142. package/src/test/fixtures/trace_transaction-randomRevert.json +216 -0
  143. package/src/test/index.ts +4 -0
  144. package/src/test/mock_archiver.ts +22 -16
  145. package/src/test/mock_l1_to_l2_message_source.ts +26 -8
  146. package/src/test/mock_l2_block_source.ts +313 -42
  147. package/src/test/mock_structs.ts +311 -0
  148. package/src/test/noop_l1_archiver.ts +109 -0
  149. package/dest/archiver/archiver.d.ts +0 -197
  150. package/dest/archiver/archiver.d.ts.map +0 -1
  151. package/dest/archiver/archiver.js +0 -900
  152. package/dest/archiver/archiver_store.d.ts +0 -220
  153. package/dest/archiver/archiver_store.d.ts.map +0 -1
  154. package/dest/archiver/archiver_store.js +0 -4
  155. package/dest/archiver/archiver_store_test_suite.d.ts +0 -8
  156. package/dest/archiver/archiver_store_test_suite.d.ts.map +0 -1
  157. package/dest/archiver/archiver_store_test_suite.js +0 -794
  158. package/dest/archiver/config.d.ts +0 -37
  159. package/dest/archiver/config.d.ts.map +0 -1
  160. package/dest/archiver/config.js +0 -46
  161. package/dest/archiver/data_retrieval.d.ts +0 -74
  162. package/dest/archiver/data_retrieval.d.ts.map +0 -1
  163. package/dest/archiver/data_retrieval.js +0 -283
  164. package/dest/archiver/errors.d.ts +0 -4
  165. package/dest/archiver/errors.d.ts.map +0 -1
  166. package/dest/archiver/errors.js +0 -5
  167. package/dest/archiver/index.d.ts +0 -8
  168. package/dest/archiver/index.d.ts.map +0 -1
  169. package/dest/archiver/index.js +0 -5
  170. package/dest/archiver/instrumentation.d.ts +0 -29
  171. package/dest/archiver/instrumentation.d.ts.map +0 -1
  172. package/dest/archiver/instrumentation.js +0 -99
  173. package/dest/archiver/kv_archiver_store/block_store.d.ts +0 -87
  174. package/dest/archiver/kv_archiver_store/block_store.d.ts.map +0 -1
  175. package/dest/archiver/kv_archiver_store/block_store.js +0 -217
  176. package/dest/archiver/kv_archiver_store/contract_class_store.d.ts +0 -18
  177. package/dest/archiver/kv_archiver_store/contract_class_store.d.ts.map +0 -1
  178. package/dest/archiver/kv_archiver_store/contract_instance_store.d.ts +0 -21
  179. package/dest/archiver/kv_archiver_store/contract_instance_store.d.ts.map +0 -1
  180. package/dest/archiver/kv_archiver_store/contract_instance_store.js +0 -63
  181. package/dest/archiver/kv_archiver_store/kv_archiver_store.d.ts +0 -153
  182. package/dest/archiver/kv_archiver_store/kv_archiver_store.d.ts.map +0 -1
  183. package/dest/archiver/kv_archiver_store/kv_archiver_store.js +0 -254
  184. package/dest/archiver/kv_archiver_store/log_store.d.ts +0 -49
  185. package/dest/archiver/kv_archiver_store/log_store.d.ts.map +0 -1
  186. package/dest/archiver/kv_archiver_store/log_store.js +0 -364
  187. package/dest/archiver/kv_archiver_store/message_store.d.ts +0 -33
  188. package/dest/archiver/kv_archiver_store/message_store.d.ts.map +0 -1
  189. package/dest/archiver/kv_archiver_store/message_store.js +0 -85
  190. package/dest/archiver/kv_archiver_store/nullifier_store.d.ts +0 -12
  191. package/dest/archiver/kv_archiver_store/nullifier_store.d.ts.map +0 -1
  192. package/dest/archiver/kv_archiver_store/nullifier_store.js +0 -73
  193. package/dest/archiver/memory_archiver_store/l1_to_l2_message_store.d.ts +0 -23
  194. package/dest/archiver/memory_archiver_store/l1_to_l2_message_store.d.ts.map +0 -1
  195. package/dest/archiver/memory_archiver_store/l1_to_l2_message_store.js +0 -49
  196. package/dest/archiver/memory_archiver_store/memory_archiver_store.d.ts +0 -175
  197. package/dest/archiver/memory_archiver_store/memory_archiver_store.d.ts.map +0 -1
  198. package/dest/archiver/memory_archiver_store/memory_archiver_store.js +0 -636
  199. package/dest/archiver/structs/data_retrieval.d.ts +0 -27
  200. package/dest/archiver/structs/data_retrieval.d.ts.map +0 -1
  201. package/dest/archiver/structs/published.d.ts +0 -11
  202. package/dest/archiver/structs/published.d.ts.map +0 -1
  203. package/dest/archiver/structs/published.js +0 -1
  204. package/dest/rpc/index.d.ts +0 -10
  205. package/dest/rpc/index.d.ts.map +0 -1
  206. package/dest/rpc/index.js +0 -18
  207. package/src/archiver/archiver.ts +0 -1181
  208. package/src/archiver/archiver_store.ts +0 -263
  209. package/src/archiver/archiver_store_test_suite.ts +0 -810
  210. package/src/archiver/config.ts +0 -92
  211. package/src/archiver/data_retrieval.ts +0 -422
  212. package/src/archiver/errors.ts +0 -5
  213. package/src/archiver/index.ts +0 -7
  214. package/src/archiver/instrumentation.ts +0 -132
  215. package/src/archiver/kv_archiver_store/block_store.ts +0 -283
  216. package/src/archiver/kv_archiver_store/kv_archiver_store.ts +0 -358
  217. package/src/archiver/kv_archiver_store/log_store.ts +0 -444
  218. package/src/archiver/kv_archiver_store/message_store.ts +0 -102
  219. package/src/archiver/kv_archiver_store/nullifier_store.ts +0 -97
  220. package/src/archiver/memory_archiver_store/l1_to_l2_message_store.ts +0 -61
  221. package/src/archiver/memory_archiver_store/memory_archiver_store.ts +0 -801
  222. package/src/archiver/structs/published.ts +0 -11
  223. package/src/rpc/index.ts +0 -20
  224. /package/dest/{archiver/structs → structs}/data_retrieval.js +0 -0
  225. /package/src/{archiver/structs → structs}/data_retrieval.ts +0 -0
@@ -1,220 +0,0 @@
1
- import type { Fr } from '@aztec/foundation/fields';
2
- import type { FunctionSelector } from '@aztec/stdlib/abi';
3
- import type { AztecAddress } from '@aztec/stdlib/aztec-address';
4
- import type { InBlock, L2Block } from '@aztec/stdlib/block';
5
- import type { ContractClassPublic, ContractInstanceUpdateWithAddress, ContractInstanceWithAddress, ExecutablePrivateFunctionWithMembershipProof, UnconstrainedFunctionWithMembershipProof } from '@aztec/stdlib/contract';
6
- import type { GetContractClassLogsResponse, GetPublicLogsResponse } from '@aztec/stdlib/interfaces/client';
7
- import type { LogFilter, PrivateLog, TxScopedL2Log } from '@aztec/stdlib/logs';
8
- import type { InboxLeaf } from '@aztec/stdlib/messaging';
9
- import { BlockHeader, type TxEffect, type TxHash, type TxReceipt } from '@aztec/stdlib/tx';
10
- import type { DataRetrieval } from './structs/data_retrieval.js';
11
- import type { L1Published } from './structs/published.js';
12
- /**
13
- * Represents the latest L1 block processed by the archiver for various objects in L2.
14
- */
15
- export type ArchiverL1SynchPoint = {
16
- /** Number of the last L1 block that added a new L2 block metadata. */
17
- blocksSynchedTo?: bigint;
18
- /** Number of the last L1 block that added L1 -> L2 messages from the Inbox. */
19
- messagesSynchedTo?: bigint;
20
- /** Number of the last L1 block that added a new proven block. */
21
- provenLogsSynchedTo?: bigint;
22
- };
23
- /**
24
- * Interface describing a data store to be used by the archiver to store all its relevant data
25
- * (blocks, encrypted logs, aztec contract data extended contract data).
26
- */
27
- export interface ArchiverDataStore {
28
- /**
29
- * Append new blocks to the store's list.
30
- * @param blocks - The L2 blocks to be added to the store and the last processed L1 block.
31
- * @returns True if the operation is successful.
32
- */
33
- addBlocks(blocks: L1Published<L2Block>[]): Promise<boolean>;
34
- /**
35
- * Unwinds blocks from the database
36
- * @param from - The tip of the chain, passed for verification purposes,
37
- * ensuring that we don't end up deleting something we did not intend
38
- * @param blocksToUnwind - The number of blocks we are to unwind
39
- * @returns True if the operation is successful
40
- */
41
- unwindBlocks(from: number, blocksToUnwind: number): Promise<boolean>;
42
- /**
43
- * Gets up to `limit` amount of L2 blocks starting from `from`.
44
- * @param from - Number of the first block to return (inclusive).
45
- * @param limit - The number of blocks to return.
46
- * @returns The requested L2 blocks.
47
- */
48
- getBlocks(from: number, limit: number): Promise<L1Published<L2Block>[]>;
49
- /**
50
- * Gets up to `limit` amount of L2 block headers starting from `from`.
51
- * @param from - Number of the first block to return (inclusive).
52
- * @param limit - The number of blocks to return.
53
- * @returns The requested L2 block headers.
54
- */
55
- getBlockHeaders(from: number, limit: number): Promise<BlockHeader[]>;
56
- /**
57
- * Gets a tx effect.
58
- * @param txHash - The txHash of the tx corresponding to the tx effect.
59
- * @returns The requested tx effect (or undefined if not found).
60
- */
61
- getTxEffect(txHash: TxHash): Promise<InBlock<TxEffect> | undefined>;
62
- /**
63
- * Gets a receipt of a settled tx.
64
- * @param txHash - The hash of a tx we try to get the receipt for.
65
- * @returns The requested tx receipt (or undefined if not found).
66
- */
67
- getSettledTxReceipt(txHash: TxHash): Promise<TxReceipt | undefined>;
68
- /**
69
- * Append new logs to the store's list.
70
- * @param blocks - The blocks for which to add the logs.
71
- * @returns True if the operation is successful.
72
- */
73
- addLogs(blocks: L2Block[]): Promise<boolean>;
74
- deleteLogs(blocks: L2Block[]): Promise<boolean>;
75
- /**
76
- * Append new nullifiers to the store's list.
77
- * @param blocks - The blocks for which to add the nullifiers.
78
- * @returns True if the operation is successful.
79
- */
80
- addNullifiers(blocks: L2Block[]): Promise<boolean>;
81
- deleteNullifiers(blocks: L2Block[]): Promise<boolean>;
82
- /**
83
- * Returns the provided nullifier indexes scoped to the block
84
- * they were first included in, or undefined if they're not present in the tree
85
- * @param blockNumber Max block number to search for the nullifiers
86
- * @param nullifiers Nullifiers to get
87
- * @returns The block scoped indexes of the provided nullifiers, or undefined if the nullifier doesn't exist in the tree
88
- */
89
- findNullifiersIndexesWithBlock(blockNumber: number, nullifiers: Fr[]): Promise<(InBlock<bigint> | undefined)[]>;
90
- /**
91
- * Append L1 to L2 messages to the store.
92
- * @param messages - The L1 to L2 messages to be added to the store and the last processed L1 block.
93
- * @returns True if the operation is successful.
94
- */
95
- addL1ToL2Messages(messages: DataRetrieval<InboxLeaf>): Promise<boolean>;
96
- /**
97
- * Gets L1 to L2 message (to be) included in a given block.
98
- * @param blockNumber - L2 block number to get messages for.
99
- * @returns The L1 to L2 messages/leaves of the messages subtree (throws if not found).
100
- */
101
- getL1ToL2Messages(blockNumber: bigint): Promise<Fr[]>;
102
- /**
103
- * Gets the L1 to L2 message index in the L1 to L2 message tree.
104
- * @param l1ToL2Message - The L1 to L2 message.
105
- * @returns The index of the L1 to L2 message in the L1 to L2 message tree (undefined if not found).
106
- */
107
- getL1ToL2MessageIndex(l1ToL2Message: Fr): Promise<bigint | undefined>;
108
- /**
109
- * Get the total number of L1 to L2 messages
110
- * @returns The number of L1 to L2 messages in the store
111
- */
112
- getTotalL1ToL2MessageCount(): Promise<bigint>;
113
- /**
114
- * Retrieves all private logs from up to `limit` blocks, starting from the block number `from`.
115
- * @param from - The block number from which to begin retrieving logs.
116
- * @param limit - The maximum number of blocks to retrieve logs from.
117
- * @returns An array of private logs from the specified range of blocks.
118
- */
119
- getPrivateLogs(from: number, limit: number): Promise<PrivateLog[]>;
120
- /**
121
- * Gets all logs that match any of the received tags (i.e. logs with their first field equal to a tag).
122
- * @param tags - The tags to filter the logs by.
123
- * @returns For each received tag, an array of matching logs is returned. An empty array implies no logs match
124
- * that tag.
125
- */
126
- getLogsByTags(tags: Fr[]): Promise<TxScopedL2Log[][]>;
127
- /**
128
- * Gets public logs based on the provided filter.
129
- * @param filter - The filter to apply to the logs.
130
- * @returns The requested logs.
131
- */
132
- getPublicLogs(filter: LogFilter): Promise<GetPublicLogsResponse>;
133
- /**
134
- * Gets contract class logs based on the provided filter.
135
- * @param filter - The filter to apply to the logs.
136
- * @returns The requested logs.
137
- */
138
- getContractClassLogs(filter: LogFilter): Promise<GetContractClassLogsResponse>;
139
- /**
140
- * Gets the number of the latest L2 block processed.
141
- * @returns The number of the latest L2 block processed.
142
- */
143
- getSynchedL2BlockNumber(): Promise<number>;
144
- /**
145
- * Gets the number of the latest proven L2 block processed.
146
- * @returns The number of the latest proven L2 block processed.
147
- */
148
- getProvenL2BlockNumber(): Promise<number>;
149
- /**
150
- * Stores the number of the latest proven L2 block processed.
151
- * @param l2BlockNumber - The number of the latest proven L2 block processed.
152
- */
153
- setProvenL2BlockNumber(l2BlockNumber: number): Promise<void>;
154
- /**
155
- * Stores the l1 block number that blocks have been synched until
156
- * @param l1BlockNumber - The l1 block number
157
- */
158
- setBlockSynchedL1BlockNumber(l1BlockNumber: bigint): Promise<void>;
159
- /**
160
- * Stores the l1 block number that messages have been synched until
161
- * @param l1BlockNumber - The l1 block number
162
- */
163
- setMessageSynchedL1BlockNumber(l1BlockNumber: bigint): Promise<void>;
164
- /**
165
- * Gets the synch point of the archiver
166
- */
167
- getSynchPoint(): Promise<ArchiverL1SynchPoint>;
168
- /**
169
- * Add new contract classes from an L2 block to the store's list.
170
- * @param data - List of contract classes to be added.
171
- * @param blockNumber - Number of the L2 block the contracts were registered in.
172
- * @returns True if the operation is successful.
173
- */
174
- addContractClasses(data: ContractClassPublic[], bytecodeCommitments: Fr[], blockNumber: number): Promise<boolean>;
175
- deleteContractClasses(data: ContractClassPublic[], blockNumber: number): Promise<boolean>;
176
- getBytecodeCommitment(contractClassId: Fr): Promise<Fr | undefined>;
177
- /**
178
- * Returns a contract class given its id, or undefined if not exists.
179
- * @param id - Id of the contract class.
180
- */
181
- getContractClass(id: Fr): Promise<ContractClassPublic | undefined>;
182
- /**
183
- * Add new contract instances from an L2 block to the store's list.
184
- * @param data - List of contract instances to be added.
185
- * @param blockNumber - Number of the L2 block the instances were deployed in.
186
- * @returns True if the operation is successful.
187
- */
188
- addContractInstances(data: ContractInstanceWithAddress[], blockNumber: number): Promise<boolean>;
189
- deleteContractInstances(data: ContractInstanceWithAddress[], blockNumber: number): Promise<boolean>;
190
- /**
191
- * Add new contract instance updates
192
- * @param data - List of contract updates to be added.
193
- * @param blockNumber - Number of the L2 block the updates were scheduled in.
194
- * @returns True if the operation is successful.
195
- */
196
- addContractInstanceUpdates(data: ContractInstanceUpdateWithAddress[], blockNumber: number): Promise<boolean>;
197
- deleteContractInstanceUpdates(data: ContractInstanceUpdateWithAddress[], blockNumber: number): Promise<boolean>;
198
- /**
199
- * Adds private functions to a contract class.
200
- */
201
- addFunctions(contractClassId: Fr, privateFunctions: ExecutablePrivateFunctionWithMembershipProof[], unconstrainedFunctions: UnconstrainedFunctionWithMembershipProof[]): Promise<boolean>;
202
- /**
203
- * Returns a contract instance given its address and the given block number, or undefined if not exists.
204
- * @param address - Address of the contract.
205
- */
206
- getContractInstance(address: AztecAddress): Promise<ContractInstanceWithAddress | undefined>;
207
- /** Returns the list of all class ids known by the archiver. */
208
- getContractClassIds(): Promise<Fr[]>;
209
- registerContractFunctionSignatures(address: AztecAddress, signatures: string[]): Promise<void>;
210
- getContractFunctionName(address: AztecAddress, selector: FunctionSelector): Promise<string | undefined>;
211
- /**
212
- * Estimates the size of the store in bytes.
213
- */
214
- estimateSize(): Promise<{
215
- mappingSize: number;
216
- actualSize: number;
217
- numItems: number;
218
- }>;
219
- }
220
- //# sourceMappingURL=archiver_store.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"archiver_store.d.ts","sourceRoot":"","sources":["../../src/archiver/archiver_store.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,0BAA0B,CAAC;AACnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,KAA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U,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACxF"}
@@ -1,4 +0,0 @@
1
- /**
2
- * Interface describing a data store to be used by the archiver to store all its relevant data
3
- * (blocks, encrypted logs, aztec contract data extended contract data).
4
- */ export { };
@@ -1,8 +0,0 @@
1
- import '@aztec/stdlib/testing/jest';
2
- import type { ArchiverDataStore } from './archiver_store.js';
3
- /**
4
- * @param testName - The name of the test suite.
5
- * @param getStore - Returns an instance of a store that's already been initialized.
6
- */
7
- export declare function describeArchiverDataStore(testName: string, getStore: () => ArchiverDataStore | Promise<ArchiverDataStore>): void;
8
- //# sourceMappingURL=archiver_store_test_suite.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"archiver_store_test_suite.d.ts","sourceRoot":"","sources":["../../src/archiver/archiver_store_test_suite.ts"],"names":[],"mappings":"AAyBA,OAAO,4BAA4B,CAAC;AAGpC,OAAO,KAAK,EAAE,iBAAiB,EAAwB,MAAM,qBAAqB,CAAC;AAGnF;;;GAGG;AACH,wBAAgB,yBAAyB,CACvC,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,MAAM,iBAAiB,GAAG,OAAO,CAAC,iBAAiB,CAAC,QAowB/D"}