Skip to content
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

soroban-rpc: simulateTransaction returning invalid results #20

Open
Shaptic opened this issue Sep 6, 2023 · 1 comment
Open

soroban-rpc: simulateTransaction returning invalid results #20

Shaptic opened this issue Sep 6, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@Shaptic
Copy link
Contributor

Shaptic commented Sep 6, 2023

What version are you using?

https://rpc-futurenet.stellar.org/

What did you do?

Ran simulation of a transaction:

curl -s 'https://rpc-futurenet.stellar.org/' -H 'Content-Type: application/json' --data '{
  "jsonrpc": "2.0",
  "id": 10235,
  "method": "simulateTransaction",
  "params": [ 
    "AAAAAgAAAADzwQ11keCAXiGbzzenrJCF67uR4i8TRh6rq10fRyygkwAAA+gAALIrAAAARQAAAAEAAAAAAAAAAAAAAABk+MefAAAAAAAAAAEAAAAAAAAAGgAAAAAAAAABAAAAAAAAAAAAAAACAAAABzvHl6ljHJiGxSRWVNXrog1BZenOcFxRa/PN/pljigY5AAAAAAAAAAYAAAABO8eXqWMcmIbFJFZU1euiDUFl6c5wXFFr883+mWOKBjkAAAAUAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA"
  ]
}' | jq

The response was:

{
  "jsonrpc": "2.0",
  "id": 10235,
  "result": {
    "transactionData": "AAAAAAAAAAAAAAACAAAABzvHl6ljHJiGxSRWVNXrog1BZenOcFxRa/PN/pljigY5AAAAAAAAAAYAAAABO8eXqWMcmIbFJFZU1euiDUFl6c5wXFFr883+mWOKBjkAAAAUAAAAAQAAAAAAAAAAAAAAzAAAAMwAAAGYAAAAAAAAAFA=",
    "events": null,
    "minResourceFee": "62171",
    "results": [
      {
        "auth": null,
        "xdr": ""
      }
    ],
    "cost": {
      "cpuInsns": "0",
      "memBytes": "0"
    },
    "latestLedger": "771779"
  }
}

(More context on Discord.)

What did you expect to see?

According to the documentation, the results field should not have any optional components, so this should either:

  • include an error field or
  • include valid auth and xdr fields

What did you see instead?

results[0] is not a valid result structure, since xdr is an empty string and auth is null.

@Shaptic
Copy link
Contributor Author

Shaptic commented Sep 6, 2023

I'm almost certain this is fixed in current versions so feel free to just close this as such, but I just want to raise it in case it's not.

@stellarsaur stellarsaur transferred this issue from stellar/stellar-cli Feb 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant