-
Notifications
You must be signed in to change notification settings - Fork 0
feat(nibiru): geth v1.14 compatible with Nibiru #9
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
Looks like ethereum#30094 became a bit stale after ethereum#30185 was merged and now we have a stale ref to a state override object causing CI to fail on master.
Return the actually requested external port instead of 0 in the AddMapping implementation for `--nat extip:<IP>`.
The test specifies `ListenAddr: ":0"`, which means a random ephemeral port will be chosen for the TCP listener by the OS. Additionally, since no `DiscAddr` was specified, the same port that is chosen automatically by the OS will also be used for the UDP listener in the discovery UDP setup. This sometimes leads to test failures if the TCP listener picks a free TCP port that is already taken for UDP. By specifying `DiscAddr: ":0"`, the UDP port will be chosen independently from the TCP port, fixing the random failure. See issue ethereum#29830. Verified using ``` cd p2p go test -c -race stress ./p2p.test -test.run=TestServerPortMapping ... 5m0s: 4556 runs so far, 0 failures ``` The issue described above can technically lead to sporadic failures on systems that specify a listen address via the `--port` flag of 0 while not setting `--discovery.port`. Since the default is using port `30303` and using a random ephemeral port is likely not used much to begin with, not addressing the root cause might be acceptable.
…thereum#30239) ## Issue If `nextTime` has passed, but all nodes are excluded, `get` would return `nil` and `run` would therefore not invoke `schedule`. Then, we schedule a timer for the past, as neither `nextTime` value has been updated. This creates a busy loop, as the timer immediately returns. ## Fix With this PR, revalidation will be also rescheduled when all nodes are excluded. --------- Co-authored-by: lightclient <[email protected]>
…30219) This PR fixes an issue in the setMode method of beaconBackfiller where the log message was not displaying the previous mode correctly. The log message now shows both the old and new sync modes.
The package `github.com/golang/protobuf/proto` is deprecated in favor `google.golang.org/protobuf/proto`. We should update the codes to recommended package. Signed-off-by: Icarus Wu <[email protected]>
…reum#30195) Adding the correct accessList parameter when calling a contract can reduce gas consumption. However, the current version only allows adding the accessList manually when constructing the transaction. This PR can provide convenience for saving gas.
Removing because memsize will very likely be broken by Go 1.23. See fjl/memsize#4
Fixes a regression introduced in ethereum#30219
Fixes ethereum#30254 It seems like the removed CreateAccount call is very old and not needed anymore. After removing it, setting a sender that does not exist in the state doesn't seem to cause an issue.
…sed (ethereum#30267) Seems it is checked with the wrong argument Signed-off-by: jsvisa <[email protected]>
…30257) The struct-based tracing added in ethereum#29189 seems to have caused an issue with the benchmark `BenchmarkTracerStepVsCallFrame`. On master we see the following panic: ```console BenchmarkTracerStepVsCallFrame panic: runtime error: invalid memory address or nil pointer dereference [signal SIGSEGV: segmentation violation code=0x2 addr=0x40 pc=0x1019782f0] goroutine 37 [running]: github.com/ethereum/go-ethereum/eth/tracers/js.(*jsTracer).OnOpcode(0x140004c4000, 0x0, 0x10?, 0x989680, 0x1, {0x101ea2298, 0x1400000e258}, {0x1400000e258?, 0x14000155928?, 0x10173020c?}, ...) /Users/matt/dev/go-ethereum/eth/tracers/js/goja.go:328 +0x140 github.com/ethereum/go-ethereum/core/vm.(*EVMInterpreter).Run(0x14000307da0, 0x140003cc0d0, {0x0, 0x0, 0x0}, 0x0) ... FAIL github.com/ethereum/go-ethereum/core/vm/runtime 0.420s FAIL ``` The issue seems to be that `OnOpcode` expects that `OnTxStart` has already been called to initialize the `env` value in the tracer. The JS tracer uses it in `OnOpcode` for the `GetRefund()` method. This patch resolves the issue by reusing the `Call` method already defined in `runtime_test.go` which correctly calls `OnTxStart`.
Some chains’ network IDs use hexadecimal such as Optimism ("0xa" instead of "10"), so when converting the string to big.Int, we cannot specify base 10; otherwise, it will encounter errors with hexadecimal network IDs.
This PR adds the methods `Stack.swap1..16()` that faster than `Stack.swap(1..16)`. Co-authored-by: lmittmann <[email protected]>
…hereum#30274) (ethereum#30277) Precomputes valid primitive types into a map to use for validation, thus removing sprintf.
Consistently use `uint64` for indices in `Memory` and drop lots of type conversions from `uint64` to `int64`. --------- Co-authored-by: lmittmann <[email protected]>
Due to https://github.com/ethereum/tests/releases/tag/v10.1, the format of the TransactionTest changed, but it was not properly addressed, causing the test to pass unexpectedly. --------- Co-authored-by: Martin Holst Swende <[email protected]>
…nloader queue (ethereum#30276) Fixes a slight miscalculation in the downloader queue, which was not accurately taking block withdrawals into account when calculating the size of the items in the queue
fixes ethereum#30279 -- previously we did not use the basefee from the genesis, and instead the defaults were used from `runtime.go/setDefaults`-function
…ead of hard-coded value (ethereum#29721) Co-authored-by: Felix Lange <[email protected]> Co-authored-by: Marius van der Wijden <[email protected]> Co-authored-by: lightclient <[email protected]>
Looking at the history of these packages over the past several years, there haven't been any meaningful contributions or usages: https://github.com/ethereum/go-ethereum/commits/master/p2p/simulations?before=de6d5976794a9ed3b626d4eba57bf7f0806fb970+35 Almost all of the commits are part of larger refactors or low-hanging-fruit contributions. Seems like it's not providing much value and taking up team + contributor time.
…lete storage (ethereum#30258) This pull request fixes ethereum#30229. During snap sync, large storage will be split into several pieces and synchronized concurrently. Unfortunately, the tradeoff is that the respective merkle trie of each storage chunk will be incomplete due to the incomplete boundaries. The trie nodes on these boundaries will be discarded, and any dangling nodes on disk will also be removed if they fall on these paths, ensuring the state healer won't be blocked. However, the dangling account trie nodes on the path from the root to the associated account are left untouched. This means the dangling account trie nodes could potentially stop the state healing and break the assumption that the entire subtrie should exist if the subtrie root exists. We should consider the account trie node as the ancestor of the corresponding storage trie node. In the scenarios described in the above ticket, the state corruption could occur if there is a dangling account trie node while some storage trie nodes are removed due to synchronization redo. The fixing idea is pretty straightforward, the trie nodes on the path from root to account should all be explicitly removed if an incomplete storage trie occurs. Therefore, a `delete` operation has been added into `gentrie` to explicitly clear the account along with all nodes on this path. The special thing is that it's a cross-trie clearing. In theory, there may be a dangling node at any position on this account key and we have to clear all of them.
Adds support non-legacy transaction-signing using ledger --------- Co-authored-by: Martin Holst Swende <[email protected]>
This change updates the EIP-712 implementation to resolve [ethereum#30619](ethereum#30619). The test cases have been repurposed from the ethers.js [repository](https://github.com/ethers-io/ethers.js/blob/main/testcases/typed-data.json.gz), but have been updated to remove tests that don't have a valid domain separator; EIP-712 messages without a domain separator are not supported by geth. --------- Co-authored-by: Martin Holst Swende <[email protected]>
… and fork (ethereum#30442) When `evm statetest --bench` is specified, benchmark the execution similarly to `evm run`. Also adds the ability to filter tests by name, index and fork. --------- Co-authored-by: Martin Holst Swende <[email protected]>
This PR moves chain config related code (config file processing, fork logic, network defaults) from `beacon/types` and `beacon/blsync` into `beacon/params` while the command line flag logic of the chain config is moved into `cmd/utils`, thereby removing the cli dependencies from package `beacon` and its sub-packages.
This change invokes the OnCodeChange hook when selfdestruct operation is performed, and a contract is removed. This is an event which can be consumed by tracers.
Co-authored-by: Martin HS <[email protected]>
Adds a protocol handler fuzzer to fuzz the ETH68 protocol handlers
Fix panic in tests
add unit tests for `p2p/addrutil` --------- Co-authored-by: Martin HS <[email protected]>
fixes a typo on one of the postmortems
Fixes an error in the binary iterator, adds additional testcases --------- Co-authored-by: Gary Rong <[email protected]>
This is one further step towards removing account management from `geth`. This PR deprecates the flag `unlock`, and makes the flag moot: unlock via geth is no longer possible.
The [kilic](https://github.com/kilic/bls12-381) bls12381 implementation has been archived. It shouldn't be necessary to include it as a fuzzing target any longer. This also adds fuzzers for G1/G2 mul that use inputs that are guaranteed to be valid. Previously, we just did random input fuzzing for these precompiles.
…um#30534) This adds an API method `DropTransactions` to legacy pool, blob pool and txpool interface. This method removes all txs currently tracked in the pools. It modifies the simulated beacon to use the new method in `Rollback` which removes previous hacky implementation that also erroneously reset the gas tip to 1 gwei. --------- Co-authored-by: Felix Lange <[email protected]>
Continuation of ethereum#30381
Important Review skippedMore than 25% of the files skipped due to max files limit. The review is being skipped to prevent a low-quality review. 86 files out of 296 files are above the max files limit of 100. Please upgrade to Pro plan to get higher limits. You can disable this status message by setting the Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
gasRemaining
with=
instead of+=
(core: initializegasRemaining
with=
instead of+=
ethereum/go-ethereum#29149)excessBlobGas
(cmd/emv/internal/t8ntool: fix shadowing ofexcessBlobGas
ethereum/go-ethereum#29263)err
check (internal/ethapi: removes some leftovererr
check ethereum/go-ethereum#29339)debug_verbosity
ethereum/go-ethereum#29356)min
builtin (core/vm: refactor push-functions to usemin
builtin ethereum/go-ethereum#29515)VMTraceJsonConfig
(cmd/geth, cmd/utils: rename config and flag toVMTraceJsonConfig
ethereum/go-ethereum#29573)String
s (params: clarify consensus engine configString
s ethereum/go-ethereum#29643)NewBlock
,WithBody
taketypes.Body
(all: refactor soNewBlock
,WithBody
taketypes.Body
ethereum/go-ethereum#29482)ProcessBeaconBlockRoot
(core/tracing: add system call callback when performingProcessBeaconBlockRoot
ethereum/go-ethereum#29355)balanceCheck
should always includemsg.Value
ethereum/go-ethereum#29762)valid
function comments (trie: update thevalid
function comments ethereum/go-ethereum#29809)TestExpDecaySampleNanosecondRegression
(metrics: fixTestExpDecaySampleNanosecondRegression
sometimes failed ethereum/go-ethereum#29832)SampleSnapshot.Sum
(metrics: add test forSampleSnapshot.Sum
ethereum/go-ethereum#29831)node.TCP
tonode.UDP()
ethereum/go-ethereum#29879)int
ton
(common/math: rename variable nameint
toin
ethereum/go-ethereum#29890)ParseUint
instead ofParseInt
(common: usingParseUint
instead ofParseInt
ethereum/go-ethereum#30020)t.TempDir()
to simplify test temp dir manager ethereum/go-ethereum#30052)embed
pkg to split go source template to file ethereum/go-ethereum#30098)invalidMessageError
(rpc: show more error detail forinvalidMessageError
ethereum/go-ethereum#30191)OnTxStart
(core/vm/runtime: ensure tracer benchmark callsOnTxStart
ethereum/go-ethereum#30257)Sprintf
consumes lots of CPU ethereum/go-ethereum#30274) (signer/core: improve performance of isPrimitiveTypeValid function (#30274) ethereum/go-ethereum#30277)github.com/julienschmidt/httprouter
ethereum/go-ethereum#30290)vm.EVM.create()
(vm: simplify error handling invm.EVM.create()
ethereum/go-ethereum#30292)setEtherbase
(cmd/utils: fixsetEtherbase
ethereum/go-ethereum#30488)mode
(core/state: fix comment ofmode
ethereum/go-ethereum#30490)HeadTracker
(beacon/light: optimize lock usage inHeadTracker
ethereum/go-ethereum#30485)TxArgs.setCancunFeeDefaults
(internal/ethapi: remove unused parameters, error return fromTxArgs.setCancunFeeDefaults
ethereum/go-ethereum#30541)personal
RPC namespace (all: removepersonal
RPC namespace ethereum/go-ethereum#30704)AccessList
based on given block, not chain tip (internal/ethapi: Set basefee forAccessList
based on given block, not chain tip ethereum/go-ethereum#30538)statetest
command + filter by name, index and fork (cmd/evm: benchmarking viastatetest
command + filter by name, index and fork ethereum/go-ethereum#30442)SetZero
for verkle ethereum/go-ethereum#30472)