Skip to content

Conversation

@tpham-mysten
Copy link
Contributor

Description

Support the same flags that gRPC's simulate transaction supports:

  • checks: enables transaction validation checks during simulation
  • do_gas_selection: enables automatic gas coin selection and budget estimation

Test plan

How did you test the new or updated feature?

cargo nextest run -p sui-indexer-alt-e2e-tests

Release notes

Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required.

For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates.

  • Protocol:
  • Nodes (Validators and Full nodes):
  • gRPC:
  • JSON-RPC:
  • GraphQL: Add support for checks and do_gas_selection argument for query.simulateTransaction
  • CLI:
  • Rust SDK:
  • Indexing Framework:

@vercel
Copy link

vercel bot commented Dec 18, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

2 Skipped Deployments
Project Deployment Review Updated (UTC)
multisig-toolkit Ignored Ignored Dec 18, 2025 2:44am
sui-kiosk Ignored Ignored Dec 18, 2025 2:44am

@tpham-mysten tpham-mysten temporarily deployed to sui-typescript-aws-kms-test-env December 18, 2025 02:44 — with GitHub Actions Inactive
Copy link
Contributor

@amnn amnn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we'll need to approach the test differently to avoid it needing to be changed by folks making unrelated changes, but the core implementation is looking good, thanks @tpham-mysten !

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this stale? It looks like you're using an inline snapshot now.

"status": "SUCCESS",
"transaction": {
"gasInput": {
"gasBudget": "156976000"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even the gas budget may change because of unrelated protocol config or gas model changes. I think it will be best to write a more "E2E" test where we take the output from GraphQL, sign it, execute it, and confirm that this succeeds and the transfer actually happens.

&self,
ctx: &Context<'_>,
transaction: Json,
checks_enabled: Option<bool>,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: thoughts on aligning this with gRPC by calling it checks? I know that in gRPC there is a special enum for this which is perhaps where the Enabled comes from, though. (I don't feel particularly strongly either way, but just noted the difference).

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