-
Notifications
You must be signed in to change notification settings - Fork 153
Cross-chain gas limits #727
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
base: main
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
📝 WalkthroughWalkthroughRenames “Gas Fees” to “Gas Fees & Limits” in EVM docs metadata and adjusts the gas page: updates front matter title to “Gas”, reflows a sentence, and adds a new “Gas Limits” section with a table describing cross-chain gas limit semantics and per-direction limits. No code or component changes. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests
Tip 👮 Agentic pre-merge checks are now available in preview!Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.
Please see the documentation for more information. Example: reviews:
pre_merge_checks:
custom_checks:
- name: "Undocumented Breaking Changes"
mode: "warning"
instructions: |
Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).Please share your feedback with us on this Discord post. 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 |
| | Outgoing to EVM | 2.5M | [Source](https://github.com/zeta-chain/node/blob/835341df/zetaclient/chains/evm/signer/gas.go) | | ||
| | Outgoing to EVM (revert) | 2M | [Source](https://github.com/zeta-chain/protocol-contracts/blob/main/contracts/Revert.sol) | |
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.
These values are not correct, users choose the fees and pay for it. But the default values are not the same neither.
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.
Yes, I know that users specify gas limits, we can rename these as "max gas limits" or something to specify that this is the max amount you can set (but you can set less).
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.
@lumtis how can we fix this table to provide up-to-date max gas limit values?
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.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
src/pages/developers/evm/gas.mdx (1)
82-90: Replace incorrect Sui source link — use Sui signer fileSui row in src/pages/developers/evm/gas.mdx (lines 82–90) links to the TON outbound file; change it to the Sui signer source (node/zetaclient/chains/sui/signer/signer_tx.go). (github.com)
-| Outgoing to Sui | 50B | [Source](https://github.com/zeta-chain/node/blob/835341df/zetaclient/chains/ton/observer/outbound.go) | +| Outgoing to Sui | 50B | [Source](https://github.com/zeta-chain/node/blob/835341df/zetaclient/chains/sui/signer/signer_tx.go) |
🧹 Nitpick comments (5)
src/pages/developers/evm/_meta.json (1)
15-17: Update description to reflect new scope.The page now covers gas limits; include that in the description.
- "description": "Learn about ZRC-20 withdraw fees, message passing fees" + "description": "Learn about ZRC-20 withdraw fees, message passing fees, and cross-chain gas limits"src/pages/developers/evm/gas.mdx (4)
69-74: Fix grammar in the fees command sentence.-To calculate fees for a different gas limit, please, check out use the `query fees` command: +To calculate fees for a different gas limit, use the query fees command:
75-81: Add freshness qualifier.Gas limits are operational parameters; add an “as of ” note to reduce staleness risk.
Gas limits set the upper bound for how much computation a cross-chain transaction can use. They’re defined per direction (incoming or outgoing) to make sure calls have enough room to execute reliably. The values may change as the network evolves. +As of September 15, 2025. Limits may change without notice; always verify before deployment.
82-90: Pin all GitHub sources to immutable commits.Revert.sol uses the “main” branch and can drift. Pin to a commit like the node links.
-| Outgoing to EVM (revert) | 2M | [Source](https://github.com/zeta-chain/protocol-contracts/blob/main/contracts/Revert.sol) | +| Outgoing to EVM (revert) | 2M | [Source](https://github.com/zeta-chain/protocol-contracts/blob/<commit>/contracts/Revert.sol) |
82-90: Clarify units per chain.“Gas” vs “compute units” vs chain-specific units can confuse readers; add a short note below the table.
| Outgoing to Solana | 1.6M | [Source](https://github.com/zeta-chain/node/blob/835341df/zetaclient/chains/solana/signer/signer.go) | +Note: Units vary by chain. EVM rows are in gas units; Solana is in compute units; Sui uses Sui gas units. These are upper bounds enforced by ZetaChain clients and may differ from user-specified gas limits or budgets on destination chains.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
Disabled knowledge base sources:
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (2)
src/pages/developers/evm/_meta.json(1 hunks)src/pages/developers/evm/gas.mdx(2 hunks)
⏰ 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)
- GitHub Check: build
🔇 Additional comments (4)
src/pages/developers/evm/_meta.json (1)
15-15: Rename approved.Sidebar label “Gas Fees & Limits” is clearer. Ensure internal links or references (if any) weren’t hardcoding the old title.
src/pages/developers/evm/gas.mdx (3)
2-2: Title change is fine; verify nav consistency.Front matter is “Gas” while sidebar is “Gas Fees & Limits”. If intentional, leave as-is; otherwise align for consistency in breadcrumbs/SEO.
84-84: Validate “Incoming to ZetaChain” reference.The LCD “system_contract” endpoint may not directly document the 1.6M limit. Consider linking to the code or a parameter source that explicitly sets this limit.
88-88: Double‑check Sui limit magnitude and unit.“50B” is unusually large. Confirm the correct unit and value; if accurate, annotate units (e.g., “50B gas units”) or convert to a consistent notation.
hernan-clich
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.
Concept ACK
Summary by CodeRabbit