Override the transactionSimulator's default TransactionValidationParams with one that allows for exceeding the account balance (which effectively zeros the baseFee).
This mimics the way that eth_estimateGas and eth_call are implemented.
Signed-off-by: Simon Dudley <simon.dudley@consensys.net>
* Add log to show where we're reading the jwt from
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Standard path log
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Add jwt path to the prettified info log at startup
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Javadoc
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Refactor to only set engine configs when engine is enabled
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Print the ephemeral jwt created by besu if no jwt is passed to the engine api
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
---------
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Cancel older block creation tasks upon receiving a new one
Signed-off-by: Simon Dudley <simon.dudley@consensys.net>
* Use only one thread for building blocks so there is no risk of overlapping
Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
* Fix tests that fail when debug log is enabled
Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
---------
Signed-off-by: Simon Dudley <simon.dudley@consensys.net>
Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
Co-authored-by: Simon Dudley <simon.dudley@consensys.net>
Add deposits to the Execution Layer block structure: EIP-6110. The scope of this commit is to add Deposit related info into BlockHeader and BlockBody. The rest of the EIP including RPC API and validating Deposit with be included in future PRs.
---------
Signed-off-by: Navie Chan <naviechan@gmail.com>
Signed-off-by: navie <naviechan@gmail.com>
Signed-off-by: Simon Dudley <simon.dudley@consensys.net>
* Replace getByBlockNumber by getByBlockHeader
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Replace getByBlockNumber by getByBlockHeader
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Replace BlockDataGenerator by BlockHeaderTestFixture
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Replace BlockDataGenerator by BlockHeaderTestFixture
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Add final to method param
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Replace BlockDataGEnerator by BlockHeaderTestFixture
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Replace BlockDataGenerator by BlockHeaderTestFixture
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
* Remove BlockDataGenerator
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
---------
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
Introduce BftProtocolSchedule with a copy of MutableProtocolSchedule.getByBlockNumber.
This method will be deleted from the ProtocolSchedule interfaces and so will only exist in BftProtocolSchedule.
Use BftProtocolSchedule in CombinedProtocolScheduleFactory.
Move getScheduledProtocolSpecs into BftProtocolSchedule since it is only used by CombinedProtocolScheduleFactory.
Rename existing BftProtocolSchedule classes to append Builder for clarity.
Signed-off-by: Simon Dudley <simon.dudley@consensys.net>
It's now only used by the tests following removal of production code paths in 08b822a860
A simple decorator pattern would have been a nicer implementation but I didn't want to expose the protocolSpecs from within the schedule hence why I've used inheritance.
ForksIdsNetworkConfigTest has a particularly hairy construction since it relies on TransitionProtocolSchedule but I've isolated this as an inner class.
I am hopeful that we can refactor ForksIdsNetworkConfigTest out of existence eventually and avoid using streamMilestoneBlocks at the same time.
Signed-off-by: Simon Dudley <simon.dudley@consensys.net>
Changes and config to support using GraalVM AOT to compile and
execute evmTool as an alternate configuration.
While not as long-term performant the startup time
makes filling reference tests with Besu reasonable.
Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com>
* no need to run codeql on merge group
* no need to run repolinter on merge group
* no need to run checks and gradle-wrapper on merge group
Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
---------
Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
Replace usages of streamMilestoneBlocks on production code paths: RunnerBuilder and TransactionPoolFactory.
These usages were also using getBlockByNumber which is ultimately what we're trying to remove.
Signed-off-by: Simon Dudley <simon.dudley@consensys.net>
* Upgrade reference tests to v12.
* Extend the UncleFromSideChain exception to all future forks
Signed-off-by: Danno Ferrin <danno.ferrin@swirldslabs.com>
<!-- Thanks for sending a pull request! Please check out our
contribution guidelines: -->
<!-- https://github.com/hyperledger/besu/blob/main/CONTRIBUTING.md -->
## PR description
This PR aims to remove the usage of getByBlockNumber from the
FlexiblePrivacyPrecompiledContract. As far as analysis shows the only
requirement is to get a protocolSpec (it doesn't matter which one)
currently it always fetches the protocolSpec for block number 1 which
can vary according to the network config. We're changing that get the
protocolSpec for block 0 which is the only block we always have the
header.
AT nonmainnet on circle CI
Pipeline - 21048
## Fixed Issue(s)
<!-- Please link to fixed issue(s) here using format: fixes #<issue
number> -->
<!-- Example: "fixes #2" -->
Fixes#5160
## Documentation
- [x] I thought about documentation and added the `doc-change-required`
label to this PR if
[updates are
required](https://wiki.hyperledger.org/display/BESU/Documentation).
## Acceptance Tests (Non Mainnet)
- [x] I have considered running `./gradlew acceptanceTestNonMainnet`
locally if my PR affects non-mainnet modules.
## Changelog
- [x] I thought about the changelog and included a [changelog update if
required](https://wiki.hyperledger.org/display/BESU/Changelog).
---------
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
This GHA will add the checklist that's currently in the PR template, as
a comment, on newly opened PRs.
Because it needs write access (to add the comment), it needs to run on
the `pull_request_target` action, which means you won't see the outcome
on _this_ PR, but only once it's merged in, you'll see it on subsequent
PRs - example -
https://github.com/daisy-row/vigilant-octo-umbrella/pull/51
---------
Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
tracing endpoints keep open a worldstate for the duration of tracing and
response generation.
---------
Signed-off-by: Karim TAAM <karim.t2am@gmail.com>
Signed-off-by: garyschulte <garyschulte@gmail.com>
Co-authored-by: Karim TAAM <karim.t2am@gmail.com>
<!-- Thanks for sending a pull request! Please check out our
contribution guidelines: -->
<!-- https://github.com/hyperledger/besu/blob/main/CONTRIBUTING.md -->
## PR description
There is an issue when restarting Besu when a backward sync session is
running, since after the restart it is possible that the Consensus
client sends a FcU or a NewPayload for a block that is present in the
backward sync storage, but not yet imported, so not on the main chain,
but still the backward sync thinks it should not do anything with that
block, so it returns like it has completed the sync, but since the sync
is not done actually then the internal error that the finalize block is
not present.
The solution is to persist the backward sync status, so in case of a
restart, it can resume from where it was interrupted.
## Fixed Issue(s)
<!-- Please link to fixed issue(s) here using format: fixes #<issue
number> -->
<!-- Example: "fixes #2" -->
fixes#5053
## Documentation
- [x] I thought about documentation and added the `doc-change-required`
label to this PR if
[updates are
required](https://wiki.hyperledger.org/display/BESU/Documentation).
## Acceptance Tests (Non Mainnet)
- [x] I have considered running `./gradlew acceptanceTestNonMainnet`
locally if my PR affects non-mainnet modules.
## Changelog
- [x] I thought about the changelog and included a [changelog update if
required](https://wiki.hyperledger.org/display/BESU/Changelog).
---------
Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
Co-authored-by: Sally MacFarlane <macfarla.github@gmail.com>