-
Notifications
You must be signed in to change notification settings - Fork 0
Core 2534 investigate get dependency #4
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
Conversation
Fixes an incorrect encoding of recursive bytes types. closes ethereum/go-ethereum#30979
Shout-out to @Gabriel-Trintinalia for discovering this issue. The gist of it as follows: When processing a block, we should provide the parent block as well as the last 256 block hashes. Some of these parents data (specifically the hash) was incorrect because even though during the processing of the parent block we have updated the header, that header was not updating the TransactionsRoot and ReceiptsRoot fields (types.NewBlock makes a new copy of the header and changes it only on that instance). --------- Co-authored-by: lightclient <[email protected]>
Fixed broken or outdated links and improved documentation formatting to ensure consistency and correct references. --------- Co-authored-by: Sina M <[email protected]>
I ran into this while trying to debug a discv5 thing. I tried to disable DNS discovery using `--discovery.dns=false`, which doesn't work. Annoyingly, geth started anyway and discarded the error silently. I eventually found my mistake, but it took way longer than it should have. Also including a small change to the error message for invalid DNS URLs here. The user actually needs to see the URL to make sense of the error.
Updates cloudflare-go from v0.79.0 to v0.114.0 which also gets rid of a dependency to `github.com/hashicorp/go-retryablehttp` which had a security flaw. Diff: cloudflare/cloudflare-go@v0.79.0...v0.114.0 I did a quick sanity check on the diff on all methods that we use and went through the release notes, there was nothing related to how we use it afaict
In this PR, several improvements have been made: Authorization-related validations have been moved to legacyPool. Previously, these checks were part of the standard validation procedure, which applies common validations across different pools. Since these checks are specific to SetCode transactions, relocating them to legacyPool is a more reasonable choice. Additionally, authorization conflict checks are now performed regardless of whether the transaction is a replacement or not. --------- Co-authored-by: lightclient <[email protected]>
We forgot to add the deposit contract address for holesky, causing deposits to not be flagged correctly --------- Co-authored-by: lightclient <[email protected]>
Adds a basic sanity test case to catch any go-routines leaked from instantiation/closing of a simulated backend.
This fixes an issue where dial candidates from discv5 would be ignored because the "eth" ENR entry was not loaded correctly.
Fixes lint issue
>>> /home/appveyor/.gvm/gos/go1.24.0/bin/go generate ./...
ci.go:404: File changed: .git/index
ci.go:407: One or more generated files were updated by running 'go generate ./...'
exit status 1
This change divides BlobGasUsed by MaxBlobGasPerBlock instead of MaxBlobsPerBlock. Dividing by MaxBlobsPerBlock meant the blobGasUsedRatio was an incorrect large number. This bug was introduced by a typo [here](ethereum/go-ethereum@e6f3ce7#diff-3357b2399699d7cf954c543cbfb02ff442eb24491e55f5e813e3cc85829b3e8dR110) Fixes ethereum/go-ethereum#31245
Co-authored-by: Felix Lange <[email protected]> Co-authored-by: Sina Mahmoodi <[email protected]>
Follow on to #31246. Adds a sanity check in the test to make sure the ratio value never goes over 1. Would have avoided the issue in #31245.
when remove an non-SetCodeTxType transaction, error logs flood ``` t=2025-02-25T03:11:06+0000 lvl=error msg="Authority with untracked tx" addr=0xD5bf9221fCB1C31Cd1EE477a60c148d40dD63DC1 hash=0x626fdf205a5b1619deb2f9e51fed567353f80acbd522265b455daa0821c571d9 ``` in this PR, only try to removeAuthorities for txs with SetCodeTxType in addition, the performance of removeAuthorities improved a lot, because no need range all `t.auths` now. --------- Co-authored-by: lightclient <[email protected]>
This is for fixing the PPA build, which has been failing since the update to Go 1.24. In Go 1.24, the required Go version for bootstrapping was updated to 1.22. In general, they are following through with always depending on the Go version two releases ago for bootstrapping. Since we still support Ubuntu Xenial (16.04) until its EOL date of 04/2026, and Xenial only has golang 1.10 as a package, we now need to build Go a total of four times to get the most recent version. I'm adding a step for Go 1.23 here. This should last us until Go 1.25, which should be out around 04/2026, and we can hopefully drop the first bootstrapping step at that time.
This changes the go mod tidy check to use the go mod tidy -diff command, removing the custom diffing for go.mod. The check for go.mod/go.sum is now performed in the check_generate action. Also included is a change where check_generate and check_baddeps will now run on the GitHub Actions lint step. --------- Co-authored-by: Felix Lange <[email protected]>
This is a not-particularly-important "cleanliness" PR. It removes the last remnants of the `x/exp` package, where we used the `maps.Keys` function. The original returned the keys in a slice, but when it became 'native' the signature changed to return an iterator, so the new idiom is `slices.Collect(maps.Keys(theMap))`, unless of course the raw iterator can be used instead. In some cases, where we previously collect into slice and then sort, we can now instead do `slices.SortXX` on the iterator instead, making the code a bit more concise. This PR might be _slighly_ less optimal, because the original `x/exp` implementation allocated the slice at the correct size off the bat, which I suppose the new code won't. Putting it up for discussion. --------- Co-authored-by: Felix Lange <[email protected]>
Next attempt at fixing the build on launchpad.net
Hi, it seems these methods in the `backend.go` and `api_backend.go` files are not used that expose the eventMux, but that is not needed.
In transaction-sending APIs such as `eth_sendRawTransaction`, a submitted transaction failing the configured txpool validation rules (i.e. fee too low) would cause an error to be returned, even though the transaction was successfully added into the locals tracker. Once added there, the transaction may even be included into the chain at a later time, when fee market conditions change. This change improves on this by performing the validation in the locals tracker, basically skipping some of the validation rules for local transactions. We still try to add the tx to the main pool immediately, but an error will only be returned for transactions which are fundamentally invalid. --------- Co-authored-by: Gary Rong <[email protected]>
…ved (#31219) This ensures that if we receive a blob transaction announcement where we cannot link the tx to the sidecar commitments, we will drop the sending peer. This check is added in the protocol handler for the PooledTransactions message. Tests for this have also been added in the cross-client "eth" protocol test suite. --------- Co-authored-by: Felix Lange <[email protected]>
This PR contains three refactors: - refactor the latest fork check that we use quite extensively - refactor the nil checks in NewPayloads --------- Co-authored-by: lightclient <[email protected]>
Fix a todo: force-enable this in --dev mode --------- Co-authored-by: jwasinger <[email protected]>
This adds support for naming the source iterators of FairMix, like so:
mix.AddSource(enode.WithSourceName("mySource", iter))
The source that produced the latest node is returned by the new NodeSource method.
…gen-7 testnet (#31014) Adding values to the witness introduces a new class of issues for computing gas: if there is not enough gas to cover adding an item to the witness, then the item should not be added to the witness. The problem happens when several items are added together, and that process runs out of gas. The witness gas computation needs a way to signal that not enough gas was provided. These values can not be hardcoded, however, as they are context dependent, i.e. two calls to the same function with the same parameters can give two different results. The approach is to return both the gas that was actually consumed, and the gas that was necessary. If the values don't match, then a witness update OOG'd. The caller should then charge the `consumed` value (remaining gas will be 0) and error out. Why not return a boolean instead of the wanted value? Because when several items are touched, we want to distinguish which item lacked gas. --------- Signed-off-by: Guillaume Ballet <[email protected]>
This adds a geth subcommand for downloading era1 files and placing them into the correct location. The tool can be used even while geth is already running on the datadir. Downloads are checked against a hard-coded list of checksums for mainnet and sepolia. ``` ./geth download-era --server $SERVER --block 333333 ./geth download-era --server $SERVER --block 333333-444444 ./geth download-era --server $SERVER --epoch 0-10 ./geth download-era --server $SERVER --all ``` The implementation reuses the file downloader we already had for fetching build tools. I've done some refactoring on it to make sure it can support the new use case, and there are some changes to the build here as well.
They were not widely used in users setups.
…30661) In this pull request, snapshot generation in pathdb has been ported from the legacy state snapshot implementation. Additionally, when running in path mode, legacy state snapshot data is now managed by the pathdb based snapshot logic. Note: Existing snapshot data will be re-generated, regardless of whether it was previously fully constructed.
This PR implements eth/69. This protocol version drops the bloom filter from receipts messages, reducing the amount of data needed for a sync by ~530GB (2.3B txs * 256 byte) uncompressed. Compressed this will be reduced to ~100GB The new version also changes the Status message and introduces the BlockRangeUpdate message to relay information about the available history range. --------- Co-authored-by: Felix Lange <[email protected]>
Small optimization in debug_getModifiedAccountsBy* to avoid fetching block body.
I added a test for BlockRangeUpdate in #29158 but forgot to enable it. Here I'm adding two more tests for it. Also applied a small refactoring to combine calls to `dial()` and `peer()` into a single function, since these two calls are duplicated in each test.
remove duplicate code Signed-off-by: Csaba Kiraly <[email protected]>
The `compile` and `eth_getWork` `eth_submitWork` apis were not available anymore, so try to remove them
Hey team—noticed a dead link, replaced it with a working URL https://github.com/moby/moby/blob/master/pkg/reexec/reexec.go - old link https://github.com/moby/moby/blob/master/pkg/reexec/reexec_deprecated.go - new link
I've updated the broken link to point to the current official Ethereum JSON-RPC API documentation at https://ethereum.org/en/developers/docs/apis/json-rpc/. This is the correct and up-to-date location for the Ethereum Execution Layer APIs documentation. The link should now work properly.
Some tests involving transactions near the txMaxSize limit were flaky. This was due to ECDSA signatures occasionally having leading zeros, which are omitted during RLP encoding — making the final transaction size 1 byte smaller than expected. To address this, a new helper function pricedDataTransactionWithFixedSignature was added. It ensures both r and s are exactly 32 bytes (i.e., no leading zeros), producing transactions with deterministic size.
This PR introduces a new native tracer for AA bundlers. Bundlers participating in the alternative mempool will need to validate userops. This tracer will return sufficient information for them to decide whether griefing is possible. Resolves #30546 --------- Co-authored-by: Sina M <[email protected]>
Optimize updateStateObject to reduce an allocation.
…ive and custom types. (#2)
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 updates the Ethereum ABI binding generation by replacing the old “bind” package with “abigen” and introducing a new v2 binding generator (bindv2.go), while also updating tests to use the newer go-ethereum core types and to run in parallel. Key changes include the refactoring of binding-related helpers and methods (e.g. replacing custom name normalizers with abi.ToCamelCase), migration of generator template functions, and extensive test updates with improved timeouts and parallel execution.
Reviewed Changes
Copilot reviewed 1639 out of 1639 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| accounts/abi/abigen/source2.go.tpl | Generated binding template; no functional issues observed. |
| accounts/abi/abigen/bindv2_test.go | New tests for v2 bindings; updated to use types.GenesisAlloc etc. |
| accounts/abi/abigen/bindv2.go | Implements new v2 binder and helper functions with cleaner logic. |
| accounts/abi/abigen/bind_test.go | Test updates: package renamed to “abigen”, updated genesis alloc, and increased event wait timers. |
| accounts/abi/abigen/bind.go | Refactored binding generator: updated comments, replaced custom normalizers with abi.ToCamelCase, and small spelling fixes. |
| accounts/abi/abi_test.go / abifuzzer_test.go / abi.go | Test improvements: parallel test execution added and minor comment fixes. |
Comments suppressed due to low confidence (2)
accounts/abi/abigen/bind_test.go:1499
- The event filtering test timeout was increased from 3 to 10 seconds; please confirm that this change is intentional, as longer timeouts may slow down the test suite.
case <-time.NewTimer(3 * time.Second).C:
accounts/abi/abigen/bind.go:128
- [nitpick] The removal of language-specific normalization (using a dedicated mapping) in favor of a direct call to abi.ToCamelCase simplifies the code. Please verify that all usage of name normalization in the project now aligns with this approach.
normalizedName := abi.ToCamelCase(alias(aliases, original.Name))
| @@ -79,9 +72,9 @@ func isKeyWord(arg string) bool { | |||
|
|
|||
| // Bind generates a Go wrapper around a contract ABI. This wrapper isn't meant | |||
| // to be used as is in client code, but rather as an intermediate struct which | |||
| // enforces compile time type safety and naming convention opposed to having to | |||
| // enforces compile time type safety and naming convention as opposed to having to | |||
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.
The comment correction from 'opposed' to 'as opposed to' improves clarity; ensure similar documentation updates are consistent throughout the code.
| // enforces compile time type safety and naming convention as opposed to having to | |
| // enforces compile time type safety and naming convention instead of having to |
Copilot uses AI. Check for mistakes.
| @@ -251,7 +254,7 @@ var revertSelector = crypto.Keccak256([]byte("Error(string)"))[:4] | |||
| var panicSelector = crypto.Keccak256([]byte("Panic(uint256)"))[:4] | |||
|
|
|||
| // panicReasons map is for readable panic codes | |||
| // see this linkage for the deails | |||
| // see this linkage for the details | |||
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.
The typo in the comment ('deails' has been corrected to 'details'); such fixes enhance the documentation quality.
| // see this linkage for the details | |
| // see this link for the details |
Copilot uses AI. Check for mistakes.
No description provided.