{"record":{"id":"f8e37151be3ca9c6","repo":"FuelLabs/fuel-core","slug":"unable-to-find-any-coins-to-pay-for-the-fee","errorCode":null,"errorMessage":"Unable to find any coins to pay for the fee","messagePattern":"Unable to find any coins to pay for the fee","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/fuel-core/src/schema/tx/assemble_tx.rs","lineNumber":979,"sourceCode":"                    max: self.arguments.consensus_parameters.tx_params().max_inputs(),\n                }\n                .into());\n            }\n\n            let how_much_to_add = need_to_cover.saturating_sub(total_base_asset);\n            let coins = self\n                .arguments\n                .coins(\n                    fee_payer_account.owner(),\n                    base_asset_id,\n                    how_much_to_add,\n                    remaining_input_slots,\n                    true,\n                )\n                .await?;\n\n            if coins.is_empty() {\n                return Err(anyhow::anyhow!(\n                    \"Unable to find any coins to pay for the fee\"\n                ));\n            }\n\n            for coin in coins.into_iter().take(remaining_input_slots as usize) {\n                total_base_asset = total_base_asset.checked_add(coin.amount()).ok_or(\n                    anyhow::anyhow!(\n                        \"The total base asset amount \\\n                        became too big when tried to cover fee\"\n                    ),\n                )?;\n                self.add_input_and_witness_and_change(&fee_payer_account, coin)?;\n            }\n\n            // In the case when predicates iterates over the inputs,\n            // it increases its used gas. So we need to re-estimate predicates.\n            self = self.estimate_predicates().await?;\n        }","sourceCodeStart":961,"sourceCodeEnd":997,"githubUrl":"https://github.com/FuelLabs/fuel-core/blob/b9d4d170da3a31c9ace5f963d633b326348e0d42/crates/fuel-core/src/schema/tx/assemble_tx.rs#L961-L997","documentation":"In the fee-covering loop, when the fee payer's current base-asset inputs are insufficient the assembler queries the node for more spendable base-asset coins (respecting the exclude list). If the query returns no coins at all, there is nothing to pay gas with and assembly aborts.","triggerScenarios":"The fee account (requiredBalances[feeAddressIndex]'s account) has no spendable base-asset coins beyond those already used: empty or drained wallet, all UTXOs excluded via excludeInput, or coins locked/spent in other pending txs.","commonSituations":"Forgot to fund the fee payer; paying gas from an account that only holds non-base assets; over-aggressive excludeInput lists after retries; concurrent submissions spending the same UTXOs.","solutions":["Fund the fee account with base-asset coins and retry","Make requiredBalances[feeAddressIndex] an account that actually holds the base asset","Trim the excludeInput list and avoid submitting conflicting transactions from the same UTXO set concurrently"],"exampleFix":"# before\nnode is unfunded for 0xfee...\n\n# after\nfuels provider fund-wallet 0xfeePayer... # or transfer BASE_ASSET to the fee account\n# then retry the same assembleTransaction call","handlingStrategy":"validation","validationCode":"// confirm the fee account can pay before assembling\nconst bal = await client.request(BALANCE_QUERY(feeAccountAddress, BASE_ASSET));\nconst spendable = BigInt(bal.balance.balanceAmount);\nif (spendable < estimatedFee + reservedBaseAsset) {\n  throw new Error(`fee account short: ${spendable} < ${estimatedFee + reservedBaseAsset}; fund it first`);\n}","typeGuard":null,"tryCatchPattern":"catch (e) { if (/Unable to find any coins to pay for the fee/.test(e.message)) { /* fund the fee payer with base asset, clear stale excludes, retry */ } else throw e; }","preventionTips":["Pre-flight check the fee account's spendable base-asset balance","The fee payer is requiredBalances[feeAddressIndex].account — not necessarily the tx's other accounts","Serialize submissions from one wallet to avoid double-spending the same UTXO pool"],"tags":["fee","insufficient-funds","utxo","wallet","assemble-tx"],"backgroundTag":null,"analyzedSha":"b9d4d170da3a31c9ace5f963d633b326348e0d42","analyzedAt":"2026-08-16T08:56:42.692Z","schemaVersion":2},"datasetVersion":"2026-08-16T13:17:31.715Z"}