-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Conversation
@@ -325,6 +327,15 @@ impl Engine for Ethash { | |||
fn verify_transaction(&self, t: &SignedTransaction, _header: &Header) -> Result<(), Error> { | |||
t.sender().map(|_|()) // Perform EC recovery and cache sender | |||
} | |||
|
|||
fn is_new_best_block(&self, best_total_difficulty: U256, _best_header: HeaderView, parent_details: &BlockDetails, new_header: &HeaderView) -> bool { | |||
is_new_best_block(best_total_difficulty, parent_details, new_header) |
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.
The same as default, but kept to be explicit.
nice! I wonder if in the future it'll be feasible to extend this abstraction even to stuff like difficulty which is only relevant to PoW. This would require a strong database abstraction and to extend Engine into something which specifies block layout beyond just the seal. |
Yep, that would be nice (and will probably need to be done). Currently all additional info has to be stuffed into the seal. |
Changes Unknown when pulling 53b479f on engine-block-ordering into ** on master**. |
this still compiles with IPC enabled, right? |
Ah, you are right |
Actually it was broken before this PR. |
I broke it earlier with #2935 and also the Preparing workarounds. The codegen implementation could really use some love... |
New method on
Engine
that letsBlockchain
know about the ordering. #3489