-
Notifications
You must be signed in to change notification settings - Fork 19
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
In the txpool, reject a tx if its simulation fails #2
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Gabriel-Trintinalia <[email protected]>
Signed-off-by: Gabriel-Trintinalia <[email protected]>
Signed-off-by: Gabriel-Trintinalia <[email protected]>
Signed-off-by: Gabriel-Trintinalia <[email protected]>
Signed-off-by: Gabriel-Trintinalia <[email protected]>
Signed-off-by: Gabriel-Trintinalia <[email protected]>
Signed-off-by: Gabriel-Trintinalia <[email protected]>
Signed-off-by: Gabriel-Trintinalia <[email protected]>
fab-10
force-pushed
the
eth-sendrawtransaction-line-count-integration
branch
from
April 10, 2024 08:40
9183d34
to
b8464d7
Compare
fab-10
changed the title
Reject a tx, sent via eth_sendRawTransaction, if exceeds any of the module line count limit
Reject a tx, sent via eth_sendRawTransaction, if its simulation fails
Apr 10, 2024
fab-10
force-pushed
the
eth-sendrawtransaction-line-count-integration
branch
from
April 10, 2024 10:59
b8464d7
to
52b6531
Compare
Signed-off-by: Fabio Di Fabio <[email protected]>
fab-10
force-pushed
the
eth-sendrawtransaction-line-count-integration
branch
from
April 10, 2024 14:09
52b6531
to
201e5fd
Compare
fab-10
changed the title
Reject a tx, sent via eth_sendRawTransaction, if its simulation fails
In the txpool, reject a tx if its simulation fails
Apr 10, 2024
# Conflicts: # arithmetization/src/main/java/net/consensys/linea/AbstractLineaSharedOptionsPlugin.java # arithmetization/src/main/java/net/consensys/linea/rpc/linea/LineaEstimateGas.java # arithmetization/src/main/java/net/consensys/linea/sequencer/modulelimit/ModuleLimitsValidationResult.java
Signed-off-by: Fabio Di Fabio <[email protected]>
Gabriel-Trintinalia
approved these changes
Apr 10, 2024
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.
LGTM. PR is pretty straightforward. Some minor nits
...main/java/net/consensys/linea/sequencer/txpoolvalidation/validators/SimulationValidator.java
Outdated
Show resolved
Hide resolved
...zation/src/main/java/net/consensys/linea/config/LineaTransactionPoolValidatorCliOptions.java
Show resolved
Hide resolved
...zation/src/main/java/net/consensys/linea/config/LineaTransactionPoolValidatorCliOptions.java
Show resolved
Hide resolved
Signed-off-by: Fabio Di Fabio <[email protected]>
fab-10
force-pushed
the
eth-sendrawtransaction-line-count-integration
branch
from
April 11, 2024 12:56
0b7f9db
to
9cbd5d1
Compare
Signed-off-by: Fabio Di Fabio <[email protected]>
fab-10
force-pushed
the
eth-sendrawtransaction-line-count-integration
branch
from
April 11, 2024 13:00
9cbd5d1
to
88a814a
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds the option to perform a simulation of the tx when adding it to the txpool, and rejecting it in case the simulation fails, due to the tx being invalid, reverted or any module line count is over the limit. If the tx is rejected then an error response is returned to the caller of
eth_sendRawTransaction
.There are 2 new options to enable/disable this check, depending on the source of the tx:
plugin-linea-tx-pool-simulation-check-api-enabled
: by defaulttrue
, enables the check for transactions sent viaeth_sendRawTransaction
plugin-linea-tx-pool-simulation-check-p2p-enabled
: by defaultfalse
, enabled the check for transactions sent via P2P