Skip to content

fix(transaction-controller): recognize Ink networks for Optimism L1 gas fees - #10707

Merged
gabrieledm merged 2 commits into
mainfrom
fix/WPN-2183_ink-activity-fails-while-trying-to-max-send-for-ink-native-token-eth
Oct 8, 2026
Merged

gabrieledm merged 2 commits into
mainfrom
fix/WPN-2183_ink-activity-fails-while-trying-to-max-send-for-ink-native-token-eth

Conversation

@gabrieledm

@gabrieledm gabrieledm commented Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

Explanation

Ink is an OP Stack network, so native-token transactions include an L1 data fee obtained through OptimismLayer1GasFeeFlow.

The flow checks the remote gas API for supported OP Stack networks and uses a static list as a fallback.
Ink Mainnet and Ink Sepolia were missing from that fallback list.
When the remote API was unavailable or did not include Ink, the flow did not match Ink transactions and the L1 gas fee was not estimated.
Consumers calculating a maximum native-token send could therefore omit the L1 fee and produce a transaction whose value plus fees exceeded the account balance.

This change adds the chain IDs for Ink Mainnet (0xdef1) and Ink Sepolia (0xba5ed) and registers both with the existing OP Stack fallback.
It reuses the existing L1 gas oracle flow without introducing Ink-specific fee calculation logic.

Tests verify that both Ink networks are recognized when the remote supported-networks request fails.

References

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

Note

Low Risk
Small, additive chain-ID and fallback-list change in gas fee matching with tests; no auth or payment logic touched.

Overview
Treats Ink Mainnet (0xdef1) and Ink Sepolia (0xba5ed) as OP Stack chains for Layer 1 gas fee estimation.

Adds CHAIN_IDS.INK and CHAIN_IDS.INK_SEPOLIA and includes them in OptimismLayer1GasFeeFlow’s FALLBACK_OPTIMISM_STACK_CHAIN_IDS, so matchesTransaction routes Ink transactions through the Optimism L1 oracle flow when the remote gas API list is missing or does not list the chain. Tests cover the remote-fetch-failure fallback path for both Ink networks; the changelog documents the fix.

Reviewed by Cursor Bugbot for commit 8f27ec7. Bugbot is set up for automated code reviews on this repo. Configure here.

@gabrieledm
gabrieledm requested review from a team as code owners October 7, 2026 19:12
@gabrieledm
gabrieledm deployed to default-branch October 7, 2026 19:13 — with GitHub Actions Active
@gabrieledm
gabrieledm added this pull request to the merge queue Oct 8, 2026
Merged via the queue into main with commit 8b1ecab Oct 8, 2026
115 checks passed
@gabrieledm
gabrieledm deleted the fix/WPN-2183_ink-activity-fails-while-trying-to-max-send-for-ink-native-token-eth branch October 8, 2026 12:33
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