@volr/react 0.1.24 → 0.1.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +13 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +13 -1
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -18208,6 +18208,17 @@ function extractFailureReason(response) {
|
|
|
18208
18208
|
}
|
|
18209
18209
|
const diag = meta.developerDiagnostics;
|
|
18210
18210
|
if (diag) {
|
|
18211
|
+
const topLevel = diag.topLevel;
|
|
18212
|
+
if (topLevel) {
|
|
18213
|
+
if (typeof topLevel.reason === "string" && topLevel.reason) {
|
|
18214
|
+
reasons.push(topLevel.reason);
|
|
18215
|
+
}
|
|
18216
|
+
if (topLevel.oogSuspected) {
|
|
18217
|
+
reasons.push(
|
|
18218
|
+
"Likely Out-of-gas via VolrInvoker. The transaction consumed almost all provided gas without a clear revert reason."
|
|
18219
|
+
);
|
|
18220
|
+
}
|
|
18221
|
+
}
|
|
18211
18222
|
if (typeof diag.revertReason === "string" && diag.revertReason) {
|
|
18212
18223
|
reasons.push(diag.revertReason);
|
|
18213
18224
|
}
|
|
@@ -18252,12 +18263,13 @@ async function pollTransactionStatus(txId, client, maxAttempts = 60, intervalMs
|
|
|
18252
18263
|
if (meta) {
|
|
18253
18264
|
console.error("[pollTransactionStatus] Full meta:", JSON.stringify(meta, null, 2));
|
|
18254
18265
|
}
|
|
18255
|
-
|
|
18266
|
+
const failedResult = {
|
|
18256
18267
|
txId,
|
|
18257
18268
|
status: "FAILED",
|
|
18258
18269
|
txHash,
|
|
18259
18270
|
reason: failureReason
|
|
18260
18271
|
};
|
|
18272
|
+
return failedResult;
|
|
18261
18273
|
}
|
|
18262
18274
|
console.log(`[pollTransactionStatus] Transaction ${txId} is ${status}, attempt ${attempt + 1}/${maxAttempts}`);
|
|
18263
18275
|
await new Promise((resolve) => setTimeout(resolve, intervalMs));
|