-
Notifications
You must be signed in to change notification settings - Fork 359
fix(precompile): Fix regression where eth_call
can cause non-deterministic gas consumption
#1136
Conversation
9d6095a
to
9a6c42f
Compare
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #1136 +/- ##
==========================================
- Coverage 54.30% 54.22% -0.08%
==========================================
Files 99 99
Lines 5121 5123 +2
==========================================
- Hits 2781 2778 -3
- Misses 2173 2178 +5
Partials 167 167
|
eth_call
can cause issues with block production eth_call
can cause non-deterministic gas consumption
This reverts commit 8104805.
a0e1bf4
to
20a814f
Compare
fwiw, I really hate this design, but it will get us unblocked for testnet |
We can chat monday, but I really think we should just simplify and prevent precompiles from calling back into the EVM. This would reduce so much complexity fromt the precompile plugin and stop just gross interface contagion. I think the fact that the precompile plugin is manually calling the state plugin is a huge antipattern and generally bad practice. Plugins in general, shouldnt need to know about the existance of other plugins. |
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.
Lgtm thanks for addressing it @itsdevbear
You cannot manipulate the canonical state plugin in another plugin since there is no guarantee made about whether it is in a query or a block. Also setting gas consumption in the state plugin is not required, since the context with the updated gas only occurs in the precompile itself.
This can cause non-determinism in gas consumption between nodes.