Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
exchain
nebula
Commits
cc3ab77c
Commit
cc3ab77c
authored
Dec 07, 2022
by
Matthew Slipper
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
op-wheel: Insert receipts
parent
31fb2b9a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
cheat.go
op-wheel/cheat/cheat.go
+4
-0
No files found.
op-wheel/cheat/cheat.go
View file @
cc3ab77c
...
@@ -124,6 +124,10 @@ func (ch *Cheater) RunAndClose(fn HeadFn) error {
...
@@ -124,6 +124,10 @@ func (ch *Cheater) RunAndClose(fn HeadFn) error {
// using Clique consensus, which causes a panic.
// using Clique consensus, which causes a panic.
rawdb
.
WriteTd
(
batch
,
blockHash
,
preBlock
.
NumberU64
(),
ch
.
Blockchain
.
GetTd
(
preBlock
.
Hash
(),
preBlock
.
NumberU64
()))
rawdb
.
WriteTd
(
batch
,
blockHash
,
preBlock
.
NumberU64
(),
ch
.
Blockchain
.
GetTd
(
preBlock
.
Hash
(),
preBlock
.
NumberU64
()))
// Need to copy over receipts since they are keyed by block hash.
receipts
:=
rawdb
.
ReadReceipts
(
ch
.
DB
,
preBlock
.
Hash
(),
preBlock
.
NumberU64
(),
ch
.
Blockchain
.
Config
())
rawdb
.
WriteReceipts
(
batch
,
blockHash
,
preBlock
.
NumberU64
(),
receipts
)
// Geth maintains an internal mapping between block bodies and their hashes. None of the database
// Geth maintains an internal mapping between block bodies and their hashes. None of the database
// accessors above update this mapping, so we need to do it manually.
// accessors above update this mapping, so we need to do it manually.
oldKey
:=
blockBodyKey
(
preBlock
.
NumberU64
(),
preBlock
.
Hash
())
oldKey
:=
blockBodyKey
(
preBlock
.
NumberU64
(),
preBlock
.
Hash
())
...
...
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