ethereum-optimism / op-geth

GNU Lesser General Public License v3.0
280 stars 735 forks source link

Make L1BlobBaseFee an interface{} during version transition #327

Closed axelKingsley closed 1 month ago

axelKingsley commented 3 months ago

A quick attempt at allowing marshal/unmarshal of Receipts, regardless of the format of L1BlobBaseFee. Uses interface{}, which remains opaque throughout, and must be type-cast to be used.

Testing

op-node passes CI with this: https://github.com/ethereum-optimism/optimism/pull/10706

Context

My understanding of the problem:

When a given L2 node is connecting to L1, it uses Exported definitions in op-geth. Normally, this means that a consistent Node:Execution pairing are always on the same api. However, in the case of L3s or other utilities that build on-top of L2, the version of their node must now also match the L2 host they are connecting to. This locked compatibility currently requires a brief outage for >L2 infrastructure, as the only mutually compatible versioning between OP-Node 1.7.5 and OP-Node 1.7.6 is to have both sides upgrade in lock-step.

By abstracting out the L1BlobBaseFee into an interface{}, either format of this field should marshal.

Caveat

I am not sure if this is the direction we would want this fix to go, as I am uncertain of the downstream impacts of this change. There is a failing unit test related to this change which may indicate that this is not correctly done.

sebastianst commented 1 month ago

This is no longer relevant, latest op-node and op-geth version are compatible.