@aztec/txe 0.0.1-commit.023c3e5 → 0.0.1-commit.08c5969dc
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/dest/oracle/txe_oracle_top_level_context.d.ts +2 -2
- package/dest/oracle/txe_oracle_top_level_context.d.ts.map +1 -1
- package/dest/oracle/txe_oracle_top_level_context.js +79 -20
- package/dest/rpc_translator.d.ts +4 -4
- package/dest/rpc_translator.d.ts.map +1 -1
- package/dest/rpc_translator.js +22 -10
- package/dest/state_machine/archiver.d.ts +1 -1
- package/dest/state_machine/archiver.d.ts.map +1 -1
- package/dest/state_machine/archiver.js +2 -0
- package/dest/state_machine/dummy_p2p_client.d.ts +11 -8
- package/dest/state_machine/dummy_p2p_client.d.ts.map +1 -1
- package/dest/state_machine/dummy_p2p_client.js +21 -12
- package/dest/state_machine/index.d.ts +5 -5
- package/dest/state_machine/index.d.ts.map +1 -1
- package/dest/state_machine/index.js +14 -9
- package/dest/state_machine/mock_epoch_cache.d.ts +3 -1
- package/dest/state_machine/mock_epoch_cache.d.ts.map +1 -1
- package/dest/state_machine/mock_epoch_cache.js +4 -0
- package/dest/txe_session.d.ts +1 -1
- package/dest/txe_session.d.ts.map +1 -1
- package/dest/txe_session.js +63 -6
- package/dest/utils/block_creation.d.ts +1 -1
- package/dest/utils/block_creation.d.ts.map +1 -1
- package/dest/utils/block_creation.js +3 -1
- package/package.json +15 -15
- package/src/oracle/txe_oracle_top_level_context.ts +81 -66
- package/src/rpc_translator.ts +16 -5
- package/src/state_machine/archiver.ts +2 -0
- package/src/state_machine/dummy_p2p_client.ts +29 -15
- package/src/state_machine/index.ts +24 -9
- package/src/state_machine/mock_epoch_cache.ts +5 -0
- package/src/txe_session.ts +58 -52
- package/src/utils/block_creation.ts +3 -1
|
@@ -6,6 +6,8 @@ import type {
|
|
|
6
6
|
P2PBlockReceivedCallback,
|
|
7
7
|
P2PCheckpointReceivedCallback,
|
|
8
8
|
P2PConfig,
|
|
9
|
+
P2PDuplicateAttestationCallback,
|
|
10
|
+
P2PDuplicateProposalCallback,
|
|
9
11
|
P2PSyncState,
|
|
10
12
|
PeerId,
|
|
11
13
|
ReqRespSubProtocol,
|
|
@@ -16,7 +18,7 @@ import type {
|
|
|
16
18
|
import type { EthAddress, L2BlockStreamEvent, L2Tips } from '@aztec/stdlib/block';
|
|
17
19
|
import type { PeerInfo } from '@aztec/stdlib/interfaces/server';
|
|
18
20
|
import type { BlockProposal, CheckpointAttestation, CheckpointProposal } from '@aztec/stdlib/p2p';
|
|
19
|
-
import type { Tx, TxHash } from '@aztec/stdlib/tx';
|
|
21
|
+
import type { BlockHeader, Tx, TxHash } from '@aztec/stdlib/tx';
|
|
20
22
|
|
|
21
23
|
export class DummyP2P implements P2P {
|
|
22
24
|
public validate(_txs: Tx[]): Promise<void> {
|
|
@@ -71,8 +73,8 @@ export class DummyP2P implements P2P {
|
|
|
71
73
|
throw new Error('DummyP2P does not implement "sendTx"');
|
|
72
74
|
}
|
|
73
75
|
|
|
74
|
-
public
|
|
75
|
-
throw new Error('DummyP2P does not implement "
|
|
76
|
+
public handleFailedExecution(_txHashes: TxHash[]): Promise<void> {
|
|
77
|
+
throw new Error('DummyP2P does not implement "handleFailedExecution"');
|
|
76
78
|
}
|
|
77
79
|
|
|
78
80
|
public getTxByHashFromPool(_txHash: TxHash): Promise<Tx | undefined> {
|
|
@@ -97,6 +99,10 @@ export class DummyP2P implements P2P {
|
|
|
97
99
|
throw new Error('DummyP2P does not implement "iteratePendingTxs"');
|
|
98
100
|
}
|
|
99
101
|
|
|
102
|
+
public iterateEligiblePendingTxs(): AsyncIterableIterator<Tx> {
|
|
103
|
+
throw new Error('DummyP2P does not implement "iterateEligiblePendingTxs"');
|
|
104
|
+
}
|
|
105
|
+
|
|
100
106
|
public getPendingTxCount(): Promise<number> {
|
|
101
107
|
throw new Error('DummyP2P does not implement "getPendingTxCount"');
|
|
102
108
|
}
|
|
@@ -133,8 +139,8 @@ export class DummyP2P implements P2P {
|
|
|
133
139
|
throw new Error('DummyP2P does not implement "getCheckpointAttestationsForSlot"');
|
|
134
140
|
}
|
|
135
141
|
|
|
136
|
-
public
|
|
137
|
-
throw new Error('DummyP2P does not implement "
|
|
142
|
+
public addOwnCheckpointAttestations(_attestations: CheckpointAttestation[]): Promise<void> {
|
|
143
|
+
throw new Error('DummyP2P does not implement "addOwnCheckpointAttestations"');
|
|
138
144
|
}
|
|
139
145
|
|
|
140
146
|
public getL2BlockHash(_number: number): Promise<string | undefined> {
|
|
@@ -157,14 +163,6 @@ export class DummyP2P implements P2P {
|
|
|
157
163
|
throw new Error('DummyP2P does not implement "sync"');
|
|
158
164
|
}
|
|
159
165
|
|
|
160
|
-
public requestTxsByHash(_txHashes: TxHash[]): Promise<Tx[]> {
|
|
161
|
-
throw new Error('DummyP2P does not implement "requestTxsByHash"');
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
public getTxs(_filter: 'all' | 'pending' | 'mined'): Promise<Tx[]> {
|
|
165
|
-
throw new Error('DummyP2P does not implement "getTxs"');
|
|
166
|
-
}
|
|
167
|
-
|
|
168
166
|
public getTxsByHashFromPool(_txHashes: TxHash[]): Promise<(Tx | undefined)[]> {
|
|
169
167
|
throw new Error('DummyP2P does not implement "getTxsByHashFromPool"');
|
|
170
168
|
}
|
|
@@ -189,8 +187,12 @@ export class DummyP2P implements P2P {
|
|
|
189
187
|
throw new Error('DummyP2P does not implement "getSyncedLatestSlot"');
|
|
190
188
|
}
|
|
191
189
|
|
|
192
|
-
|
|
193
|
-
throw new Error('DummyP2P does not implement "
|
|
190
|
+
protectTxs(_txHashes: TxHash[], _blockHeader: BlockHeader): Promise<TxHash[]> {
|
|
191
|
+
throw new Error('DummyP2P does not implement "protectTxs".');
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
prepareForSlot(_slotNumber: SlotNumber): Promise<void> {
|
|
195
|
+
return Promise.resolve();
|
|
194
196
|
}
|
|
195
197
|
|
|
196
198
|
addReqRespSubProtocol(
|
|
@@ -206,4 +208,16 @@ export class DummyP2P implements P2P {
|
|
|
206
208
|
|
|
207
209
|
//This is no-op
|
|
208
210
|
public registerThisValidatorAddresses(_address: EthAddress[]): void {}
|
|
211
|
+
|
|
212
|
+
public registerDuplicateProposalCallback(_callback: P2PDuplicateProposalCallback): void {
|
|
213
|
+
throw new Error('DummyP2P does not implement "registerDuplicateProposalCallback"');
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
public registerDuplicateAttestationCallback(_callback: P2PDuplicateAttestationCallback): void {
|
|
217
|
+
throw new Error('DummyP2P does not implement "registerDuplicateAttestationCallback"');
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
public hasBlockProposalsForSlot(_slot: SlotNumber): Promise<boolean> {
|
|
221
|
+
throw new Error('DummyP2P does not implement "hasBlockProposalsForSlot"');
|
|
222
|
+
}
|
|
209
223
|
}
|
|
@@ -3,8 +3,7 @@ import { TestCircuitVerifier } from '@aztec/bb-prover/test';
|
|
|
3
3
|
import { CheckpointNumber } from '@aztec/foundation/branded-types';
|
|
4
4
|
import { Fr } from '@aztec/foundation/curves/bn254';
|
|
5
5
|
import { createLogger } from '@aztec/foundation/log';
|
|
6
|
-
import type
|
|
7
|
-
import { AnchorBlockStore } from '@aztec/pxe/server';
|
|
6
|
+
import { type AnchorBlockStore, type ContractStore, ContractSyncService, type NoteStore } from '@aztec/pxe/server';
|
|
8
7
|
import { L2Block } from '@aztec/stdlib/block';
|
|
9
8
|
import { Checkpoint, L1PublishedData, PublishedCheckpoint } from '@aztec/stdlib/checkpoint';
|
|
10
9
|
import type { AztecNode } from '@aztec/stdlib/interfaces/client';
|
|
@@ -26,13 +25,16 @@ export class TXEStateMachine {
|
|
|
26
25
|
public synchronizer: TXESynchronizer,
|
|
27
26
|
public archiver: TXEArchiver,
|
|
28
27
|
public anchorBlockStore: AnchorBlockStore,
|
|
28
|
+
public contractSyncService: ContractSyncService,
|
|
29
29
|
) {}
|
|
30
30
|
|
|
31
|
-
public static async create(
|
|
32
|
-
|
|
31
|
+
public static async create(
|
|
32
|
+
archiver: TXEArchiver,
|
|
33
|
+
anchorBlockStore: AnchorBlockStore,
|
|
34
|
+
contractStore: ContractStore,
|
|
35
|
+
noteStore: NoteStore,
|
|
36
|
+
) {
|
|
33
37
|
const synchronizer = await TXESynchronizer.create();
|
|
34
|
-
const anchorBlockStore = new AnchorBlockStore(db);
|
|
35
|
-
|
|
36
38
|
const aztecNodeConfig = {} as AztecNodeConfig;
|
|
37
39
|
|
|
38
40
|
const log = createLogger('txe_node');
|
|
@@ -58,11 +60,21 @@ export class TXEStateMachine {
|
|
|
58
60
|
log,
|
|
59
61
|
);
|
|
60
62
|
|
|
61
|
-
|
|
63
|
+
const contractSyncService = new ContractSyncService(
|
|
64
|
+
node,
|
|
65
|
+
contractStore,
|
|
66
|
+
noteStore,
|
|
67
|
+
createLogger('txe:contract_sync'),
|
|
68
|
+
);
|
|
69
|
+
|
|
70
|
+
return new this(node, synchronizer, archiver, anchorBlockStore, contractSyncService);
|
|
62
71
|
}
|
|
63
72
|
|
|
64
73
|
public async handleL2Block(block: L2Block) {
|
|
65
|
-
// Create a checkpoint from the block manually
|
|
74
|
+
// Create a checkpoint from the block manually.
|
|
75
|
+
// TXE uses 1-block-per-checkpoint for testing simplicity, so we can use block number as checkpoint number.
|
|
76
|
+
// This uses the deprecated fromBlockNumber method intentionally for the TXE testing environment.
|
|
77
|
+
const checkpointNumber = CheckpointNumber.fromBlockNumber(block.number);
|
|
66
78
|
const checkpoint = new Checkpoint(
|
|
67
79
|
block.archive,
|
|
68
80
|
CheckpointHeader.from({
|
|
@@ -79,7 +91,7 @@ export class TXEStateMachine {
|
|
|
79
91
|
totalManaUsed: block.header.totalManaUsed,
|
|
80
92
|
}),
|
|
81
93
|
[block],
|
|
82
|
-
|
|
94
|
+
checkpointNumber,
|
|
83
95
|
);
|
|
84
96
|
|
|
85
97
|
const publishedCheckpoint = new PublishedCheckpoint(
|
|
@@ -91,6 +103,9 @@ export class TXEStateMachine {
|
|
|
91
103
|
),
|
|
92
104
|
[],
|
|
93
105
|
);
|
|
106
|
+
// Wipe contract sync cache when anchor block changes (mirrors BlockSynchronizer behavior)
|
|
107
|
+
this.contractSyncService.wipe();
|
|
108
|
+
|
|
94
109
|
await Promise.all([
|
|
95
110
|
this.synchronizer.handleL2Block(block),
|
|
96
111
|
this.archiver.addCheckpoints([publishedCheckpoint], undefined),
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { EpochAndSlot, EpochCacheInterface, EpochCommitteeInfo, SlotTag } from '@aztec/epoch-cache';
|
|
2
2
|
import { EpochNumber, SlotNumber } from '@aztec/foundation/branded-types';
|
|
3
3
|
import { EthAddress } from '@aztec/foundation/eth-address';
|
|
4
|
+
import { EmptyL1RollupConstants, type L1RollupConstants } from '@aztec/stdlib/epoch-helpers';
|
|
4
5
|
|
|
5
6
|
/**
|
|
6
7
|
* Mock implementation of the EpochCacheInterface used to satisfy dependencies of AztecNodeService.
|
|
@@ -64,4 +65,8 @@ export class MockEpochCache implements EpochCacheInterface {
|
|
|
64
65
|
filterInCommittee(_slot: SlotTag, _validators: EthAddress[]): Promise<EthAddress[]> {
|
|
65
66
|
return Promise.resolve([]);
|
|
66
67
|
}
|
|
68
|
+
|
|
69
|
+
getL1Constants(): L1RollupConstants {
|
|
70
|
+
return EmptyL1RollupConstants;
|
|
71
|
+
}
|
|
67
72
|
}
|
package/src/txe_session.ts
CHANGED
|
@@ -6,6 +6,7 @@ import { openTmpStore } from '@aztec/kv-store/lmdb-v2';
|
|
|
6
6
|
import type { ProtocolContract } from '@aztec/protocol-contracts';
|
|
7
7
|
import {
|
|
8
8
|
AddressStore,
|
|
9
|
+
AnchorBlockStore,
|
|
9
10
|
CapsuleStore,
|
|
10
11
|
JobCoordinator,
|
|
11
12
|
NoteService,
|
|
@@ -49,6 +50,7 @@ import type { IAvmExecutionOracle, ITxeExecutionOracle } from './oracle/interfac
|
|
|
49
50
|
import { TXEOraclePublicContext } from './oracle/txe_oracle_public_context.js';
|
|
50
51
|
import { TXEOracleTopLevelContext } from './oracle/txe_oracle_top_level_context.js';
|
|
51
52
|
import { RPCTranslator } from './rpc_translator.js';
|
|
53
|
+
import { TXEArchiver } from './state_machine/archiver.js';
|
|
52
54
|
import { TXEStateMachine } from './state_machine/index.js';
|
|
53
55
|
import type { ForeignCallArgs, ForeignCallResult } from './util/encoding.js';
|
|
54
56
|
import { TXEAccountStore } from './util/txe_account_store.js';
|
|
@@ -176,7 +178,9 @@ export class TXESession implements TXESessionStateHandler {
|
|
|
176
178
|
await contractStore.addContractInstance(instance);
|
|
177
179
|
}
|
|
178
180
|
|
|
179
|
-
const
|
|
181
|
+
const archiver = new TXEArchiver(store);
|
|
182
|
+
const anchorBlockStore = new AnchorBlockStore(store);
|
|
183
|
+
const stateMachine = await TXEStateMachine.create(archiver, anchorBlockStore, contractStore, noteStore);
|
|
180
184
|
|
|
181
185
|
const nextBlockTimestamp = BigInt(Math.floor(new Date().getTime() / 1000));
|
|
182
186
|
const version = new Fr(await stateMachine.node.getVersion());
|
|
@@ -335,29 +339,30 @@ export class TXESession implements TXESessionStateHandler {
|
|
|
335
339
|
const taggingIndexCache = new ExecutionTaggingIndexCache();
|
|
336
340
|
|
|
337
341
|
const utilityExecutor = this.utilityExecutorForContractSync(anchorBlock);
|
|
338
|
-
this.oracleHandler = new PrivateExecutionOracle(
|
|
339
|
-
Fr.ZERO,
|
|
340
|
-
new TxContext(this.chainId, this.version, GasSettings.empty()),
|
|
341
|
-
new CallContext(AztecAddress.ZERO, contractAddress, FunctionSelector.empty(), false),
|
|
342
|
-
anchorBlock!,
|
|
342
|
+
this.oracleHandler = new PrivateExecutionOracle({
|
|
343
|
+
argsHash: Fr.ZERO,
|
|
344
|
+
txContext: new TxContext(this.chainId, this.version, GasSettings.empty()),
|
|
345
|
+
callContext: new CallContext(AztecAddress.ZERO, contractAddress, FunctionSelector.empty(), false),
|
|
346
|
+
anchorBlockHeader: anchorBlock!,
|
|
343
347
|
utilityExecutor,
|
|
344
|
-
[],
|
|
345
|
-
[],
|
|
346
|
-
new HashedValuesCache(),
|
|
348
|
+
authWitnesses: [],
|
|
349
|
+
capsules: [],
|
|
350
|
+
executionCache: new HashedValuesCache(),
|
|
347
351
|
noteCache,
|
|
348
352
|
taggingIndexCache,
|
|
349
|
-
this.contractStore,
|
|
350
|
-
this.noteStore,
|
|
351
|
-
this.keyStore,
|
|
352
|
-
this.addressStore,
|
|
353
|
-
this.stateMachine.node,
|
|
354
|
-
this.senderTaggingStore,
|
|
355
|
-
this.recipientTaggingStore,
|
|
356
|
-
this.senderAddressBookStore,
|
|
357
|
-
this.capsuleStore,
|
|
358
|
-
this.privateEventStore,
|
|
359
|
-
this.
|
|
360
|
-
|
|
353
|
+
contractStore: this.contractStore,
|
|
354
|
+
noteStore: this.noteStore,
|
|
355
|
+
keyStore: this.keyStore,
|
|
356
|
+
addressStore: this.addressStore,
|
|
357
|
+
aztecNode: this.stateMachine.node,
|
|
358
|
+
senderTaggingStore: this.senderTaggingStore,
|
|
359
|
+
recipientTaggingStore: this.recipientTaggingStore,
|
|
360
|
+
senderAddressBookStore: this.senderAddressBookStore,
|
|
361
|
+
capsuleStore: this.capsuleStore,
|
|
362
|
+
privateEventStore: this.privateEventStore,
|
|
363
|
+
contractSyncService: this.stateMachine.contractSyncService,
|
|
364
|
+
jobId: this.currentJobId,
|
|
365
|
+
});
|
|
361
366
|
|
|
362
367
|
// We store the note and tagging index caches fed into the PrivateExecutionOracle (along with some other auxiliary
|
|
363
368
|
// data) in order to refer to it later, mimicking the way this object is used by the ContractFunctionSimulator. The
|
|
@@ -411,22 +416,22 @@ export class TXESession implements TXESessionStateHandler {
|
|
|
411
416
|
this.currentJobId,
|
|
412
417
|
).syncNoteNullifiers(contractAddress);
|
|
413
418
|
|
|
414
|
-
this.oracleHandler = new UtilityExecutionOracle(
|
|
419
|
+
this.oracleHandler = new UtilityExecutionOracle({
|
|
415
420
|
contractAddress,
|
|
416
|
-
[],
|
|
417
|
-
[],
|
|
421
|
+
authWitnesses: [],
|
|
422
|
+
capsules: [],
|
|
418
423
|
anchorBlockHeader,
|
|
419
|
-
this.contractStore,
|
|
420
|
-
this.noteStore,
|
|
421
|
-
this.keyStore,
|
|
422
|
-
this.addressStore,
|
|
423
|
-
this.stateMachine.node,
|
|
424
|
-
this.recipientTaggingStore,
|
|
425
|
-
this.senderAddressBookStore,
|
|
426
|
-
this.capsuleStore,
|
|
427
|
-
this.privateEventStore,
|
|
428
|
-
this.currentJobId,
|
|
429
|
-
);
|
|
424
|
+
contractStore: this.contractStore,
|
|
425
|
+
noteStore: this.noteStore,
|
|
426
|
+
keyStore: this.keyStore,
|
|
427
|
+
addressStore: this.addressStore,
|
|
428
|
+
aztecNode: this.stateMachine.node,
|
|
429
|
+
recipientTaggingStore: this.recipientTaggingStore,
|
|
430
|
+
senderAddressBookStore: this.senderAddressBookStore,
|
|
431
|
+
capsuleStore: this.capsuleStore,
|
|
432
|
+
privateEventStore: this.privateEventStore,
|
|
433
|
+
jobId: this.currentJobId,
|
|
434
|
+
});
|
|
430
435
|
|
|
431
436
|
this.state = { name: 'UTILITY' };
|
|
432
437
|
this.logger.debug(`Entered state ${this.state.name}`);
|
|
@@ -494,29 +499,30 @@ export class TXESession implements TXESessionStateHandler {
|
|
|
494
499
|
}
|
|
495
500
|
|
|
496
501
|
private utilityExecutorForContractSync(anchorBlock: any) {
|
|
497
|
-
return async (call: FunctionCall) => {
|
|
502
|
+
return async (call: FunctionCall, scopes: undefined | AztecAddress[]) => {
|
|
498
503
|
const entryPointArtifact = await this.contractStore.getFunctionArtifactWithDebugMetadata(call.to, call.selector);
|
|
499
504
|
if (entryPointArtifact.functionType !== FunctionType.UTILITY) {
|
|
500
505
|
throw new Error(`Cannot run ${entryPointArtifact.functionType} function as utility`);
|
|
501
506
|
}
|
|
502
507
|
|
|
503
508
|
try {
|
|
504
|
-
const oracle = new UtilityExecutionOracle(
|
|
505
|
-
call.to,
|
|
506
|
-
[],
|
|
507
|
-
[],
|
|
508
|
-
anchorBlock!,
|
|
509
|
-
this.contractStore,
|
|
510
|
-
this.noteStore,
|
|
511
|
-
this.keyStore,
|
|
512
|
-
this.addressStore,
|
|
513
|
-
this.stateMachine.node,
|
|
514
|
-
this.recipientTaggingStore,
|
|
515
|
-
this.senderAddressBookStore,
|
|
516
|
-
this.capsuleStore,
|
|
517
|
-
this.privateEventStore,
|
|
518
|
-
this.currentJobId,
|
|
519
|
-
|
|
509
|
+
const oracle = new UtilityExecutionOracle({
|
|
510
|
+
contractAddress: call.to,
|
|
511
|
+
authWitnesses: [],
|
|
512
|
+
capsules: [],
|
|
513
|
+
anchorBlockHeader: anchorBlock!,
|
|
514
|
+
contractStore: this.contractStore,
|
|
515
|
+
noteStore: this.noteStore,
|
|
516
|
+
keyStore: this.keyStore,
|
|
517
|
+
addressStore: this.addressStore,
|
|
518
|
+
aztecNode: this.stateMachine.node,
|
|
519
|
+
recipientTaggingStore: this.recipientTaggingStore,
|
|
520
|
+
senderAddressBookStore: this.senderAddressBookStore,
|
|
521
|
+
capsuleStore: this.capsuleStore,
|
|
522
|
+
privateEventStore: this.privateEventStore,
|
|
523
|
+
jobId: this.currentJobId,
|
|
524
|
+
scopes,
|
|
525
|
+
});
|
|
520
526
|
await new WASMSimulator()
|
|
521
527
|
.executeUserCircuit(toACVMWitness(0, call.args), entryPointArtifact, new Oracle(oracle).toACIRCallback())
|
|
522
528
|
.catch((err: Error) => {
|
|
@@ -87,7 +87,9 @@ export async function makeTXEBlock(
|
|
|
87
87
|
const newArchiveInfo = await worldTrees.getTreeInfo(MerkleTreeId.ARCHIVE);
|
|
88
88
|
const newArchive = new AppendOnlyTreeSnapshot(new Fr(newArchiveInfo.root), Number(newArchiveInfo.size));
|
|
89
89
|
|
|
90
|
-
// L2Block requires checkpointNumber and indexWithinCheckpoint
|
|
90
|
+
// L2Block requires checkpointNumber and indexWithinCheckpoint.
|
|
91
|
+
// TXE uses 1-block-per-checkpoint for testing simplicity, so we can use block number as checkpoint number.
|
|
92
|
+
// This uses the deprecated fromBlockNumber method intentionally for the TXE testing environment.
|
|
91
93
|
const checkpointNumber = CheckpointNumber.fromBlockNumber(globalVariables.blockNumber);
|
|
92
94
|
const indexWithinCheckpoint = IndexWithinCheckpoint(0);
|
|
93
95
|
|