@streamflow/stream 7.4.15 → 7.4.17
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.
|
@@ -848,7 +848,7 @@ class SolanaStreamClient extends BaseStreamClient_js_1.BaseStreamClient {
|
|
|
848
848
|
},
|
|
849
849
|
]);
|
|
850
850
|
const streamPubKeys = alignedOutgoingProgramAccounts.map((account) => account.account.stream);
|
|
851
|
-
const streamAccounts = await this.connection
|
|
851
|
+
const streamAccounts = await (0, solana_1.getMultipleAccountsInfoBatched)(this.connection, streamPubKeys, constants_js_1.TX_FINALITY_CONFIRMED);
|
|
852
852
|
streamAccounts.forEach((account, index) => {
|
|
853
853
|
if (account) {
|
|
854
854
|
const alignedData = alignedOutgoingProgramAccounts[index].account;
|
|
@@ -861,7 +861,7 @@ class SolanaStreamClient extends BaseStreamClient_js_1.BaseStreamClient {
|
|
|
861
861
|
const streams = {};
|
|
862
862
|
const alignedStreamsPubKeys = Object.keys(streamRecord);
|
|
863
863
|
const alignedProxyPDAs = alignedStreamsPubKeys.map((streamPubKey) => (0, derive_accounts_js_1.deriveContractPDA)(this.alignedProxyProgram.programId, new web3_js_1.PublicKey(streamPubKey)));
|
|
864
|
-
const alignedProxyAccounts = await this.connection
|
|
864
|
+
const alignedProxyAccounts = await (0, solana_1.getMultipleAccountsInfoBatched)(this.connection, alignedProxyPDAs);
|
|
865
865
|
alignedProxyAccounts.forEach((account, index) => {
|
|
866
866
|
if (account && account.data.length === ALIGNED_METADATA_ACC_SIZE) {
|
|
867
867
|
const alignedData = streamRecord[alignedStreamsPubKeys[index]];
|
|
@@ -4,7 +4,7 @@ import bs58 from "bs58";
|
|
|
4
4
|
import { Buffer } from "buffer";
|
|
5
5
|
import { ASSOCIATED_TOKEN_PROGRAM_ID, NATIVE_MINT } from "@solana/spl-token";
|
|
6
6
|
import { Connection, Keypair, PublicKey, SystemProgram, SYSVAR_RENT_PUBKEY, TransactionMessage, VersionedTransaction, } from "@solana/web3.js";
|
|
7
|
-
import { ata, checkOrCreateAtaBatch, signAndExecuteTransaction, getProgramAccounts, prepareWrappedAccount, prepareTransaction, prepareBaseInstructions, getMintAndProgram, executeTransaction, executeMultipleTransactions, buildSendThrottler, } from "@streamflow/common/solana";
|
|
7
|
+
import { ata, checkOrCreateAtaBatch, signAndExecuteTransaction, getProgramAccounts, prepareWrappedAccount, prepareTransaction, prepareBaseInstructions, getMintAndProgram, executeTransaction, executeMultipleTransactions, buildSendThrottler, getMultipleAccountsInfoBatched, } from "@streamflow/common/solana";
|
|
8
8
|
import * as borsh from "borsh";
|
|
9
9
|
import { Program } from "@coral-xyz/anchor";
|
|
10
10
|
import { getBN } from "@streamflow/common";
|
|
@@ -824,7 +824,7 @@ export class SolanaStreamClient extends BaseStreamClient {
|
|
|
824
824
|
},
|
|
825
825
|
]);
|
|
826
826
|
const streamPubKeys = alignedOutgoingProgramAccounts.map((account) => account.account.stream);
|
|
827
|
-
const streamAccounts = await this.connection
|
|
827
|
+
const streamAccounts = await getMultipleAccountsInfoBatched(this.connection, streamPubKeys, TX_FINALITY_CONFIRMED);
|
|
828
828
|
streamAccounts.forEach((account, index) => {
|
|
829
829
|
if (account) {
|
|
830
830
|
const alignedData = alignedOutgoingProgramAccounts[index].account;
|
|
@@ -837,7 +837,7 @@ export class SolanaStreamClient extends BaseStreamClient {
|
|
|
837
837
|
const streams = {};
|
|
838
838
|
const alignedStreamsPubKeys = Object.keys(streamRecord);
|
|
839
839
|
const alignedProxyPDAs = alignedStreamsPubKeys.map((streamPubKey) => deriveContractPDA(this.alignedProxyProgram.programId, new PublicKey(streamPubKey)));
|
|
840
|
-
const alignedProxyAccounts = await this.connection
|
|
840
|
+
const alignedProxyAccounts = await getMultipleAccountsInfoBatched(this.connection, alignedProxyPDAs);
|
|
841
841
|
alignedProxyAccounts.forEach((account, index) => {
|
|
842
842
|
if (account && account.data.length === ALIGNED_METADATA_ACC_SIZE) {
|
|
843
843
|
const alignedData = streamRecord[alignedStreamsPubKeys[index]];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamflow/stream",
|
|
3
|
-
"version": "7.4.
|
|
3
|
+
"version": "7.4.17",
|
|
4
4
|
"description": "JavaScript SDK to interact with Streamflow protocol.",
|
|
5
5
|
"homepage": "https://github.com/streamflow-finance/js-sdk/",
|
|
6
6
|
"main": "./dist/esm/index.js",
|
|
@@ -47,9 +47,9 @@
|
|
|
47
47
|
"lint": "eslint --fix .",
|
|
48
48
|
"prepublishOnly": "pnpm run lint && pnpm run test run && pnpm run build"
|
|
49
49
|
},
|
|
50
|
-
"gitHead": "
|
|
50
|
+
"gitHead": "087be41783b46f904ac73f084c4fb92ab42d32e9",
|
|
51
51
|
"devDependencies": {
|
|
52
|
-
"@streamflow/eslint-config": "7.4.
|
|
52
|
+
"@streamflow/eslint-config": "7.4.17",
|
|
53
53
|
"@types/bn.js": "5.1.1",
|
|
54
54
|
"@types/ethereum-checksum-address": "^0.0.0",
|
|
55
55
|
"date-fns": "2.28.0",
|
|
@@ -64,7 +64,7 @@
|
|
|
64
64
|
"@solana/spl-token": "0.4.9",
|
|
65
65
|
"@solana/wallet-adapter-base": "0.9.19",
|
|
66
66
|
"@solana/web3.js": "1.95.4",
|
|
67
|
-
"@streamflow/common": "7.4.
|
|
67
|
+
"@streamflow/common": "7.4.17",
|
|
68
68
|
"@suiet/wallet-kit": "^0.3.3",
|
|
69
69
|
"aptos": "1.21.0",
|
|
70
70
|
"bn.js": "5.2.1",
|