Skip to content
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

Upstream merge from go-ethereum/v1.11.6 #949

Merged
merged 1,271 commits into from
Aug 3, 2023
Merged

Conversation

0xsharma
Copy link
Contributor

@0xsharma 0xsharma commented Aug 3, 2023

Description

In this PR, we are merging from the upstream from v1.11.6.

karalabe and others added 30 commits February 9, 2023 13:31
* common/prque, eth/downloader: fix timeout resurrection panic

* common/prque: revert -1 hack for les, temporaryly!
…ent `value` (#26632)

This is a breaking change in the tracing hooks API as well as semantics of the callTracer:

- CaptureEnter hook provided a nil value argument in case of DELEGATECALL. However to stay consistent with how delegate calls behave in EVM this hook is changed to pass in the value of the parent call.
- callTracer will return parent call's value for DELEGATECALL frames.

---------

Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
* params: schedule shanghai fork on sepolia

* params: u64 -> newUint64
Logs stored on disk have minimal information. Contextual information such as block
number, index of log in block, index of transaction in block are filled in upon request.
We can fill in all these fields only having the block header and list of receipts.
But determining the transaction hash of a log requires the block body.

The goal of this PR is postponing this retrieval until we are sure we the transaction hash.
It happens often that the header bloom filter signals there might be matches in a block,
but after actually checking them reveals the logs do not match. We want to avoid fetching
the body in this case.

Note that this changes the semantics of Backend.GetLogs. Downstream callers of
GetLogs now assume log context fields have not been derived, and need to call
DeriveFields on the logs if necessary.
This change allows all post-Berlin forks to be specified as overrides for futureForkBlock in the config parameter for traceBlockToFile.
This change fixes a fuzzer which broke when we updated the gnark dependency earlier.
Our discovery crawler spits out a huge amount of logs, most of which is pretty non-interesting. This change moves the very verbose output to Debug, and adds a 8-second status log message giving the general idea about what's going on.
This change updates the CHT entries for mainnet and rinkeby
* eth/filters: replace atomic.Pointer

* fix

* improve

Co-authored-by: Martin Holst Swende <martin@swende.se>

---------

Co-authored-by: Martin Holst Swende <martin@swende.se>
MemTableStopWritesThreshold was set to the max size of all memtables before blocking writing but should be set to the max number of memtables. This is documented [here](https://github.com/cockroachdb/pebble/blob/master/options.go#L738-L742).
…(#26675)

This PR relaxes the block body ingress handling a bit: if block body withdrawals are missing (but expected to be empty), the body withdrawals are set to 'empty list' before being passed to upper layers. 

This fixes an issue where a block passed from EthereumJS to geth was deemed invalid.
travis, build: update Go to 1.20
This PR is a (superior) alternative to ethereum/go-ethereum#26708, it handles deprecation, primarily two specific cases. 

`rand.Seed` is typically used in two ways
- `rand.Seed(time.Now().UnixNano())` -- we seed it, just to be sure to get some random, and not always get the same thing on every run. This is not needed, with global seeding, so those are just removed. 
- `rand.Seed(1)` this is typically done to ensure we have a stable test. If we rely on this, we need to fix up the tests to use a deterministic prng-source. A few occurrences like this has been replaced with a proper custom source. 

`rand.Read` has been replaced by `crypto/rand`.`Read` in this PR.
This change will break one hive test, but pass another and it will be the better way going forward
The method `GetPayloadBodiesByRangeV1` now returns "-38004: Too large request" error if the requested range is too large, according to spec

Co-authored-by: Martin Holst Swende <martin@swende.se>
@0xsharma 0xsharma requested a review from a team August 3, 2023 09:17
@0xsharma 0xsharma merged commit b09b69c into develop Aug 3, 2023
@marcello33 marcello33 deleted the mardizzone/upstream-merge branch November 16, 2023 11:49
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.