cmd/geth, eth, core: snapshot dump + unify with trie dump (#22795)

* cmd/geth, eth, core: snapshot dump + unify with trie dump

* cmd/evm: dump API fixes

* cmd/geth, core, eth: fix some remaining errors

* cmd/evm: dump - add limit, support address startkey, address review concerns

* cmd, core/state, eth: minor polishes, fix snap dump crash, unify format

Co-authored-by: Péter Szilágyi <peterke@gmail.com>
This commit is contained in:
Martin Holst Swende
2021-05-12 10:05:39 +02:00
committed by GitHub
parent 1cca781a02
commit addd8824cf
10 changed files with 300 additions and 95 deletions

View File

@ -184,7 +184,7 @@ var (
Name: "exitwhensynced",
Usage: "Exits after block synchronisation completes",
}
IterativeOutputFlag = cli.BoolFlag{
IterativeOutputFlag = cli.BoolTFlag{
Name: "iterative",
Usage: "Print streaming JSON iteratively, delimited by newlines",
}
@ -200,6 +200,16 @@ var (
Name: "nocode",
Usage: "Exclude contract code (save db lookups)",
}
StartKeyFlag = cli.StringFlag{
Name: "start",
Usage: "Start position. Either a hash or address",
Value: "0x0000000000000000000000000000000000000000000000000000000000000000",
}
DumpLimitFlag = cli.Uint64Flag{
Name: "limit",
Usage: "Max number of elements (0 = no limit)",
Value: 0,
}
defaultSyncMode = ethconfig.Defaults.SyncMode
SyncModeFlag = TextMarshalerFlag{
Name: "syncmode",