-
Notifications
You must be signed in to change notification settings - Fork 20k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
eth: add GasPriceOracle #990
Conversation
@@ -419,7 +422,25 @@ func (self *ChainManager) GetBlock(hash common.Hash) *types.Block { | |||
glog.V(logger.Error).Infof("invalid block RLP for hash %x: %v", hash, err) | |||
return nil | |||
} | |||
return (*types.Block)(&block) | |||
|
|||
blk := (*types.Block)(&block) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be moved to its own separate function. We want to limit the amount of database gets and RLP decoding required to get a block. Most cases when GetBlock
is called you don't require the receipts.
Move this to an additional method like
func (cm *ChainManager) GetReceipts(block *types.Block) types.Receipts {
// your code
}
@zsfelfoldi If it's not too much effort, can you add a method to XEth to access the receipts? This would be to support #1042 |
@zsfelfoldi @tgerring as per my question on gitter. Separate the transaction receipt storing in a new PR |
@tgerring Ok, I'll do that later today or tomorrow morning. |
69323ea
to
9182cf7
Compare
Mining just empty blocks:
Shouldn't it dip below 1000...00 ? |
I think it shouldn't (that's the absolute minimum value), see gitter private channel. |
Description Documentations fixes Related issues Fixes ethereum#896
No description provided.