FuelLabs/fuels-ts · error · FuelError
TRANSACTION_FAILED
TRANSACTION_FAILED
Error message
Failed to deploy predicate chunk
What it means
Thrown by deployScriptOrPredicate()'s waitForResult when the blob transaction (uploading a predicate/script chunk) either rejects during sendTransaction/waitForResult or completes with a status other than TransactionStatus.success. The original error is swallowed and re-thrown as a generic TRANSACTION_FAILED, so the underlying cause is not exposed.
Source
Thrown at packages/account/src/utils/deployScriptOrPredicate.ts:88
return {
waitForResult: () => Promise.resolve(loaderInstance),
blobId,
};
}
const fundedBlobRequest = await fundBlobTx(deployer, blobTxRequest);
// Transaction id is unset until we have funded the create tx, which is dependent on the blob tx
const waitForResult = async () => {
try {
const blobTx = await deployer.sendTransaction(fundedBlobRequest);
const result = await blobTx.waitForResult();
if (result.status !== TransactionStatus.success) {
throw new Error();
}
} catch (err: unknown) {
throw new FuelError(ErrorCode.TRANSACTION_FAILED, 'Failed to deploy predicate chunk');
}
return loaderInstance;
};
return {
waitForResult,
blobId,
};
}
View on GitHub (pinned to b3f37c91ac)
Solutions
- Ensure the deployer account has sufficient base-asset funds to cover the blob transaction fee.
- Confirm the provider/node is reachable and synced before retrying.
- Check the node's logs for the actual rejection reason (the SDK discards the original error message).
- If the blob already exists, the code short-circuits before submission — verify getBlobs behavior if you suspect a stale state.
- Retry with an updated gas price if the failure was due to underpricing.
Defensive patterns
Strategy: retry
Validate before calling
const balance = await deployer.getBalance(baseAssetId);
if (balance.eq(0)) throw new Error('Deployer has no base asset for blob tx fee'); Try / catch
let lastErr: unknown;
for (let attempt = 0; attempt < 3; attempt++) {
try { return await deployment.waitForResult(); }
catch (err) {
lastErr = err;
if (err instanceof FuelError && err.code === ErrorCode.TRANSACTION_FAILED) continue;
throw err;
}
}
throw lastErr; Prevention
- Fund the deployer account adequately before deployment.
- Inspect node logs since the SDK discards the underlying blob-tx error.
- Use a stable gas-price strategy to avoid underpriced txs.
When it happens
Trigger: Calling waitForResult() on the object returned by deployScriptOrPredicate (used when deploying large predicates/scripts as blobs). Triggers include: network/provider errors, insufficient funds to pay the blob tx fee, the node rejecting the blob, or the transaction being committed with a non-success terminal status.
Common situations: Deployer account underfunded for blob gas; node connection drops mid-submission; deploying a malformed/oversized blob; chain_id or consensus parameter mismatch; the blob was already uploaded and a duplicate submission conflicts; gas price spike causing the funded tx to be underpriced.
Related errors
- TRANSACTION_FAILED
- TRANSACTION_SQUEEZED_OUT
- TRANSACTION_NOT_FOUND
- Data section offset is out of bounds, offset: ${offset}, bin
- Contract not found!
AI-assisted analysis of FuelLabs/fuels-ts@b3f37c91ac (2026-08-12).
Data as JSON: /api/errors/38f93ad19bba3b28.
Report an issue: GitHub.