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
cd0e9417
Unverified
Commit
cd0e9417
authored
Apr 11, 2023
by
Michael de Hoog
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check for start > end too
parent
fe7f5b49
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
9 deletions
+7
-9
driver.go
op-batcher/batcher/driver.go
+7
-9
No files found.
op-batcher/batcher/driver.go
View file @
cd0e9417
...
@@ -191,7 +191,7 @@ func (l *BatchSubmitter) loadBlocksIntoState(ctx context.Context) {
...
@@ -191,7 +191,7 @@ func (l *BatchSubmitter) loadBlocksIntoState(ctx context.Context) {
if
err
!=
nil
{
if
err
!=
nil
{
l
.
log
.
Warn
(
"Error calculating L2 block range"
,
"err"
,
err
)
l
.
log
.
Warn
(
"Error calculating L2 block range"
,
"err"
,
err
)
return
return
}
else
if
start
.
Number
=
=
end
.
Number
{
}
else
if
start
.
Number
>
=
end
.
Number
{
return
return
}
}
...
@@ -212,15 +212,13 @@ func (l *BatchSubmitter) loadBlocksIntoState(ctx context.Context) {
...
@@ -212,15 +212,13 @@ func (l *BatchSubmitter) loadBlocksIntoState(ctx context.Context) {
latestBlock
=
block
latestBlock
=
block
}
}
if
latestBlock
!=
nil
{
l2ref
,
err
:=
derive
.
L2BlockToBlockRef
(
latestBlock
,
&
l
.
Rollup
.
Genesis
)
l2ref
,
err
:=
derive
.
L2BlockToBlockRef
(
latestBlock
,
&
l
.
Rollup
.
Genesis
)
if
err
!=
nil
{
if
err
!=
nil
{
l
.
log
.
Warn
(
"Invalid L2 block loaded into state"
,
"err"
,
err
)
l
.
log
.
Warn
(
"Invalid L2 block loaded into state"
,
"err"
,
err
)
return
return
}
l
.
metr
.
RecordL2BlocksLoaded
(
l2ref
)
}
}
l
.
metr
.
RecordL2BlocksLoaded
(
l2ref
)
}
}
// loadBlockIntoState fetches & stores a single block into `state`. It returns the block it loaded.
// loadBlockIntoState fetches & stores a single block into `state`. It returns the block it loaded.
...
...
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