-
Notifications
You must be signed in to change notification settings - Fork 198
feat: sui transaction parsing #11451
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Cetus swaps from SUI are currently broken with a wallet connected but work without a wallet connected. The issue is that native SUI transfers were incorrectly treated as token transfers, requiring getCoins() lookup which fails. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Exclude HAEDALPMM, HAEDALHMMV2, and METASTABLE providers from Cetus route finding to avoid failures when Pyth oracle's public endpoint is unavailable. These providers require Pyth price feeds for transaction construction. Still uses CETUS, TURBOS, BLUEFIN, FLOWX, DEEPBOOK, HAEDAL, OBRIC, STEAMM, and other non-Pyth providers for reliable quotes. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Implements transaction parsing for SUI to display actual execution prices and transfer details. Parses: - Native SUI and token transfers from balanceChanges - Transaction status (success/failure) - Gas fees (computation + storage - rebate) - Transfer types (Send/Receive/Contract) - Confirmations from checkpoint data Handles same-address swaps, token swaps, and cross-chain bridge receives. Closes #11427 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
📝 WalkthroughWalkthroughThe pull request implements full SUI transaction parsing by adding a new Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20-25 minutes
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: Organization UI Review profile: CHILL Plan: Pro Disabled knowledge base sources:
📒 Files selected for processing (1)
🧰 Additional context used📓 Path-based instructions (3)**/*.{ts,tsx,js,jsx}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
**/*.{ts,tsx}📄 CodeRabbit inference engine (CLAUDE.md)
Files:
**/*.{js,jsx,ts,tsx}📄 CodeRabbit inference engine (.cursor/rules/naming-conventions.mdc)
Files:
🧠 Learnings (20)📓 Common learnings📚 Learning: 2025-12-17T14:50:01.629ZApplied to files:
📚 Learning: 2025-11-24T21:20:57.909ZApplied to files:
📚 Learning: 2025-12-09T21:07:22.474ZApplied to files:
📚 Learning: 2025-11-24T21:20:04.979ZApplied to files:
📚 Learning: 2025-11-24T21:20:57.909ZApplied to files:
📚 Learning: 2025-11-24T21:20:57.909ZApplied to files:
📚 Learning: 2025-11-24T21:20:57.909ZApplied to files:
📚 Learning: 2025-11-24T21:20:57.909ZApplied to files:
📚 Learning: 2025-12-04T22:57:50.850ZApplied to files:
📚 Learning: 2025-12-04T11:05:01.146ZApplied to files:
📚 Learning: 2025-10-21T17:12:47.282ZApplied to files:
📚 Learning: 2025-08-05T16:39:58.598ZApplied to files:
📚 Learning: 2025-09-12T12:04:59.556ZApplied to files:
📚 Learning: 2025-08-05T23:36:13.214ZApplied to files:
📚 Learning: 2025-12-09T21:06:15.748ZApplied to files:
📚 Learning: 2025-10-23T14:27:19.073ZApplied to files:
📚 Learning: 2025-10-01T07:42:40.195ZApplied to files:
📚 Learning: 2025-11-19T16:59:50.569ZApplied to files:
📚 Learning: 2025-08-22T12:58:26.590ZApplied to files:
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🔇 Additional comments (5)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
packages/swapper/src/swappers/CetusSwapper/swapperApi/getCetusTradeData.ts
Show resolved
Hide resolved
NeOMakinG
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://jam.dev/c/e660eeaa-32ea-4a7a-b60f-8d3fb97c9310
Looks like working well
Resolved merge conflict in getCetusTradeData.ts - kept getProvidersExcluding import from feature branch.
Fixes merge conflict artifacts where PYTH_DEPENDENT_PROVIDERS was both imported and redefined locally in endpoints.ts and getCetusTradeData.ts. The constant is already properly exported from utils/constants.ts. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Description
Implements transaction parsing for SUI chain adapter to display actual execution prices and transfer details.
Parses:
Handles same-address swaps, token swaps, and cross-chain bridge receives.
Issue (if applicable)
closes #11427
Risk
Low - isolated to SUI chain adapter, follows established patterns from EVM/Tron/Solana parseTx implementations.
SUI swaps and transfers - users will now see actual execution prices instead of estimates.
Testing
Engineering
Operations
🏁 My feature is behind a flag and doesn't require operations testing (yet)
Verify swap completion screens show accurate amounts
Screenshots (if applicable)
https://jam.dev/c/9aa9fe48-5d4b-4129-839c-47ee41506fc5
Summary by CodeRabbit
Release Notes
✏️ Tip: You can customize this high-level summary in your review settings.