Skip to content

chore: wire NEXUS_122 ABI into decoder fallback#211

Open
fichiokaku wants to merge 1 commit into
developfrom
chore/wire-nexus-122-decoder-fallback
Open

chore: wire NEXUS_122 ABI into decoder fallback#211
fichiokaku wants to merge 1 commit into
developfrom
chore/wire-nexus-122-decoder-fallback

Conversation

@fichiokaku
Copy link
Copy Markdown
Collaborator

Summary

The decoder in parse-user-op-calldata.ts tries `NEXUS_120` then `NEXUS_121` but never `NEXUS_122` — the nexus-122.ts ABI was added when Nexus 1.2.2 landed but never wired into the decoder fallback chain. This PR adds the third `try { ... }` branch and updates the trailing log message accordingly.

Behaviour today

`nexus-121.ts` and `nexus-122.ts` are byte-identical (the only diff is the export name), so any calldata that decodes under 121 also decodes under 122. This means the fix is a no-op today — purely forward-compat hygiene.

Why bother

If 122 ever diverges from 121 (e.g. a future Nexus revision adds a new `execute*` function only present in the 122 ABI), the current fallback chain would silently return `undefined` and downstream callers would log "calldata not recognized" on valid UserOps. Wiring 122 now keeps the pattern consistent and avoids that footgun.

Unrelated to MEE v2.2.2

This is orthogonal preparation that should land first, so the v2.2.2 PR is a focused one-line dep bump rather than a mixed change.

Test plan

  • CI green on `develop` base
  • No behavior change expected — existing tests should pass unchanged

The decoder in `parse-user-op-calldata.ts` tried `NEXUS_120` and
`NEXUS_121` but never `NEXUS_122` — the file existed and was committed
when Nexus 1.2.2 landed but was never referenced. Today this is a no-op
because `nexus-121.ts` and `nexus-122.ts` are byte-identical (the only
diff is the export name), so any calldata that decodes against 121 also
decodes against 122. But if 122 ever diverges, the fallback would
silently return `undefined` and downstream callers would log "calldata
not recognized" for valid UserOps.

Forward-compat hygiene only — no behavior change today. Unrelated to
MEE v2.2.2; orthogonal preparation that should land first so the
v2.2.2 PR is a focused one-line dep bump.
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.

1 participant