Skip to content

Comments

feat: add NetworkUpgradeTxns library#686

Merged
0xiamflux merged 1 commit intosc-feat/l2cm-nut-libraryfrom
feat/l2cm-nut-library
Nov 14, 2025
Merged

feat: add NetworkUpgradeTxns library#686
0xiamflux merged 1 commit intosc-feat/l2cm-nut-libraryfrom
feat/l2cm-nut-library

Conversation

@0xiamflux
Copy link

@0xiamflux 0xiamflux commented Nov 14, 2025

Note

Introduce a Solidity library to build/serialize network upgrade transactions (NUT) and add tests, including Ecotone vectors and JSON roundtrip.

  • Libraries:
    • Add packages/contracts-bedrock/src/libraries/NetworkUpgradeTxns.sol providing:
      • NetworkUpgradeTxn struct mirroring DepositTx fields.
      • newTx to construct tx metadata with intent-derived sourceHash.
      • sourceHash domain-separated hashing (domain=2).
      • JSON IO: writeArtifact, serializeTxn, readArtifact using Foundry Vm.
  • Tests:
    • Add packages/contracts-bedrock/test/libraries/NetworkUpgradeTxns.t.sol with:
      • Source-hash vector checks against Ecotone intents.
      • newTx field mapping property test.
      • Artifact write/read tests (empty, single, multi-tx).
      • Full Ecotone upgrade roundtrip including proxy upgrades and EIP-4788 deployment.

Written by Cursor Bugbot for commit e752a31. This will update automatically on new commits. Configure here.

@0xiamflux 0xiamflux requested a review from 0xOneTony November 14, 2025 19:29
@0xiamflux 0xiamflux self-assigned this Nov 14, 2025
@0xiamflux 0xiamflux merged commit e76a6a4 into sc-feat/l2cm-nut-library Nov 14, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants