Skip to content

Collect batch fees into a single P2ID note - #2647

Merged
Mirko-von-Leipzig merged 4 commits into
mirko/batch-fees-pass-through-txfrom
mirko/collect-batch-fees
Sep 21, 2026
Merged

Mirko-von-Leipzig merged 4 commits into
mirko/batch-fees-pass-through-txfrom
mirko/collect-batch-fees

Conversation

@Mirko-von-Leipzig

@Mirko-von-Leipzig Mirko-von-Leipzig commented Sep 18, 2026

Copy link
Copy Markdown
Collaborator

The batch builder uses the fee-collector account to send tx fees to a configured wallet. The collection of this by the wallet is left to a separate service or app, and is not critical for now.

The sequencer CLI accepts --batch.builder.wallet-account-id as the recipient of batch-building fees. The wallet is managed separately; the sequencer does not need its account file or signing key. Local development networks and benchmarks send collected fees to an arbitrary non-existent account ID for now.

The fee-collector is now required by the sequencer in order to startup, as otherwise batch building won't work.

Batch selection reserves capacity for the collector transaction and its output note. The mempool distinguishes the selected batch ID from the proven batch ID because the appended transaction changes the ID. Batches without fee notes omit the collector transaction and keep their selected batch ID.

The batch builder submits the appended collector transaction to the validators before proving the batch.

Part of #2501.

Changelog

[[entry]]
scope       = "node"
impact      = "added"
description = "Aggregate transaction fees into a single P2ID note sent to the batch builder's wallet."

[[entry]]
scope       = "node"
impact      = "breaking"
description = "Require the batch builder's wallet account ID when starting the sequencer."

@Mirko-von-Leipzig
Mirko-von-Leipzig added this pull request to stack #2641 September 18, 2026 07:31
@Mirko-von-Leipzig
Mirko-von-Leipzig removed this pull request from stack #2641 September 18, 2026 09:45
@Mirko-von-Leipzig
Mirko-von-Leipzig added this pull request to stack #2649 September 18, 2026 09:47
@Mirko-von-Leipzig
Mirko-von-Leipzig marked this pull request as ready for review September 18, 2026 10:19

@PhilippGackstatter PhilippGackstatter left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me ito fee collector usage.

Comment thread bin/node/src/commands/modes.rs Outdated
@Mirko-von-Leipzig
Mirko-von-Leipzig force-pushed the mirko/collect-batch-fees branch 2 times, most recently from 6c853a1 to 5d8a1a7 Compare September 18, 2026 12:48
@Mirko-von-Leipzig
Mirko-von-Leipzig merged commit ac34242 into next Sep 21, 2026
29 of 51 checks passed
@Mirko-von-Leipzig
Mirko-von-Leipzig deleted the mirko/collect-batch-fees branch September 21, 2026 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants