Skip to content

Commit

Permalink
save
Browse files Browse the repository at this point in the history
  • Loading branch information
AskAlexSharov committed Oct 16, 2024
1 parent e1fdf20 commit 80c316c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion internal/erigon_node/bodies_download.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ func (c *NodeClient) BodiesDownload(ctx context.Context, w http.ResponseWriter)
return item.Id < bd.BlockNum+VisLimit // We limit visualisation to VisLimit first blocks
})
//if err := templ.ExecuteTemplate(w, "body_download.html", bd); err != nil {
// fmt.Fprintf(w, "Executing body_download template: %v", err)
// fmt.Fprintf(w, "Executing body_download template: %w", err)
// return
//}
}*/
Expand Down
2 changes: 1 addition & 1 deletion internal/erigon_node/headers_download.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ func (c *NodeClient) HeadersDownload(ctx context.Context, w http.ResponseWriter)
return item.Id < hd.HeaderNum+VisLimit // We limit visualisation to VisLimit first blocks
})
//if err := templ.ExecuteTemplate(w, "headers_download.html", hd); err != nil {
// fmt.Fprintf(w, "Executing headers_download template: %v", err)
// fmt.Fprintf(w, "Executing headers_download template: %w", err)
// return
//}
}*/
6 changes: 3 additions & 3 deletions internal/erigon_node/sync_stages.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func (c *NodeClient) FindSyncStages(ctx context.Context) (SyncStageProgress, err

func (ss *SyncStages) fetchSyncStageProgress(ctx context.Context) (SyncStageProgress, error) {
if cursorError := ss.rc.Init(ctx, syncStageDb, syncStageTable, nil); cursorError != nil {
return nil, fmt.Errorf("could not initialize remote cursor: %v", cursorError)
return nil, fmt.Errorf("could not initialize remote cursor: %w", cursorError)
}

syncStageProgress := make(SyncStageProgress)
Expand All @@ -46,13 +46,13 @@ func (ss *SyncStages) fetchSyncStageProgress(ctx context.Context) (SyncStageProg
syncProgress, unmarshalError := ss.unmarshal(v)

if unmarshalError != nil {
return nil, fmt.Errorf("could not unmarshal sync stage data: %v", unmarshalError)
return nil, fmt.Errorf("could not unmarshal sync stage data: %w", unmarshalError)
}

syncStageProgress[syncStage] = strconv.FormatUint(syncProgress, syncProgressBase)
}
if e != nil {
return nil, fmt.Errorf("could not process remote cursor line: %v", e)
return nil, fmt.Errorf("could not process remote cursor line: %w", e)
}

return syncStageProgress, nil
Expand Down

0 comments on commit 80c316c

Please sign in to comment.