Sina Mahmoodi
d267c7d976
move live directory to main directory module
2024-03-25 15:10:30 -04:00
Sina Mahmoodi
b73207705b
refactor args to msg and tx
...
# Conflicts:
# internal/ethapi/api.go
# internal/ethapi/transaction_args.go
2024-03-25 15:10:03 -04:00
Martin Holst Swende
c76d4f01ce
eth/tracers, cmd/evm: unexport JSONlogger
2024-03-18 15:56:37 -04:00
Matthieu Vachon
f596461a23
Backported a bunch more of eth/tracers
2024-03-15 14:06:11 -04:00
Matthieu Vachon
3834f135a9
Series of changes to get backport to 1.13.5 working
2024-03-14 16:53:22 -04:00
Sina Mahmoodi
77486e91fb
fix lint issue
2024-03-14 16:23:56 -04:00
Sina Mahmoodi
d0a86c45b5
rm canceler
2024-03-14 16:23:56 -04:00
Sina Mahmoodi
94fc0b4a9e
replace opcode with byte
...
# Conflicts:
# core/tracing/hooks.go
# core/vm/evm.go
# core/vm/instructions.go
# eth/tracers/js/tracer_test.go
2024-03-14 16:23:54 -04:00
Sina Mahmoodi
5c6fb316b7
rm OnKeccakPreimage
...
# Conflicts:
# core/tracing/hooks.go
2024-03-14 16:16:43 -04:00
Sina Mahmoodi
7190602bd2
rm embedding of noop tracer
2024-03-14 16:16:20 -04:00
Sina Mahmoodi
03e48ee451
rename tracer methods to On pattern
...
# Conflicts
# core/vm/interpreter.go
# eth/tracers/directory/noop.go
# eth/tracers/js/goja.go
# eth/tracers/live/noop.go
# eth/tracers/logger/logger.go
# eth/tracers/logger/logger_json.go
# eth/tracers/native/4byte.go
# eth/tracers/native/call.go
# eth/tracers/native/call_flat.go
# eth/tracers/native/mux.go
2024-03-14 16:16:18 -04:00
Sina Mahmoodi
25a3a744c3
rename Capture hooks to On
...
# Conflicts:
# cmd/evm/internal/t8ntool/execution.go
# core/vm/instructions.go
# eth/tracers/directory/noop.go
# eth/tracers/internal/tracetest/calltrace_test.go
# eth/tracers/internal/tracetest/flat_calltrace_test.go
# eth/tracers/internal/tracetest/prestate_test.go
# eth/tracers/js/goja.go
# eth/tracers/js/tracer_test.go
# eth/tracers/live/noop.go
# eth/tracers/native/4byte.go
# eth/tracers/native/call.go
# eth/tracers/native/call_flat.go
# eth/tracers/native/mux.go
# eth/tracers/native/prestate.go
2024-03-14 16:07:18 -04:00
Sina Mahmoodi
688f0b9654
rename scopeContext to opContext
2024-03-14 16:03:07 -04:00
Sina Mahmoodi
d4ec634c05
rename GetLogger to Hooks
...
# Conflicts:
# eth/tracers/logger/access_list_tracer.go
# eth/tracers/logger/logger.go
# eth/tracers/logger/logger_json.go
# eth/tracers/logger/logger_test.go
# eth/tracers/tracers_test.go
# internal/ethapi/api.go
2024-03-14 16:03:05 -04:00
Sina Mahmoodi
39fc9dcafb
move logger interface to core/tracing
...
# Conflicts:
# cmd/evm/internal/t8ntool/execution.go
# consensus/beacon/consensus.go
# consensus/ethash/consensus.go
# consensus/misc/dao.go
# core/evm.go
# core/genesis.go
# core/state/state_object.go
# core/state/state_test.go
# core/state/statedb.go
# core/state/statedb_fuzz_test.go
# core/state/statedb_test.go
# core/state/sync_test.go
# core/state/trie_prefetcher_test.go
# core/state_transition.go
# core/txpool/blobpool/blobpool_test.go
# core/txpool/legacypool/legacypool2_test.go
# core/txpool/legacypool/legacypool_test.go
# core/vm/evm.go
# core/vm/instructions.go
# core/vm/interface.go
# eth/api_debug_test.go
# internal/ethapi/api.go
# tests/block_test_util.go
# tests/state_test_util.go
2024-03-14 15:59:21 -04:00
Sina Mahmoodi
b202e8ab74
renaming GetLogger
...
# Conflicts:
# cmd/evm/internal/t8ntool/transition.go
# eth/tracers/logger/logger_test.go
# eth/tracers/tracers_test.go
2024-03-14 13:58:26 -04:00
Sina Mahmoodi
e1c669b3aa
moaar fixes
...
# Conflicts:
# core/state/state_test.go
# core/state/statedb_fuzz_test.go
# core/state/statedb_test.go
# core/state/sync_test.go
# core/state/trie_prefetcher_test.go
# core/txpool/blobpool/blobpool_test.go
# core/txpool/legacypool/legacypool2_test.go
# core/txpool/legacypool/legacypool_test.go
# eth/api_debug_test.go
2024-03-14 13:56:15 -04:00
Sina Mahmoodi
29ebfb30c3
fixes, rm t8ntool tracewriter
...
# Conflicts:
# cmd/evm/internal/t8ntool/execution.go
# cmd/evm/internal/t8ntool/transition.go
# core/vm/instructions.go
# eth/tracers/internal/tracetest/calltrace_test.go
# eth/tracers/internal/tracetest/flat_calltrace_test.go
# eth/tracers/internal/tracetest/prestate_test.go
# eth/tracers/js/tracer_test.go
# eth/tracers/logger/logger_test.go
# eth/tracers/tracers_test.go
# tests/block_test_util.go
# tests/state_test_util.go
2024-03-14 13:51:16 -04:00
Sina Mahmoodi
f1027b7c0a
fix goja scope object wrappers
2024-03-14 13:42:40 -04:00
Sina Mahmoodi
6013241175
fix memory copy util func
2024-03-14 13:42:40 -04:00
Sina Mahmoodi
e0b96540b7
Add canceler interface
2024-03-14 13:42:40 -04:00
Sina Mahmoodi
4e43718bd0
full struct-based tracing infra
...
# Conflicts:
# consensus/beacon/consensus.go
# consensus/ethash/consensus.go
# consensus/misc/dao.go
# core/blockchain.go
# core/evm.go
# core/genesis.go
# core/state/dump.go
# core/state/state_object.go
# core/state/statedb.go
# core/state_transition.go
# core/vm/evm.go
# core/vm/instructions.go
# core/vm/interface.go
# internal/ethapi/api.go
2024-03-14 12:09:18 -04:00
Sina Mahmoodi
4df6904051
use struct for tracing events
...
# Conflicts:
# core/blockchain.go
# core/state/state_object.go
# core/state/statedb.go
2024-03-14 11:57:58 -04:00
Sina Mahmoodi
8ec4560e17
refactor onBlockStart params, new skip method
2024-03-14 11:54:59 -04:00
Sina Mahmoodi
b210cc761d
remove onBeaconBlockRoot events
2024-03-14 11:54:59 -04:00
Sina Mahmoodi
d17940d2e7
minor fix
2024-03-14 11:54:59 -04:00
Sina Mahmoodi
318dc84314
add config for tracers
2024-03-14 11:54:59 -04:00
Sina Mahmoodi
2264a9c3fe
fix mdLogger
...
Backport of cf6a31514b
2024-02-09 16:08:43 -05:00
Sina Mahmoodi
97e9a8b315
fix blockchain -> logger circular import
...
Backport of 03206befb9
2024-02-09 16:07:56 -05:00
Matthieu Vachon
7ff2ae6924
indicate Known block
...
Backport of 056f229260
2024-02-08 16:04:15 -05:00
Matthieu Vachon
31b3b7dca3
rm OnNewAccount
...
Backport of 57cd0c30df
2024-02-08 15:57:12 -05:00
Matthieu Vachon
9f71824d8c
Backported commits from extended-tracer
...
- 6c44a594f4
- 188cd4182e
- f3c0a89b57
- 95b50299a5
- 2cc09548bb
2024-02-06 15:36:12 -05:00
Matthieu Vachon
7f8926e716
Backporting extended-tracer branch
...
We backported branch `extended-tracer` at commit 3078dfe80b back to v1.13.5 of Geth.
To achieve the backport, we did:
- git checkout -b extended-tracer-squashed
- git reset --hard 3078dfe80b
- git reset --mixed fc380f52ef # This was the latest merged commit not from `extended-tracer` branch
- git commit -A -m "<This message>"
- git checkout v1.13.5
- git checkout -b extended-tracer-backport-v1.13.5
- git cherry-pick extended-tracer-squashed
2024-02-06 13:06:08 -05:00
Alvaro Sevilla
b1cec853be
eth/tracers: add position field for callTracer logs ( #28389 )
...
Currently, one can use the "withLogs" parameter to include logs in the
callTracer results, which allows the user to see at which trace level
was each log emitted.
This commit adds a position field to the logs which determine
the exact ordering of a call's logs and its subcalls. This would
be useful e.g. for explorers wishing to display the flow of execution.
Co-authored-by: jsvisa <delweng@gmail.com>
2023-11-03 10:28:27 +01:00
Felix Lange
9b46986edc
all: use rlp.DecodeBytes instead of rlp.Decode where possible ( #27994 )
2023-08-24 11:47:42 +03:00
Péter Szilágyi
0c6bbeb423
core, eth, trie: expose more detailed dirty ram tracking for diff layers ( #27971 )
2023-08-23 14:08:39 +03:00
Joe Netti
e0b119884c
eth/tracers/js: use t.toBig on ctx.GasPrice for js tracing ( #27903 )
...
This change fixes a bug in js tracer, where `ctx.GasPrice.toString(16)` returns a number string in base `10`.
2023-08-15 14:19:37 -04:00
Péter Szilágyi
be65b47645
all: update golang/x/ext and fix slice sorting fallout ( #27909 )
...
The Go authors updated golang/x/ext to change the function signature of the slices sort method.
It's an entire shitshow now because x/ext is not tagged, so everyone's codebase just
picked a new version that some other dep depends on, causing our code to fail building.
This PR updates the dep on our code too and does all the refactorings to follow upstream...
2023-08-12 00:04:12 +02:00
rjl493456442
503f1f7ada
all: activate pbss as experimental feature ( #26274 )
...
* all: activate pbss
* core/rawdb: fix compilation error
* cma, core, eth, les, trie: address comments
* cmd, core, eth, trie: polish code
* core, cmd, eth: address comments
* cmd, core, eth, les, light, tests: address comment
* cmd/utils: shorten log message
* trie/triedb/pathdb: limit node buffer size to 1gb
* cmd/utils: fix opening non-existing db
* cmd/utils: rename flag name
* cmd, core: group chain history flags and fix tests
* core, eth, trie: fix memory leak in snapshot generation
* cmd, eth, internal: deprecate flags
* all: enable state tests for pathdb, fixes
* cmd, core: polish code
* trie/triedb/pathdb: limit the node buffer size to 256mb
---------
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2023-08-10 22:21:36 +03:00
jwasinger
d233b6b23a
core: replace instances of 'suicide' with 'selfdestruct' to improve code consistency. ( #27716 )
...
---------
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: lightclient <14004106+lightclient@users.noreply.github.com>
2023-07-15 10:35:30 -04:00
Ryan Schneider
517ac886d4
eth/tracers/native: panic on memory read in prestateTracer ( #27691 )
...
Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
2023-07-13 14:44:42 +02:00
Delweng
1e069cf802
eth/tracers: add ReturnData in the tracer's response ( #27704 )
...
The struct logger (or opcode tracer) was missing the return data field even
if this was explicitly enabled by user via `"enableReturnData": true` in the config.
This PR fixes this issue.
Co-authored-by: Sina Mahmoodi <itz.s1na@gmail.com>
2023-07-13 14:43:25 +02:00
Guillaume Ballet
85b8d1c06c
params, trie: add verkle fork management + upgrade go-verkle ( #27464 )
...
* params, trie: add verkle fork management + upgrade go-verkle
* remove the two verkle files
* core, eth, params: add missing function
* Gary's feedback
* remove trie/utils/verkle.go
* add verkle block override
---------
Co-authored-by: Gary Rong <garyrong0905@gmail.com>
2023-06-28 12:08:48 +03:00
Dan Laine
b1ef0bfe03
eth: use slices package for sorting ( #27490 )
...
Also adds Hash.Less method for sorting purposes.
---------
Co-authored-by: Felix Lange <fjl@twurst.com>
2023-06-19 23:38:57 +02:00
Sina Mahmoodi
7823ff6d06
eth/tracers: refactor exporting js buffer ( #27472 )
...
We had to do this workaround because it wasn't possible to export typed arrays from
JS to []byte. This was added in dop251/goja@2352993 , so we can use the better way now.
2023-06-14 19:07:24 +02:00
Delweng
8a78a4f79f
eth,consensus: replace noarg fmt.Errorf with errors.New ( #27330 )
...
* eth: replace noarg fmt.Errorf with errors.New
Signed-off-by: jsvisa <delweng@gmail.com>
* consensus: replace noarg fmt.Errorf with errors.New
Signed-off-by: jsvisa <delweng@gmail.com>
---------
Signed-off-by: jsvisa <delweng@gmail.com>
2023-05-25 02:57:34 -04:00
minh-bq
a190da9d68
eth/tracers: fix flatCallTracer crasher ( #27304 )
...
FlatCallTracer had a crasher when it was passed `onlyTopCall: true` as config.
This PR ignores config fields inherited from the normal call tracer.
2023-05-23 11:02:50 +02:00
sjlee1125
604e215d1b
eth/tracers: add txHash field on txTraceResult ( #27183 )
...
This PR modifies the interface for the results of `debug_traceBlock` and `debug_traceCall` by adding the `txHash`, allowing users to identify which transaction's trace result corresponds to.
---------
Co-authored-by: Martin Holst Swende <martin@swende.se>
2023-05-05 08:59:13 -04:00
Sina Mahmoodi
ae66009640
internal/ethapi: add block overrides to eth_call ( #26414 )
...
Adds an optional config parameter to eth_call which allows users to override block context fields (same functionality that was added to traceCall in #24871 )
---------
Co-authored-by: Martin Holst Swende <martin@swende.se>
2023-05-02 04:28:43 -04:00
Péter Szilágyi
bbc565ab05
core/types, params: add blob transaction type, RLP encoded for now ( #27049 )
...
* core/types, params: add blob transaction type, RLP encoded for now
* all: integrate Cancun (and timestamp based forks) into MakeSigner
* core/types: fix 2 back-and-forth type refactors
* core: fix review comment
* core/types: swap blob tx type id to 0x03
2023-04-21 12:52:02 +03:00