Commit graph

16473 commits

Author SHA1 Message Date
Jared Wasinger
fbe136a45e fix build 2025-10-17 13:31:48 +08:00
Jared Wasinger
eb7f934f26 minor cleanups 2025-10-17 13:31:48 +08:00
Jared Wasinger
ca6ba13d1b ensure tracers don't call CodeChange with prevCode==curCode (was done in the case of a failed contract creation). remove unecessary error check and panic 2025-10-17 13:31:48 +08:00
Jared Wasinger
c2c132d6a0 more documentation 2025-10-17 13:31:48 +08:00
Jared Wasinger
2e84d09c1c improve --experimental.bal flag description 2025-10-17 13:31:48 +08:00
Jared Wasinger
45fc8d2468 remove amsterdam tests 2025-10-17 13:31:48 +08:00
Jared Wasinger
68a4ecaf1f refactor: move access list index mutations/read construction within the ConstructionAccessList and don't expose it publicly 2025-10-17 13:31:46 +08:00
Gary Rong
7410413eec core/state, core/tracing: add state read hooks 2025-10-17 13:29:38 +08:00
Gary Rong
af34c01b90 core/tracing: reshape the comments in core/tracing 2025-10-17 13:28:51 +08:00
Jared Wasinger
b33cf06ce7 all: add block access list construction via flag --experimentalbal. When enabled, post-Cancun blocks which lack access lists will have them constructed on execution during import. When importing blocks which contain access lists, transaction execution and state root calculation is performed in parallel. 2025-10-17 13:28:04 +08:00
ucwong
0a2c21acd5
eth/ethconfig : fix eth generate config (#32929) 2025-10-17 10:35:44 +08:00
Youssef Azzaoui
b373d797d8
core/state: state copy bugfixes with Verkle Trees (#31696)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
This change addresses critical issues in the state object duplication
process specific to Verkle trie implementations. Without these
modifications, updates to state objects fail to propagate correctly
through the trie structure after a statedb copy operation, leading to
inaccuracies in the computation of the state root hash.

---------

Co-authored-by: Guillaume Ballet <3272758+gballet@users.noreply.github.com>
2025-10-16 19:19:44 +02:00
aodhgan
ff54ca02de
internal/ethapi: add eth_SendRawTransactionSync (#32830)
New RPC method eth_sendRawTransactionSync(rawTx, timeoutMs?) that
submits a signed tx and blocks until a receipt is available or a timeout
elapses.

Two CLI flags to tune server-side limits:

--rpc.txsync.defaulttimeout (default wait window)

--rpc.txsync.maxtimeout (upper bound; requests are clamped)

closes https://github.com/ethereum/go-ethereum/issues/32094

---------

Co-authored-by: aodhgan <gawnieg@gmail.com>
Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
2025-10-16 17:34:47 +02:00
hero5512
c37bd67019
ethclient: add support for eth_simulateV1 (#32856)
Adds ethclient support for the eth_simulateV1 RPC method, which allows
simulating transactions on top of a base state without making changes to
the blockchain.

---------

Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
2025-10-16 17:32:55 +02:00
Galoretka
5c535074ac
cmd/geth: log current key in expandVerkle instead of keylist[0] (#32689)
Some checks are pending
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
Fix logging in the verkle dump path to report the actual key being
processed.
Previously, the loop always logged keylist[0], which misled users when
expanding multiple keys and made debugging harder. This change aligns
the
log with the key passed to root.Get, improving traceability and
diagnostics.
2025-10-16 13:49:41 +02:00
Felix Lange
367b5fbe42 version: begin v1.16.6 release cycle 2025-10-16 09:59:52 +02:00
Felix Lange
32ccb548d3 version: release go-ethereum v1.16.5 stable 2025-10-16 09:58:47 +02:00
Felix Lange
7c107c2691
p2p/discover: remove hot-spin in table refresh trigger (#32912)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
This fixes a regression introduced in #32518. In that PR, we removed the
slowdown logic that would throttle lookups when the table runs empty.
Said logic was originally added in #20389.

Usually it's fine, but there exist pathological cases, such as hive
tests, where the node can only discover one other node, so it can only
ever query that node and won't get any results. In cases like these, we
need to throttle the creation of lookups to avoid crazy CPU usage.
2025-10-15 11:51:33 +02:00
Delweng
40505a9bc0
eth/protocols/eth: reject message containing duplicated txs and drop peer (#32728)
Drop peer if sending the same transaction multiple times in a single message.

Fixes https://github.com/ethereum/go-ethereum/issues/32724


---------

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Co-authored-by: Gary Rong <garyrong0905@gmail.com>
Co-authored-by: Csaba Kiraly <csaba.kiraly@gmail.com>
2025-10-15 10:24:48 +02:00
mishraa-G
3cfc33477b
rpc: fix flaky test TestServerWebsocketReadLimit (#32889) 2025-10-15 15:39:00 +08:00
Felix Lange
f6064f32c4
internal/ethapi: convert legacy blobtx proofs in sendRawTransaction (#32849)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
This adds a temporary conversion path for blob transactions with legacy
proof sidecar. This feature will activate after Fusaka. We will phase
this out when the fork has sufficiently settled and client side
libraries have been upgraded to send the new proofs.
2025-10-14 14:40:54 +02:00
cui
55a53208b7
accounts/abi: check presence of payable fallback or receive before proceeding with transfer (#32374)
remove todo
2025-10-14 17:07:48 +08:00
rjl493456442
e03d97a420
core/txpool/legacypool: fix pricedList updates (#32906)
This pr addresses a few issues brought by the #32270 

- Add updates to pricedList after dropping transactions.
- Remove redundant deletions in queue.evictList, since
pool.removeTx(hash, true, true) already performs the removal.
- Prevent duplicate addresses during promotion when Reset is not nil.
2025-10-14 08:40:04 +02:00
Csaba Kiraly
fb8d2298b6
eth: do not warn on switching from snap sync to full sync (#32900)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
This happens normally after a restart, so it is better to use Info level
here.

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
2025-10-14 11:03:31 +08:00
Csaba Kiraly
00f6f2b32f
eth/catalyst: remove useless log on enabling Engine API (#32901) 2025-10-14 11:01:43 +08:00
Guillaume Ballet
52c484de86
triedb/pathdb: catch int conversion overflow in 32-bit (#32899)
The limit check for `MaxUint32` is done after the cast to `int`. On 64
bits machines, that will work without a problem. On 32 bits machines,
that will always fail. The compiler catches it and refuses to build.

Note that this only fixes the compiler build. ~~If the limit is above
`MaxInt32` but strictly below `MaxUint32` then this will fail at runtime
and we have another issue.~~ I checked and this should not happen during
regular execution, although it might happen in tests.
2025-10-14 09:23:05 +08:00
Delweng
6337577434
p2p/discover: wait for bootstrap to be done (#32881)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
This ensures the node is ready to accept other nodes into the
table before it is used in a test.

Closes #32863
2025-10-13 19:58:50 +02:00
Felföldi Zsolt
b28241ba85
cmd/workload: filter fuzzer test (#31613)
This PR adds a `filterfuzz` subcommand to the workload tester that
generates requests similarly to `filtergen` (though with a much smaller
block length limit) and also verifies the results by retrieving all
block receipts in the range and locally filtering out relevant results.
Unlike `filtergen` that operates on the finalized chain range only,
`filterfuzz` does check the head region, actually it seeds a new query
at every new chain head.
2025-10-13 19:21:01 +02:00
Marius van der Wijden
7b693ea17c
core/txpool/legacypool: move queue out of main txpool (#32270)
This PR move the queue out of the main transaction pool.
For now there should be no functional changes.
I see this as a first step to refactor the legacypool and make the queue
a fully separate concept from the main pending pool.

---------

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Co-authored-by: Csaba Kiraly <csaba.kiraly@gmail.com>
2025-10-13 19:07:36 +02:00
cui
b87581f297
p2p/enode: optimize DistCmp (#32888)
This speeds up DistCmp by 75% through using 64-bit operations instead of
byte-wise XOR.
2025-10-13 16:16:07 +02:00
cui
5c6ba6b400
p2p/enode: optimize LogDist (#32887)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
This speeds up LogDist by 75% using 64-bit operations instead
of byte-wise XOR.

---------

Co-authored-by: Felix Lange <fjl@twurst.com>
2025-10-13 14:00:43 +02:00
Delweng
a7359ceb69
triedb, core/rawdb: implement the partial read in freezer (#32132)
This PR implements the partial read functionalities in the freezer, optimizing
the state history reader by resolving less data from freezer.

---------

Signed-off-by: jsvisa <delweng@gmail.com>
Co-authored-by: Gary Rong <garyrong0905@gmail.com>
2025-10-13 19:40:03 +08:00
Lewis
bc0a21a1d5
eth/filters: uninstall subscription in filter apis on error (#32894)
Fix https://github.com/ethereum/go-ethereum/issues/32893.

In the previous https://github.com/ethereum/go-ethereum/pull/32794, it
only handles the pending tx filter, while there are also head and log
filters. This PR applies the patch to all filter APIs and uses `defer`
to maintain code consistency.
2025-10-13 13:10:44 +02:00
Delweng
85e9977fae
p2p: rm unused var seedMinTableTime (#32876) 2025-10-13 16:40:08 +08:00
cui
2010781c29
core/types: optimize MergeBloom by using bitutil (#32882)
```
goos: darwin
goarch: amd64
pkg: github.com/ethereum/go-ethereum/core/types
cpu: VirtualApple @ 2.50GHz
                                 │   old.txt    │               new.txt               │
                                 │    sec/op    │   sec/op     vs base                │
CreateBloom/small-createbloom-10    1.676µ ± 4%   1.646µ ± 1%   -1.76% (p=0.000 n=10)
CreateBloom/large-createbloom-10    164.8µ ± 3%   164.3µ ± 0%        ~ (p=0.247 n=10)
CreateBloom/small-mergebloom-10    231.60n ± 0%   68.00n ± 0%  -70.64% (p=0.000 n=10)
CreateBloom/large-mergebloom-10    21.803µ ± 3%   5.107µ ± 1%  -76.58% (p=0.000 n=10)
geomean                             6.111µ        3.113µ       -49.06%

                                 │    old.txt     │                new.txt                │
                                 │      B/op      │     B/op      vs base                 │
CreateBloom/small-createbloom-10     112.0 ± 0%       112.0 ± 0%       ~ (p=1.000 n=10) ¹
CreateBloom/large-createbloom-10   10.94Ki ± 0%     10.94Ki ± 0%       ~ (p=0.474 n=10)
CreateBloom/small-mergebloom-10      0.000 ± 0%       0.000 ± 0%       ~ (p=1.000 n=10) ¹
CreateBloom/large-mergebloom-10      0.000 ± 0%       0.000 ± 0%       ~ (p=1.000 n=10) ¹
geomean                                         ²                 +0.00%                ²
¹ all samples are equal
² summaries must be >0 to compute geomean

                                 │   old.txt    │               new.txt               │
                                 │  allocs/op   │ allocs/op   vs base                 │
CreateBloom/small-createbloom-10   6.000 ± 0%     6.000 ± 0%       ~ (p=1.000 n=10) ¹
CreateBloom/large-createbloom-10   600.0 ± 0%     600.0 ± 0%       ~ (p=1.000 n=10) ¹
CreateBloom/small-mergebloom-10    0.000 ± 0%     0.000 ± 0%       ~ (p=1.000 n=10) ¹
CreateBloom/large-mergebloom-10    0.000 ± 0%     0.000 ± 0%       ~ (p=1.000 n=10) ¹
geomean                                       ²               +0.00%                ²
¹ all samples are equal
² summaries must be >0 to compute geomean
```
2025-10-13 16:39:10 +08:00
Luke Ma
a3aae29845
node: fix error condition in gzipResponseWriter.init() (#32896) 2025-10-13 15:26:35 +08:00
10gic
659342a523
ethclient: add SubscribeTransactionReceipts (#32869)
Some checks failed
/ Linux Build (push) Has been cancelled
/ Linux Build (arm) (push) Has been cancelled
/ Windows Build (push) Has been cancelled
/ Docker Image (push) Has been cancelled
Add `SubscribeTransactionReceipts` for ethclient. This is a complement
to https://github.com/ethereum/go-ethereum/pull/32697.
2025-10-10 11:47:33 +02:00
rjl493456442
de24450dbf
core/rawdb, triedb/pathdb: introduce trienode history (#32596)
It's a pull request based on the #32523 , implementing the structure of
trienode history.
2025-10-10 14:51:27 +08:00
cui
ed264a1f19
eth/protocols/snap: optimize incHash (#32748) 2025-10-10 13:48:25 +08:00
Csaba Kiraly
4d6d5a3abf
core/txpool/legacypool: fix validTxMeter to count transactions (#32845)
invalidTxMeter was counting txs, while validTxMeter was counting
accounts. Better make the two comparable.

---------

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
2025-10-10 13:40:10 +08:00
10gic
11208553dd
eth/filters: add transactionReceipts subscription (#32697)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
- Introduce a new subscription kind `transactionReceipts` to allow clients to
  receive transaction receipts over WebSocket as soon as they are available.
- Accept optional `transactionHashes` filter to subscribe to receipts for specific
  transactions; an empty or omitted filter subscribes to all receipts.
- Preserve the same receipt format as returned by `eth_getTransactionReceipt`.
- Avoid additional HTTP polling, reducing RPC load and latency.

---------

Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
2025-10-09 14:14:53 +02:00
CertiK
a1b8e4880d
eth/filters: terminate pending tx subscription on error (#32794)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
Fixes issue #32793. When the pending tx subscription ends, the filter
is removed from `api.filters`, but it is not terminated. There is no other 
way to terminate it, so the subscription will leak, and potentially block
the producer side.
2025-10-09 11:34:30 +02:00
phrwlk
695c1445ab
core/rawdb: correct misleading comments for state history accessors (#32783)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
2025-10-09 08:59:06 +08:00
Alexey Osipov
e42af536c5
cmd/devp2p/internal/ethtest: accept responses in any order (#32834)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
In both `TestSimultaneousRequests` and `TestSameRequestID`, we send two
concurrent requests. The client under test is free to respond in either
order, so we need to handle responses both ways.

Also fixes an issue where some generated blob transactions didn't have
any blobs.

---------

Co-authored-by: Felix Lange <fjl@twurst.com>
2025-10-08 19:23:44 +02:00
Nicolas Gotchac
064ab701ea
eth/protocols/eth: use BlockChain interface in Handshake (#32847) 2025-10-08 12:50:03 +02:00
sashass1315
168d699fba
core/rawdb: remove duplicated type storedReceiptRLP (#32820)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
Co-authored-by: Felix Lange <fjl@twurst.com>
2025-10-08 11:29:51 +02:00
Felix Lange
d67037a981
cmd/devp2p/internal/ethtest: update to PoS-only test chain (#32850) 2025-10-08 11:14:27 +02:00
Sina M
ee309827c6
build: faster gh actions workflow, no ubuntu on appveyor (#32829)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
This PR does a few things:

- Sets the gh actions runner sizes for lint (s) and test (l) workflows
- Runs the tests on gh actions in parallel
- Skips fetching the spec tests when unnecessary (on windows in
appveyor)
- Removes ubuntu appveyor runner since it's essentially duplicate of the
gh action workflow now

The gh test seems to go down from ~35min to ~13min.
2025-10-07 11:24:30 +02:00
Nikita Mescheryakov
477ee5873b
internal/ethapi: add timestamp to logs in eth_simulate (#32831)
Some checks are pending
/ Linux Build (push) Waiting to run
/ Linux Build (arm) (push) Waiting to run
/ Windows Build (push) Waiting to run
/ Docker Image (push) Waiting to run
Adds blockTimestamp to the logs in response of eth_simulateV1.

---------

Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
2025-10-06 18:19:25 +02:00
hero5512
1e4b39ed12
trie: cleaner array concatenation (#32756)
Some checks failed
/ Linux Build (push) Has been cancelled
/ Linux Build (arm) (push) Has been cancelled
/ Windows Build (push) Has been cancelled
/ Docker Image (push) Has been cancelled
It uses the slices.Concat and slices.Clone methods available now in Go.
2025-10-02 17:32:20 +02:00