Skip to content

opgeth-decoupling: swap DepositTx construction + Transaction-method helpers in op-node #20269

Closed

Description

@sebastianst

Part of #20263 → #20257. See plan §1, §2 in the op-geth decoupling doc.

Strategy

Swap op-node (and remaining op-service/op-batcher) DepositTx construction/decoding and fork Transaction-method calls to op-core/types / op-core/fees:

  • types.NewTx(&types.DepositTx{...}).MarshalBinary() → optypes.DepositTx{...}.MarshalBinary() — struct straight to bytes, the *types.Transaction wrapper is eliminated. UnmarshalDepositLogEvent returns *optypes.DepositTx.
  • Fork Transaction methods → op-core helpers: tx.IsDepositTx() → optypes.IsDepositTx(tx); tx.SourceHash() / tx.Mint() / tx.IsSystemTx() → decode via optypes.UnmarshalDepositTx and read fields; tx.RollupCostData() → opfees.TxRollupCostData(tx). These helpers are transition scaffolding, deleted at the cutover (doc §2).

Derive the current call-site list by grep (types\.DepositTx{, the method names above on go-ethereum types) — sites cluster in op-node derivation (one *_upgrade_transactions.go per fork; the set grows with every fork) and interop indexing. Don't trust any snapshot list.

Acceptance criteria

  • No in-scope package constructs or decodes go-ethereum's types.DepositTx or calls the fork Transaction methods; a grep over the go-ethereum import is clean outside op-core.
  • Behaviour unchanged — byte-identical encodings, pinned by the op-core differential tests.

Blocked on: #20262 (done).

🤖 Generated by Claude Code

Activity

  1. self-assigned this
    on Jul 7, 2026
  2. added a commit that references this issue on Jul 15, 2026
    7096301
  3. added a commit that references this issue on Jul 16, 2026
    8b46802
  4. added a commit that references this issue on Sep 19, 2026
    3ea0f14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions