Skip to content

Commit 4f08c6b

Browse files
committed
chore: drop unused imports and fix test-input types after per-block bundle change (A-1374)
1 parent 13ec8ee commit 4f08c6b

4 files changed

Lines changed: 8 additions & 11 deletions

File tree

yarn-project/prover-client/src/orchestrator/block-proving-state.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,8 @@ import {
88
type NESTED_RECURSIVE_ROLLUP_HONK_PROOF_LENGTH,
99
} from '@aztec/constants';
1010
import { BlockNumber } from '@aztec/foundation/branded-types';
11-
import { padArrayEnd } from '@aztec/foundation/collection';
1211
import { Fr } from '@aztec/foundation/curves/bn254';
13-
import { type Tuple } from '@aztec/foundation/serialize';
12+
import type { Tuple } from '@aztec/foundation/serialize';
1413
import { type TreeNodeLocation, UnbalancedTreeStore } from '@aztec/foundation/trees';
1514
import type { PublicInputsAndRecursiveProof } from '@aztec/stdlib/interfaces/server';
1615
import type { RollupHonkProofData } from '@aztec/stdlib/proofs';
@@ -378,7 +377,8 @@ export class BlockProvingState {
378377
if (this.isFirstBlock) {
379378
return { leaves: this.parentCheckpoint.getPaddedL1ToL2Messages(), numMsgs: MAX_L1_TO_L2_MSGS_PER_BLOCK };
380379
}
381-
return { leaves: padArrayEnd([], Fr.ZERO, MAX_L1_TO_L2_MSGS_PER_BLOCK), numMsgs: 0 };
380+
// Array.from (not padArrayEnd) keeps the type `Fr[]` — a padArrayEnd to the literal cap infers a deep tuple type.
381+
return { leaves: Array.from({ length: MAX_L1_TO_L2_MSGS_PER_BLOCK }, () => Fr.ZERO), numMsgs: 0 };
382382
}
383383

384384
/**

yarn-project/prover-client/src/orchestrator/checkpoint-sub-tree-orchestrator.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,7 @@ import type {
2525
ReadonlyWorldStateAccess,
2626
ServerCircuitProver,
2727
} from '@aztec/stdlib/interfaces/server';
28-
import {
29-
L1ToL2MessageSponge,
30-
accumulateL1ToL2MessageSponge,
31-
appendL1ToL2MessagesToTree,
32-
} from '@aztec/stdlib/messaging';
28+
import { L1ToL2MessageSponge, appendL1ToL2MessagesToTree } from '@aztec/stdlib/messaging';
3329
import type { ParityPublicInputs } from '@aztec/stdlib/parity';
3430
import {
3531
type BaseRollupHints,
@@ -530,7 +526,7 @@ export class CheckpointSubTreeOrchestrator extends ProvingScheduler {
530526
// Precompute the message-bundle sponges. The checkpoint's messages are padded to the per-checkpoint cap (the first
531527
// block's transitional bundle); base parity `i` starts from the sponge over the first `i` chunks, and the whole
532528
// padded sponge is inherited by non-first block roots.
533-
const paddedL1ToL2Messages = padArrayEnd(l1ToL2Messages, Fr.ZERO, MAX_L1_TO_L2_MSGS_PER_CHECKPOINT);
529+
const paddedL1ToL2Messages = padArrayEnd<Fr, number>(l1ToL2Messages, Fr.ZERO, MAX_L1_TO_L2_MSGS_PER_CHECKPOINT);
534530
const baseParityStartSponges: L1ToL2MessageSponge[] = [];
535531
let runningSponge = L1ToL2MessageSponge.empty();
536532
for (let i = 0; i < NUM_BASE_PARITY_PER_ROOT_PARITY; i++) {

yarn-project/prover-client/src/test/bb_prover_full_rollup.test.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,9 @@ describe('prover/bb_prover/full-rollup', () => {
103103
}
104104

105105
topTreeData.push({
106-
blockProofs: subTree.getSubTreeResult().then(r => r.blockProofOutputs),
106+
blockProofs: subTree
107+
.getSubTreeResult()
108+
.then(r => ({ blockProofOutputs: r.blockProofOutputs, parityRootProof: r.parityRootProof })),
107109
l2ToL1MsgsPerBlock: blocks.map(b => b.txs.map(tx => tx.txEffect.l2ToL1Msgs)),
108110
blobFields: checkpoint.toBlobFields(),
109111
previousBlockHeader,

yarn-project/stdlib/src/tests/factories.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import {
99
AVM_V2_PROOF_LENGTH_IN_FIELDS,
1010
CHONK_PROOF_LENGTH,
1111
CONTRACT_CLASS_LOG_SIZE_IN_FIELDS,
12-
L1_TO_L2_MSG_SUBTREE_ROOT_SIBLING_PATH_LENGTH,
1312
L1_TO_L2_MSG_TREE_HEIGHT,
1413
MAX_CHECKPOINTS_PER_EPOCH,
1514
MAX_CONTRACT_CLASS_LOGS_PER_TX,

0 commit comments

Comments
 (0)