@pushchain/core 5.1.1 → 5.1.3
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/package.json +1 -1
- package/src/lib/constants/abi/uea.evm.js +12 -13
- package/src/lib/constants/abi/uea.evm.js.map +1 -1
- package/src/lib/constants/abi/uea.svm.js +12 -13
- package/src/lib/constants/abi/uea.svm.js.map +1 -1
- package/src/lib/orchestrator/orchestrator.d.ts +5 -0
- package/src/lib/orchestrator/orchestrator.js +118 -39
- package/src/lib/orchestrator/orchestrator.js.map +1 -1
- package/src/lib/orchestrator/payload-builders.js +1 -1
- package/src/lib/orchestrator/payload-builders.js.map +1 -1
- package/src/lib/push-chain/push-chain.d.ts +18 -3
- package/src/lib/push-chain/push-chain.js +79 -4
- package/src/lib/push-chain/push-chain.js.map +1 -1
- package/src/lib/universal/account/account.d.ts +15 -0
- package/src/lib/universal/account/account.js +94 -1
- package/src/lib/universal/account/account.js.map +1 -1
- package/src/lib/utils.d.ts +2 -1
- package/src/lib/utils.js +1 -0
- package/src/lib/utils.js.map +1 -1
package/package.json
CHANGED
|
@@ -34,7 +34,7 @@ exports.UEA_EVM = [
|
|
|
34
34
|
},
|
|
35
35
|
{
|
|
36
36
|
type: 'function',
|
|
37
|
-
name: '
|
|
37
|
+
name: 'executeUniversalTx',
|
|
38
38
|
inputs: [
|
|
39
39
|
{
|
|
40
40
|
name: 'payload',
|
|
@@ -99,7 +99,7 @@ exports.UEA_EVM = [
|
|
|
99
99
|
},
|
|
100
100
|
{
|
|
101
101
|
type: 'function',
|
|
102
|
-
name: '
|
|
102
|
+
name: 'getUniversalPayloadHash',
|
|
103
103
|
inputs: [
|
|
104
104
|
{
|
|
105
105
|
name: 'payload',
|
|
@@ -189,6 +189,11 @@ exports.UEA_EVM = [
|
|
|
189
189
|
},
|
|
190
190
|
],
|
|
191
191
|
},
|
|
192
|
+
{
|
|
193
|
+
name: '_factory',
|
|
194
|
+
type: 'address',
|
|
195
|
+
internalType: 'address',
|
|
196
|
+
},
|
|
192
197
|
],
|
|
193
198
|
outputs: [],
|
|
194
199
|
stateMutability: 'nonpayable',
|
|
@@ -238,7 +243,7 @@ exports.UEA_EVM = [
|
|
|
238
243
|
},
|
|
239
244
|
{
|
|
240
245
|
type: 'function',
|
|
241
|
-
name: '
|
|
246
|
+
name: 'verifyUniversalPayloadSignature',
|
|
242
247
|
inputs: [
|
|
243
248
|
{
|
|
244
249
|
name: 'messageHash',
|
|
@@ -271,23 +276,17 @@ exports.UEA_EVM = [
|
|
|
271
276
|
internalType: 'bytes',
|
|
272
277
|
},
|
|
273
278
|
{
|
|
274
|
-
name: '
|
|
275
|
-
type: '
|
|
276
|
-
indexed: false,
|
|
277
|
-
internalType: 'address',
|
|
278
|
-
},
|
|
279
|
-
{
|
|
280
|
-
name: 'data',
|
|
281
|
-
type: 'bytes',
|
|
279
|
+
name: 'nonce',
|
|
280
|
+
type: 'uint256',
|
|
282
281
|
indexed: false,
|
|
283
|
-
internalType: '
|
|
282
|
+
internalType: 'uint256',
|
|
284
283
|
},
|
|
285
284
|
],
|
|
286
285
|
anonymous: false,
|
|
287
286
|
},
|
|
288
287
|
{
|
|
289
288
|
type: 'error',
|
|
290
|
-
name: '
|
|
289
|
+
name: 'AccountAlreadyExists',
|
|
291
290
|
inputs: [],
|
|
292
291
|
},
|
|
293
292
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uea.evm.js","sourceRoot":"","sources":["../../../../../../../packages/core/src/lib/constants/abi/uea.evm.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG;IACrB;QACE,IAAI,EAAE,SAAS;QACf,eAAe,EAAE,SAAS;KAC3B;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,SAAS;QACf,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,QAAQ;gBACd,YAAY,EAAE,QAAQ;aACvB;SACF;QACD,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,iBAAiB;QACvB,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS;aACxB;SACF;QACD,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,
|
|
1
|
+
{"version":3,"file":"uea.evm.js","sourceRoot":"","sources":["../../../../../../../packages/core/src/lib/constants/abi/uea.evm.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG;IACrB;QACE,IAAI,EAAE,SAAS;QACf,eAAe,EAAE,SAAS;KAC3B;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,SAAS;QACf,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,QAAQ;gBACd,YAAY,EAAE,QAAQ;aACvB;SACF;QACD,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,iBAAiB;QACvB,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS;aACxB;SACF;QACD,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,oBAAoB;QAC1B,MAAM,EAAE;YACN;gBACE,IAAI,EAAE,SAAS;gBACf,IAAI,EAAE,OAAO;gBACb,YAAY,EAAE,yBAAyB;gBACvC,UAAU,EAAE;oBACV;wBACE,IAAI,EAAE,IAAI;wBACV,IAAI,EAAE,SAAS;wBACf,YAAY,EAAE,SAAS;qBACxB;oBACD;wBACE,IAAI,EAAE,OAAO;wBACb,IAAI,EAAE,SAAS;wBACf,YAAY,E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,EAAE,KAAK;gBACd,YAAY,EAAE,OAAO;aACtB;YACD;gBACE,IAAI,EAAE,OAAO;gBACb,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE,KAAK;gBACd,YAAY,EAAE,SAAS;aACxB;SACF;QACD,SAAS,EAAE,KAAK;KACjB;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,sBAAsB;QAC5B,MAAM,EAAE,EAAE;KACX;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,uBAAuB;QAC7B,MAAM,EAAE,EAAE;KACX;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,6BAA6B;QACnC,MAAM,EAAE;YACN;gBACE,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS;aACxB;SACF;KACF;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,wBAAwB;QAC9B,MAAM,EAAE;YACN;gBACE,IAAI,EAAE,GAAG;gBACT,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS;aACxB;SACF;KACF;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,iBAAiB;QACvB,MAAM,EAAE,EAAE;KACX;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,iBAAiB;QACvB,MAAM,EAAE,EAAE;KACX;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,qBAAqB;QAC3B,MAAM,EAAE,EAAE;KACX;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,8BAA8B;QACpC,MAAM,EAAE,EAAE;KACX;CACF,CAAC"}
|
|
@@ -47,7 +47,7 @@ exports.UEA_SVM = [
|
|
|
47
47
|
},
|
|
48
48
|
{
|
|
49
49
|
type: 'function',
|
|
50
|
-
name: '
|
|
50
|
+
name: 'executeUniversalTx',
|
|
51
51
|
inputs: [
|
|
52
52
|
{
|
|
53
53
|
name: 'payload',
|
|
@@ -112,7 +112,7 @@ exports.UEA_SVM = [
|
|
|
112
112
|
},
|
|
113
113
|
{
|
|
114
114
|
type: 'function',
|
|
115
|
-
name: '
|
|
115
|
+
name: 'getUniversalPayloadHash',
|
|
116
116
|
inputs: [
|
|
117
117
|
{
|
|
118
118
|
name: 'payload',
|
|
@@ -202,6 +202,11 @@ exports.UEA_SVM = [
|
|
|
202
202
|
},
|
|
203
203
|
],
|
|
204
204
|
},
|
|
205
|
+
{
|
|
206
|
+
name: '_factory',
|
|
207
|
+
type: 'address',
|
|
208
|
+
internalType: 'address',
|
|
209
|
+
},
|
|
205
210
|
],
|
|
206
211
|
outputs: [],
|
|
207
212
|
stateMutability: 'nonpayable',
|
|
@@ -251,7 +256,7 @@ exports.UEA_SVM = [
|
|
|
251
256
|
},
|
|
252
257
|
{
|
|
253
258
|
type: 'function',
|
|
254
|
-
name: '
|
|
259
|
+
name: 'verifyUniversalPayloadSignature',
|
|
255
260
|
inputs: [
|
|
256
261
|
{
|
|
257
262
|
name: 'messageHash',
|
|
@@ -284,23 +289,17 @@ exports.UEA_SVM = [
|
|
|
284
289
|
internalType: 'bytes',
|
|
285
290
|
},
|
|
286
291
|
{
|
|
287
|
-
name: '
|
|
288
|
-
type: '
|
|
289
|
-
indexed: false,
|
|
290
|
-
internalType: 'address',
|
|
291
|
-
},
|
|
292
|
-
{
|
|
293
|
-
name: 'data',
|
|
294
|
-
type: 'bytes',
|
|
292
|
+
name: 'nonce',
|
|
293
|
+
type: 'uint256',
|
|
295
294
|
indexed: false,
|
|
296
|
-
internalType: '
|
|
295
|
+
internalType: 'uint256',
|
|
297
296
|
},
|
|
298
297
|
],
|
|
299
298
|
anonymous: false,
|
|
300
299
|
},
|
|
301
300
|
{
|
|
302
301
|
type: 'error',
|
|
303
|
-
name: '
|
|
302
|
+
name: 'AccountAlreadyExists',
|
|
304
303
|
inputs: [],
|
|
305
304
|
},
|
|
306
305
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uea.svm.js","sourceRoot":"","sources":["../../../../../../../packages/core/src/lib/constants/abi/uea.svm.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG;IACrB;QACE,IAAI,EAAE,SAAS;QACf,eAAe,EAAE,SAAS;KAC3B;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,qBAAqB;QAC3B,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS;aACxB;SACF;QACD,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,SAAS;QACf,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,QAAQ;gBACd,YAAY,EAAE,QAAQ;aACvB;SACF;QACD,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,iBAAiB;QACvB,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS;aACxB;SACF;QACD,eAAe,EAAE,MAAM;KACxB;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,
|
|
1
|
+
{"version":3,"file":"uea.svm.js","sourceRoot":"","sources":["../../../../../../../packages/core/src/lib/constants/abi/uea.svm.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG;IACrB;QACE,IAAI,EAAE,SAAS;QACf,eAAe,EAAE,SAAS;KAC3B;IACD;QACE,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,qBAAqB;QAC3B,MAAM,EAAE,EAAE;QACV,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,EAAE;gBACR,IAAI,EAAE,SAAS;gBACf,YAAY,EAAE,SAAS;aACxB;SACF;QACD,eAAe,EAAE,MAAM;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AqB;QAC3B,MAAM,EAAE,EAAE;KACX;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,sBAAsB;QAC5B,MAAM,EAAE,EAAE;KACX;IACD;QACE,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,8BAA8B;QACpC,MAAM,EAAE,EAAE;KACX;CACF,CAAC"}
|
|
@@ -375,6 +375,11 @@ export declare class Orchestrator {
|
|
|
375
375
|
* @returns Array of ProgressEvent objects to emit
|
|
376
376
|
*/
|
|
377
377
|
private reconstructProgressEvents;
|
|
378
|
+
/**
|
|
379
|
+
* Detect the transaction route from UniversalTxV2 data.
|
|
380
|
+
* Used by trackTransaction to infer the route when it's not set by execute().
|
|
381
|
+
*/
|
|
382
|
+
private detectRouteFromUniversalTxData;
|
|
378
383
|
/**
|
|
379
384
|
* Tracks a transaction by hash on Push Chain and returns UniversalTxResponse.
|
|
380
385
|
* Reconstructs and replays SEND-TX-* progress events for completed transactions.
|
|
@@ -466,7 +466,7 @@ class Orchestrator {
|
|
|
466
466
|
throw new Error(`Failed to retrieve Push Chain transaction status for gateway tx: ${txHash}. ` +
|
|
467
467
|
`The transaction may have failed on Push Chain or not been indexed yet.`);
|
|
468
468
|
}
|
|
469
|
-
// For sendFunds operations, MintPC (first) succeeds and
|
|
469
|
+
// For sendFunds operations, MintPC (first) succeeds and executeUniversalTx (second) may fail
|
|
470
470
|
// Always use the last pcTx entry as it represents the final execution result
|
|
471
471
|
const lastPcTransaction = pushChainUniversalTx.pcTx.at(-1);
|
|
472
472
|
this.printLog('sendFunds — pushChainUniversalTx pcTx: ' + JSON.stringify((_e = pushChainUniversalTx === null || pushChainUniversalTx === void 0 ? void 0 : pushChainUniversalTx.pcTx) === null || _e === void 0 ? void 0 : _e.map((p) => ({ txHash: p.txHash, status: p.status, errorMsg: p.errorMsg })), null, 2));
|
|
@@ -1010,7 +1010,9 @@ class Orchestrator {
|
|
|
1010
1010
|
// passed as zeroAddress in the future.
|
|
1011
1011
|
// execute.to = zeroAddress;
|
|
1012
1012
|
payloadTo = viem_1.zeroAddress;
|
|
1013
|
-
|
|
1013
|
+
if (execute.to.toLowerCase() !== viem_1.zeroAddress) {
|
|
1014
|
+
console.warn(`Multicalls should have execute.to as ${viem_1.zeroAddress}`);
|
|
1015
|
+
}
|
|
1014
1016
|
payloadData = this._buildMulticallPayloadData(execute.to, (0, payload_builders_1.buildExecuteMulticall)({ execute, ueaAddress: UEA }));
|
|
1015
1017
|
req = this._buildUniversalTxRequest({
|
|
1016
1018
|
recipient: viem_1.zeroAddress,
|
|
@@ -2431,12 +2433,18 @@ class Orchestrator {
|
|
|
2431
2433
|
// Get UniversalGatewayPC address
|
|
2432
2434
|
const gatewayPcAddress = this.getUniversalGatewayPCAddress();
|
|
2433
2435
|
// Pre-fetch UEA status early — balance is needed for gas value calculation
|
|
2436
|
+
const signerChain = this.universalSigner.account.chain;
|
|
2437
|
+
const isNativePushEOA = this.isPushChain(signerChain);
|
|
2434
2438
|
const [ueaCode, ueaBalance] = yield Promise.all([
|
|
2435
2439
|
this.pushClient.publicClient.getCode({ address: ueaAddress }),
|
|
2436
2440
|
this.pushClient.getBalance(ueaAddress),
|
|
2437
2441
|
]);
|
|
2438
|
-
const isUEADeployed = ueaCode !== undefined;
|
|
2439
|
-
|
|
2442
|
+
const isUEADeployed = isNativePushEOA || ueaCode !== undefined;
|
|
2443
|
+
if (!isUEADeployed) {
|
|
2444
|
+
throw new Error('UEA is not deployed. Please send an inbound transaction to Push Chain first ' +
|
|
2445
|
+
'(e.g. sendTransaction with value) to deploy your Universal Execution Account before using outbound transfers.');
|
|
2446
|
+
}
|
|
2447
|
+
const ueaNonce = isNativePushEOA ? BigInt(0) : yield this.getUEANonce(ueaAddress);
|
|
2440
2448
|
// Build the multicall that will execute ON Push Chain from UEA context
|
|
2441
2449
|
// This includes: 1) approve PRC-20 (if needed), 2) call sendUniversalTxOutbound
|
|
2442
2450
|
const pushChainMulticalls = [];
|
|
@@ -2492,6 +2500,31 @@ class Orchestrator {
|
|
|
2492
2500
|
});
|
|
2493
2501
|
pushChainMulticalls.push(...outboundMulticalls);
|
|
2494
2502
|
this.printLog(`executeUoaToCea — Push Chain multicall has ${pushChainMulticalls.length} operations`);
|
|
2503
|
+
// TODO: Enable pre-flight balance checks once outbound flow is stable
|
|
2504
|
+
// if (burnAmount > BigInt(0)) {
|
|
2505
|
+
// const prc20Balance = await this.pushClient.publicClient.readContract({
|
|
2506
|
+
// address: prc20Token,
|
|
2507
|
+
// abi: [{ name: 'balanceOf', type: 'function', stateMutability: 'view', inputs: [{ name: 'account', type: 'address' }], outputs: [{ name: '', type: 'uint256' }] }],
|
|
2508
|
+
// functionName: 'balanceOf',
|
|
2509
|
+
// args: [ueaAddress],
|
|
2510
|
+
// }) as bigint;
|
|
2511
|
+
// if (prc20Balance < burnAmount) {
|
|
2512
|
+
// throw new Error(
|
|
2513
|
+
// `Insufficient PRC-20 token balance on UEA. ` +
|
|
2514
|
+
// `Required: ${burnAmount.toString()}, Available: ${prc20Balance.toString()}, ` +
|
|
2515
|
+
// `Token: ${prc20Token}, UEA: ${ueaAddress}. ` +
|
|
2516
|
+
// `Please bridge tokens to Push Chain first.`
|
|
2517
|
+
// );
|
|
2518
|
+
// }
|
|
2519
|
+
// }
|
|
2520
|
+
// const currentUeaBalance = await this.pushClient.getBalance(ueaAddress);
|
|
2521
|
+
// if (currentUeaBalance < nativeValueForGas) {
|
|
2522
|
+
// throw new Error(
|
|
2523
|
+
// `Insufficient native balance on UEA for outbound gas. ` +
|
|
2524
|
+
// `Required: ${nativeValueForGas.toString()} wei, Available: ${currentUeaBalance.toString()} wei, ` +
|
|
2525
|
+
// `UEA: ${ueaAddress}. Please send UPC to your UEA first.`
|
|
2526
|
+
// );
|
|
2527
|
+
// }
|
|
2495
2528
|
// Execute through the normal execute() flow
|
|
2496
2529
|
// This handles fee-locking on origin chain and executes the multicall from UEA context
|
|
2497
2530
|
// Sum native values from multicall entries for proper fee calculation
|
|
@@ -2597,14 +2630,18 @@ class Orchestrator {
|
|
|
2597
2630
|
}, null, 2)}`);
|
|
2598
2631
|
// --- Pre-fetch UEA status early — balance is needed for gas value calculation ---
|
|
2599
2632
|
const gatewayPcAddress = this.getUniversalGatewayPCAddress();
|
|
2633
|
+
const signerChainSvm = this.universalSigner.account.chain;
|
|
2634
|
+
const isNativePushEOASvm = this.isPushChain(signerChainSvm);
|
|
2600
2635
|
const [ueaCode, ueaBalance] = yield Promise.all([
|
|
2601
2636
|
this.pushClient.publicClient.getCode({ address: ueaAddress }),
|
|
2602
2637
|
this.pushClient.getBalance(ueaAddress),
|
|
2603
2638
|
]);
|
|
2604
|
-
const isUEADeployed = ueaCode !== undefined;
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
|
|
2639
|
+
const isUEADeployed = isNativePushEOASvm || ueaCode !== undefined;
|
|
2640
|
+
if (!isUEADeployed) {
|
|
2641
|
+
throw new Error('UEA is not deployed. Please send an inbound transaction to Push Chain first ' +
|
|
2642
|
+
'(e.g. sendTransaction with value) to deploy your Universal Execution Account before using outbound transfers.');
|
|
2643
|
+
}
|
|
2644
|
+
const ueaNonce = isNativePushEOASvm ? BigInt(0) : yield this.getUEANonce(ueaAddress);
|
|
2608
2645
|
// --- Query gas fee (identical to EVM path) ---
|
|
2609
2646
|
let gasFee = BigInt(0);
|
|
2610
2647
|
let gasToken = selectors_1.ZERO_ADDRESS;
|
|
@@ -3914,27 +3951,6 @@ class Orchestrator {
|
|
|
3914
3951
|
};
|
|
3915
3952
|
const { cosmosAddress: signer } = this.pushClient.getSignerAddress();
|
|
3916
3953
|
const msgs = [];
|
|
3917
|
-
if (!isUEADeployed) {
|
|
3918
|
-
/**
|
|
3919
|
-
* @dev - fee should be locked for UEA deployment to avoid spamming
|
|
3920
|
-
*/
|
|
3921
|
-
if (!feeLockTxHash) {
|
|
3922
|
-
throw new Error('UEA cannot be deployed without fee locking');
|
|
3923
|
-
}
|
|
3924
|
-
msgs.push(this.pushClient.createMsgDeployUEA({
|
|
3925
|
-
signer,
|
|
3926
|
-
universalAccountId,
|
|
3927
|
-
txHash: feeLockTxHash,
|
|
3928
|
-
}));
|
|
3929
|
-
// TODO: pchaind q uexecutor all-universal-tx --node https://rpc-testnet-donut-node1.push.org/
|
|
3930
|
-
}
|
|
3931
|
-
if (feeLockTxHash) {
|
|
3932
|
-
msgs.push(this.pushClient.createMsgMintPC({
|
|
3933
|
-
signer,
|
|
3934
|
-
universalAccountId,
|
|
3935
|
-
txHash: feeLockTxHash,
|
|
3936
|
-
}));
|
|
3937
|
-
}
|
|
3938
3954
|
if (universalPayload && verificationData) {
|
|
3939
3955
|
msgs.push(this.pushClient.createMsgExecutePayload({
|
|
3940
3956
|
signer,
|
|
@@ -4302,18 +4318,46 @@ class Orchestrator {
|
|
|
4302
4318
|
}
|
|
4303
4319
|
// SEND_TX_07: Broadcasting (always emit)
|
|
4304
4320
|
events.push(progress_hook_1.default[progress_hook_types_1.PROGRESS_HOOK.SEND_TX_07]());
|
|
4305
|
-
// Determine outcome from pcTx status
|
|
4321
|
+
// Determine outcome from pcTx status and outbound status
|
|
4306
4322
|
const pcTx = (_a = universalTxData === null || universalTxData === void 0 ? void 0 : universalTxData.pcTx) === null || _a === void 0 ? void 0 : _a[0];
|
|
4307
|
-
const
|
|
4323
|
+
const isOutboundFailed = (universalTxData === null || universalTxData === void 0 ? void 0 : universalTxData.universalStatus) === types_1.UniversalTxStatus.OUTBOUND_FAILED;
|
|
4324
|
+
const isPcFailed = (pcTx === null || pcTx === void 0 ? void 0 : pcTx.status) === 'FAILED';
|
|
4325
|
+
const isFailed = isPcFailed || isOutboundFailed;
|
|
4308
4326
|
// SEND_TX_99_01/02: Final outcome
|
|
4309
4327
|
if (isFailed) {
|
|
4310
|
-
|
|
4328
|
+
const errorMsg = isOutboundFailed
|
|
4329
|
+
? 'Outbound transaction failed (status: OUTBOUND_FAILED)'
|
|
4330
|
+
: ((pcTx === null || pcTx === void 0 ? void 0 : pcTx.errorMsg) || 'Unknown error');
|
|
4331
|
+
events.push(progress_hook_1.default[progress_hook_types_1.PROGRESS_HOOK.SEND_TX_99_02](errorMsg));
|
|
4311
4332
|
}
|
|
4312
4333
|
else {
|
|
4313
4334
|
events.push(progress_hook_1.default[progress_hook_types_1.PROGRESS_HOOK.SEND_TX_99_01]([universalTxResponse]));
|
|
4314
4335
|
}
|
|
4315
4336
|
return events;
|
|
4316
4337
|
}
|
|
4338
|
+
/**
|
|
4339
|
+
* Detect the transaction route from UniversalTxV2 data.
|
|
4340
|
+
* Used by trackTransaction to infer the route when it's not set by execute().
|
|
4341
|
+
*/
|
|
4342
|
+
detectRouteFromUniversalTxData(universalTxData) {
|
|
4343
|
+
if (!universalTxData)
|
|
4344
|
+
return undefined;
|
|
4345
|
+
const hasOutbound = universalTxData.outboundTx.length > 0;
|
|
4346
|
+
const hasInbound = !!universalTxData.inboundTx;
|
|
4347
|
+
const statusIndicatesOutbound = [
|
|
4348
|
+
types_1.UniversalTxStatus.OUTBOUND_PENDING,
|
|
4349
|
+
types_1.UniversalTxStatus.OUTBOUND_SUCCESS,
|
|
4350
|
+
types_1.UniversalTxStatus.OUTBOUND_FAILED,
|
|
4351
|
+
].includes(universalTxData.universalStatus);
|
|
4352
|
+
if (hasOutbound || statusIndicatesOutbound) {
|
|
4353
|
+
return hasInbound
|
|
4354
|
+
? route_detector_1.TransactionRoute.CEA_TO_CEA
|
|
4355
|
+
: route_detector_1.TransactionRoute.UOA_TO_CEA;
|
|
4356
|
+
}
|
|
4357
|
+
if (hasInbound)
|
|
4358
|
+
return route_detector_1.TransactionRoute.CEA_TO_PUSH;
|
|
4359
|
+
return route_detector_1.TransactionRoute.UOA_TO_PUSH;
|
|
4360
|
+
}
|
|
4317
4361
|
/**
|
|
4318
4362
|
* Tracks a transaction by hash on Push Chain and returns UniversalTxResponse.
|
|
4319
4363
|
* Reconstructs and replays SEND-TX-* progress events for completed transactions.
|
|
@@ -4370,20 +4414,53 @@ class Orchestrator {
|
|
|
4370
4414
|
}
|
|
4371
4415
|
// Try to get UniversalTx data for richer progress reconstruction
|
|
4372
4416
|
// (may not exist for direct Push Chain transactions)
|
|
4417
|
+
// Three-tier lookup: direct hash → computed keccak ID → Cosmos event extraction
|
|
4373
4418
|
let universalTxData;
|
|
4374
4419
|
try {
|
|
4375
|
-
// Attempt to find UniversalTx by searching pcTx entries
|
|
4376
|
-
// For now, we'll try to look up by the tx hash
|
|
4377
4420
|
const utxResponse = yield this.pushClient.getUniversalTxByIdV2(txHash);
|
|
4378
4421
|
if (utxResponse === null || utxResponse === void 0 ? void 0 : utxResponse.universalTx) {
|
|
4379
4422
|
universalTxData = utxResponse.universalTx;
|
|
4380
4423
|
}
|
|
4381
4424
|
}
|
|
4382
4425
|
catch (_a) {
|
|
4383
|
-
// Ignore -
|
|
4426
|
+
// Ignore - try computed ID next
|
|
4427
|
+
}
|
|
4428
|
+
if (!universalTxData) {
|
|
4429
|
+
try {
|
|
4430
|
+
const computedId = this.computeUniversalTxId(txHash);
|
|
4431
|
+
const queryId = computedId.startsWith('0x') ? computedId.slice(2) : computedId;
|
|
4432
|
+
const utxResponse = yield this.pushClient.getUniversalTxByIdV2(queryId);
|
|
4433
|
+
if (utxResponse === null || utxResponse === void 0 ? void 0 : utxResponse.universalTx) {
|
|
4434
|
+
universalTxData = utxResponse.universalTx;
|
|
4435
|
+
}
|
|
4436
|
+
}
|
|
4437
|
+
catch (_b) {
|
|
4438
|
+
// Ignore - try Cosmos event extraction next
|
|
4439
|
+
}
|
|
4440
|
+
}
|
|
4441
|
+
if (!universalTxData) {
|
|
4442
|
+
try {
|
|
4443
|
+
const extractedId = yield this.extractUniversalSubTxIdFromTx(txHash);
|
|
4444
|
+
if (extractedId) {
|
|
4445
|
+
const queryId = extractedId.startsWith('0x') ? extractedId.slice(2) : extractedId;
|
|
4446
|
+
const utxResponse = yield this.pushClient.getUniversalTxByIdV2(queryId);
|
|
4447
|
+
if (utxResponse === null || utxResponse === void 0 ? void 0 : utxResponse.universalTx) {
|
|
4448
|
+
universalTxData = utxResponse.universalTx;
|
|
4449
|
+
}
|
|
4450
|
+
}
|
|
4451
|
+
}
|
|
4452
|
+
catch (_c) {
|
|
4453
|
+
// Ignore - no universal tx data available
|
|
4454
|
+
}
|
|
4384
4455
|
}
|
|
4385
4456
|
// Transform to UniversalTxResponse
|
|
4386
4457
|
const universalTxResponse = yield this.transformToUniversalTxResponse(tx, eventBuffer);
|
|
4458
|
+
// Detect route from UniversalTxV2 data and set on response
|
|
4459
|
+
// This enables wait() to trigger outbound polling via waitForOutboundTx()
|
|
4460
|
+
const detectedRoute = this.detectRouteFromUniversalTxData(universalTxData);
|
|
4461
|
+
if (detectedRoute) {
|
|
4462
|
+
universalTxResponse.route = detectedRoute;
|
|
4463
|
+
}
|
|
4387
4464
|
// Reconstruct and emit SEND-TX-* progress events
|
|
4388
4465
|
const reconstructedEvents = this.reconstructProgressEvents(universalTxResponse, universalTxData);
|
|
4389
4466
|
for (const event of reconstructedEvents) {
|
|
@@ -5552,7 +5629,7 @@ class Orchestrator {
|
|
|
5552
5629
|
let value;
|
|
5553
5630
|
let data;
|
|
5554
5631
|
let rawTransactionData;
|
|
5555
|
-
const ueaOrigin = yield push_chain_1.PushChain.utils.account.
|
|
5632
|
+
const ueaOrigin = yield push_chain_1.PushChain.utils.account.convertExecutorToOrigin(tx.to);
|
|
5556
5633
|
let originAddress;
|
|
5557
5634
|
if (ueaOrigin.exists) {
|
|
5558
5635
|
if (!ueaOrigin.account) {
|
|
@@ -5750,9 +5827,11 @@ class Orchestrator {
|
|
|
5750
5827
|
const receipt = yield tx.wait();
|
|
5751
5828
|
baseReceipt = this.transformToUniversalTxReceipt(receipt, universalTxResponse);
|
|
5752
5829
|
}
|
|
5753
|
-
// If outbound route
|
|
5754
|
-
|
|
5755
|
-
|
|
5830
|
+
// If outbound route, poll for external chain details
|
|
5831
|
+
const routeInfo = universalTxResponse.route
|
|
5832
|
+
? (0, route_detector_1.getRouteInfo)(universalTxResponse.route)
|
|
5833
|
+
: undefined;
|
|
5834
|
+
if (routeInfo === null || routeInfo === void 0 ? void 0 : routeInfo.isOutbound) {
|
|
5756
5835
|
try {
|
|
5757
5836
|
const outboundDetails = yield this.waitForOutboundTx(tx.hash, {
|
|
5758
5837
|
initialWaitMs: Orchestrator.OUTBOUND_INITIAL_WAIT_MS,
|