Skip to content

Conversation

@micaelae
Copy link
Member

@micaelae micaelae commented Oct 29, 2025

Explanation

Removes all selectedNetworkClientId references:

  • retrieves network client details using the quote request's srcChainId
  • refactors metrics request params utilitgy
  • updates tests/snapshots

References

Part of https://consensyssoftware.atlassian.net/browse/SWAPS-3122

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, highlighting breaking changes as necessary
  • I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes

Note

Removes all selectedNetworkClientId references, deriving network clients via srcChainId, refactors metrics request params, and updates tests/snapshots accordingly.

  • Bridge Controller:
    • Remove selected network usage: delete #getSelectedNetworkClientId/#getSelectedNetworkClient; resolve clients via NetworkController:findNetworkClientIdByChainId in #getNetworkClientByChainId.
    • Use srcChainId-derived client for balance checks and provider config; treat non‑EVM src chains accordingly.
    • Simplify polling input: drop networkClientId from BridgePollingInput and startPolling calls.
  • Metrics:
    • Refactor getRequestParams to take only quoteRequest (no external srcChainId param) with ETH fallback; update all event builders to use new signature.
  • Types:
    • Remove NetworkController:getState from allowed actions and NetworkClientId import/usages.
  • Tests/Snapshots:
    • Update mocks and expectations to remove selectedNetworkClientId; adjust call counts and snapshots; ensure network lookup by chainId.
  • Changelog:
    • Add Fixed note documenting removal of selectedNetworkClientId usages.

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

@micaelae micaelae requested a review from a team as a code owner October 29, 2025 17:38
@micaelae micaelae requested a review from a team as a code owner October 29, 2025 17:48
cursor[bot]

This comment was marked as outdated.

@micaelae micaelae changed the title fix: remove selectedNetworkClientid references in bridge-controller fix: remove all selectedNetworkClientid references in bridge-controller Oct 29, 2025
cursor[bot]

This comment was marked as outdated.

@micaelae micaelae enabled auto-merge (squash) October 29, 2025 18:29
@micaelae micaelae merged commit 1674646 into main Oct 29, 2025
255 checks passed
@micaelae micaelae deleted the swaps-rm-selected-network branch October 29, 2025 18:36
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.

3 participants