-
Notifications
You must be signed in to change notification settings - Fork 956
feat(peerDAS): add max number of blob per transaction #8761
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(peerDAS): add max number of blob per transaction #8761
Conversation
Signed-off-by: Gabriel-Trintinalia <gabriel.trintinalia@consensys.net>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a per-transaction blob limit (max blobs per transaction) across scheduling, calculators, validation, JSON-RPC endpoints, and configuration parsing. It updates:
- The blob schedule model and JSON config to accept a new
maxPerTx
field, defaulting tomax
. - Osaka/Cancun gas limit calculators and the transaction validator to enforce the new per-transaction blob gas cap.
- Tests and JSON-RPC logic to validate blob count against the new limit.
Reviewed Changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
ethereum/core/src/main/java/.../OsakaTargetingGasLimitCalculator.java | Added maxBlobsPerTransaction parameter and transactionBlobGasLimitCap . |
ethereum/core/src/main/java/.../MainnetBlobsValidator.java | Enforced per-transaction blob gas limit in validation. |
ethereum/core/src/main/java/.../GasLimitCalculator.java | Added default transactionBlobGasLimitCap() method. |
ethereum/api/src/.../AbstractEngineNewPayload.java | Added RPC-level blob count check against transactionBlobGasLimitCap . |
config/src/main/java/.../BlobSchedule.java | Switched to static factory, added maxPerTransaction , and key parsing. |
config/src/test/resources/mainnet_with_blob_schedule.json | Introduced maxPerTx fields in blob schedules. |
config/src/main/java/.../BlobScheduleOptionsTest.java | Expanded tests for parsing maxPerTransaction . |
ethereum/core/.../OsakaTargetingGasLimitCalculatorTest.java & related tests | Updated constructor calls and tests for new parameter. |
Comments suppressed due to low confidence (1)
ethereum/core/src/main/java/org/hyperledger/besu/ethereum/mainnet/OsakaTargetingGasLimitCalculator.java:59
- The method
getBlobGasPerBlob()
does not exist onGasCalculator
; usegasCalculator.blobGasCost(1)
(or another appropriate call) to retrieve the per-blob gas cost, then multiply bymaxBlobsPerTransaction
.
this.transactionBlobGasLimitCap = gasCalculator.getBlobGasPerBlob() * maxBlobsPerTransaction;
"bpo5": { | ||
"target": 51, | ||
"max": 52, | ||
"maxPerTx": 53, |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion for error message consistency
ethereum/core/src/main/java/org/hyperledger/besu/ethereum/GasLimitCalculator.java
Outdated
Show resolved
Hide resolved
ethereum/core/src/main/java/org/hyperledger/besu/ethereum/mainnet/MainnetBlobsValidator.java
Outdated
Show resolved
Hide resolved
ethereum/core/src/main/java/org/hyperledger/besu/ethereum/mainnet/MainnetBlobsValidator.java
Outdated
Show resolved
Hide resolved
ethereum/core/src/main/java/org/hyperledger/besu/ethereum/mainnet/MainnetBlobsValidator.java
Show resolved
Hide resolved
…r block Signed-off-by: Gabriel-Trintinalia <gabriel.trintinalia@consensys.net>
Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
Signed-off-by: Gabriel-Trintinalia <gabriel.trintinalia@consensys.net>
cherry-picked commit from #8820 |
Signed-off-by: Gabriel-Trintinalia <gabriel.trintinalia@consensys.net>
PR description
Implements ethereum/EIPs#9623
Target for devnet-2
fixes: #8760