Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
bfa0f968
Commit
bfa0f968
authored
Oct 04, 2018
by
cdetrio
Committed by
Martin Holst Swende
Oct 04, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmd/evm: fix state dump (#17832)
parent
82a1c771
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
staterunner.go
cmd/evm/staterunner.go
+4
-4
No files found.
cmd/evm/staterunner.go
View file @
bfa0f968
...
@@ -97,6 +97,10 @@ func stateTestCmd(ctx *cli.Context) error {
...
@@ -97,6 +97,10 @@ func stateTestCmd(ctx *cli.Context) error {
// Run the test and aggregate the result
// Run the test and aggregate the result
result
:=
&
StatetestResult
{
Name
:
key
,
Fork
:
st
.
Fork
,
Pass
:
true
}
result
:=
&
StatetestResult
{
Name
:
key
,
Fork
:
st
.
Fork
,
Pass
:
true
}
state
,
err
:=
test
.
Run
(
st
,
cfg
)
state
,
err
:=
test
.
Run
(
st
,
cfg
)
// print state root for evmlab tracing
if
ctx
.
GlobalBool
(
MachineFlag
.
Name
)
&&
state
!=
nil
{
fmt
.
Fprintf
(
os
.
Stderr
,
"{
\"
stateRoot
\"
:
\"
%x
\"
}
\n
"
,
state
.
IntermediateRoot
(
false
))
}
if
err
!=
nil
{
if
err
!=
nil
{
// Test failed, mark as so and dump any state to aid debugging
// Test failed, mark as so and dump any state to aid debugging
result
.
Pass
,
result
.
Error
=
false
,
err
.
Error
()
result
.
Pass
,
result
.
Error
=
false
,
err
.
Error
()
...
@@ -105,10 +109,6 @@ func stateTestCmd(ctx *cli.Context) error {
...
@@ -105,10 +109,6 @@ func stateTestCmd(ctx *cli.Context) error {
result
.
State
=
&
dump
result
.
State
=
&
dump
}
}
}
}
// print state root for evmlab tracing (already committed above, so no need to delete objects again
if
ctx
.
GlobalBool
(
MachineFlag
.
Name
)
&&
state
!=
nil
{
fmt
.
Fprintf
(
os
.
Stderr
,
"{
\"
stateRoot
\"
:
\"
%x
\"
}
\n
"
,
state
.
IntermediateRoot
(
false
))
}
results
=
append
(
results
,
*
result
)
results
=
append
(
results
,
*
result
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment