Skip to content

Commit

Permalink
ethstats: report block nonce to ethstats
Browse files Browse the repository at this point in the history
  • Loading branch information
Zergity committed Oct 1, 2019
1 parent 46fb6d4 commit 5c9cc8b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ethstats/ethstats.go
Original file line number Diff line number Diff line change
Expand Up @@ -476,6 +476,7 @@ type blockStats struct {
Miner common.Address `json:"miner"`
GasUsed uint64 `json:"gasUsed"`
GasLimit uint64 `json:"gasLimit"`
Nonce uint64 `json:"nonce"`
Diff string `json:"difficulty"`
TotalDiff string `json:"totalDifficulty"`
Txs []txStats `json:"transactions"`
Expand Down Expand Up @@ -593,6 +594,7 @@ func (s *Service) assembleBlockStats(block *types.Block) *blockStats {
Miner: author,
GasUsed: header.GasUsed,
GasLimit: header.GasLimit,
Nonce: header.Nonce.Uint64(),
Diff: header.Difficulty.String(),
TotalDiff: td.String(),
Txs: txs,
Expand Down

0 comments on commit 5c9cc8b

Please sign in to comment.