{"record":{"id":"64d5ff3ec2dd32ac","repo":"unionlabs/union","slug":"simulation-result-not-found","errorCode":null,"errorMessage":"simulation result not found","messagePattern":"simulation result not found","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"typescript-sdk/src/aptos/transfer.ts","lineNumber":97,"sourceCode":"    args.aptos.transaction.submit.simple({\n      transaction: args.transaction,\n      senderAuthenticator: args.accountAuthenticator,\n    }),\n  error => new Error(`Submit simple transaction failed`, { cause: error }),\n)\n\nconst simulateSimpleTransaction: (args: {\n  aptos: Aptos\n  signerPublicKey: PublicKey\n  transaction: AnyRawTransaction\n}) => ResultAsync<UserTransactionResponse, Error> = ResultAsync.fromThrowable(\n  async args => {\n    const [simulationResult] = await args.aptos.transaction.simulate.simple({\n      transaction: args.transaction,\n      signerPublicKey: args.signerPublicKey,\n    })\n    if (!simulationResult?.success) {\n      throw new Error(\"simulation result not found\")\n    }\n    return simulationResult\n  },\n  error => new Error(`Simulate simple transaction failed`, { cause: error }),\n)\n\nexport const transferAssetFromAptos: (args: AptosTransferParams) => ResultAsync<string, Error> =\n  ResultAsync.fromThrowable(\n    async parameters => {\n      const payload = {\n        function: `${parameters.relayContractAddress}::ibc::send`,\n        typeArguments: [],\n        functionArguments: [\n          parameters.sourceChannel,\n          isValidBech32Address(parameters.receiver)\n            ? bech32AddressToHex({ address: parameters.receiver })\n            : parameters.receiver,\n          [parameters.denomAddress],","sourceCodeStart":79,"sourceCodeEnd":115,"githubUrl":"https://github.com/unionlabs/union/blob/031785bb6dc6b957c624e62bc64c184409c97d7b/typescript-sdk/src/aptos/transfer.ts#L79-L115","documentation":"Thrown by simulateSimpleTransaction when the Aptos SDK's transaction.simulate.simple returns no first element or a result whose success flag is falsy. Simulation executes the transaction against the current ledger state without submitting it, so this error means the Move code would abort if submitted (or the node returned an empty simulation array).","triggerScenarios":"Simulating a transfer payload (e.g. relayContractAddress::ibc::send or fungible transfer) where execution aborts: wrong argument types/counts, insufficient balance, resource errors, or an unreachable/legacy RPC node that returns an empty simulation result.","commonSituations":"Cross-chain transfer previews that simulate before signing; a signer public key that does not match the funding account; denom address with no fungible store for the signer; testnet/fullnode endpoints that behave differently than mainnet.","solutions":["Inspect the simulation result's vm_status (log the full array returned by simulate.simple) to find the abort reason","Make sure the simulated signer has the asset and gas balance the real signer would have","Check the payload's function path, typeArguments, and argument order against the deployed contract","Point the client at a healthy fullnode (https://fullnode.mainnet.aptoslabs.com/v1 or a paid provider)"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"const [simulation] = await aptos.transaction.simulate.simple({\n  transaction,\n  signerPublicKey,\n})\nif (!simulation?.success) {\n  console.warn(\"simulation aborted:\", simulation?.vm_status ?? \"no result\")\n  // fix payload/balance before signing the real transaction\n}","typeGuard":null,"tryCatchPattern":"try {\n  await simulateTransfer(params).toPromise()\n} catch (error) {\n  if ((error as Error).message.includes(\"simulation result not found\")) {\n    // run a raw simulate.simple to read vm_status and correct arguments/balance\n  }\n  throw error\n}","preventionTips":["Run your own simulate.simple call and log vm_status before signing","Ensure the simulated signer mirrors the real signer's balances","Keep payloads aligned with the deployed contract ABI (function path, type args, arg order)"],"tags":["aptos","simulation","transaction","typescript-sdk"],"backgroundTag":null,"analyzedSha":"031785bb6dc6b957c624e62bc64c184409c97d7b","analyzedAt":"2026-08-16T06:24:09.996Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}