@streamflow/stream 4.0.2 → 4.1.0-beta.0
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/__tests__/aptos/streamClient.spec.js +1 -1
- package/dist/aptos/StreamClient.d.ts +4 -3
- package/dist/aptos/StreamClient.js +13 -6
- package/dist/aptos/types.d.ts +0 -16
- package/dist/common/BaseStreamClient.d.ts +11 -9
- package/dist/common/GenericStreamClient.d.ts +25 -12
- package/dist/common/GenericStreamClient.js +18 -5
- package/dist/common/types.d.ts +29 -1
- package/dist/common/types.js +2 -0
- package/dist/common/utils.js +6 -3
- package/dist/evm/StreamClient.d.ts +27 -0
- package/dist/evm/StreamClient.js +376 -0
- package/dist/evm/abi.d.ts +111 -0
- package/dist/evm/abi.js +442 -0
- package/dist/evm/constants.d.ts +3 -0
- package/dist/evm/constants.js +17 -0
- package/dist/evm/ercAbi.d.ts +39 -0
- package/dist/evm/ercAbi.js +224 -0
- package/dist/evm/index.d.ts +2 -0
- package/dist/evm/index.js +24 -0
- package/dist/evm/types.d.ts +122 -0
- package/dist/evm/types.js +64 -0
- package/dist/solana/StreamClient.d.ts +11 -11
- package/dist/solana/StreamClient.js +26 -21
- package/dist/solana/utils.js +12 -8
- package/package.json +2 -1
package/dist/solana/utils.js
CHANGED
|
@@ -227,14 +227,15 @@ exports.signAllTransactionWithRecipients = signAllTransactionWithRecipients;
|
|
|
227
227
|
* @return {Promise<BatchItemResult>} - Returns settled transaction item
|
|
228
228
|
*/
|
|
229
229
|
function sendAndConfirmStreamRawTransaction(connection, batchItem) {
|
|
230
|
+
var _a, _b;
|
|
230
231
|
return __awaiter(this, void 0, void 0, function () {
|
|
231
|
-
var rawTx,
|
|
232
|
-
return __generator(this, function (
|
|
233
|
-
switch (
|
|
232
|
+
var rawTx, _c, lastValidBlockHeight, signature, recentBlockhash, confirmationStrategy, completedTxSignature, error_1;
|
|
233
|
+
return __generator(this, function (_d) {
|
|
234
|
+
switch (_d.label) {
|
|
234
235
|
case 0:
|
|
235
|
-
|
|
236
|
+
_d.trys.push([0, 2, , 3]);
|
|
236
237
|
rawTx = batchItem.tx.serialize();
|
|
237
|
-
|
|
238
|
+
_c = batchItem.tx, lastValidBlockHeight = _c.lastValidBlockHeight, signature = _c.signature, recentBlockhash = _c.recentBlockhash;
|
|
238
239
|
if (!lastValidBlockHeight || !signature || !recentBlockhash)
|
|
239
240
|
throw { recipient: batchItem.recipient, error: "no recent blockhash" };
|
|
240
241
|
confirmationStrategy = {
|
|
@@ -244,11 +245,14 @@ function sendAndConfirmStreamRawTransaction(connection, batchItem) {
|
|
|
244
245
|
};
|
|
245
246
|
return [4 /*yield*/, (0, web3_js_1.sendAndConfirmRawTransaction)(connection, rawTx, confirmationStrategy)];
|
|
246
247
|
case 1:
|
|
247
|
-
completedTxSignature =
|
|
248
|
+
completedTxSignature = _d.sent();
|
|
248
249
|
return [2 /*return*/, __assign(__assign({}, batchItem), { signature: completedTxSignature })];
|
|
249
250
|
case 2:
|
|
250
|
-
error_1 =
|
|
251
|
-
throw {
|
|
251
|
+
error_1 = _d.sent();
|
|
252
|
+
throw {
|
|
253
|
+
recipient: batchItem.recipient,
|
|
254
|
+
error: (_b = (_a = error_1 === null || error_1 === void 0 ? void 0 : error_1.error) !== null && _a !== void 0 ? _a : error_1 === null || error_1 === void 0 ? void 0 : error_1.message) !== null && _b !== void 0 ? _b : error_1.toString(),
|
|
255
|
+
};
|
|
252
256
|
case 3: return [2 /*return*/];
|
|
253
257
|
}
|
|
254
258
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamflow/stream",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.1.0-beta.0",
|
|
4
4
|
"description": "JavaScript SDK to interact with Streamflow protocol.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"homepage": "https://github.com/streamflow-finance/js-sdk/",
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"aptos": "1.4.0",
|
|
36
36
|
"bn.js": "5.2.1",
|
|
37
37
|
"bs58": "5.0.0",
|
|
38
|
+
"ethers": "5.7.2",
|
|
38
39
|
"js-sha256": "0.9.0"
|
|
39
40
|
}
|
|
40
41
|
}
|