@dynamic-labs/embedded-wallet-solana 3.0.0-alpha.27 → 3.0.0-alpha.29
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/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,18 @@
|
|
|
1
1
|
|
|
2
|
+
## [3.0.0-alpha.29](https://github.com/dynamic-labs/DynamicAuth/compare/v3.0.0-alpha.28...v3.0.0-alpha.29) (2024-07-25)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* add link to starknet snap companion app in network switch modal ([#6417](https://github.com/dynamic-labs/DynamicAuth/issues/6417)) ([132a3f8](https://github.com/dynamic-labs/DynamicAuth/commit/132a3f84af62930583f042f35e9616bc837ee49d))
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Bug Fixes
|
|
11
|
+
|
|
12
|
+
* improve network switch ux for starknet snap on login ([#6376](https://github.com/dynamic-labs/DynamicAuth/issues/6376)) ([db4af65](https://github.com/dynamic-labs/DynamicAuth/commit/db4af6576dc164876750ad6e13f4624d8a11a1a3))
|
|
13
|
+
|
|
14
|
+
## [3.0.0-alpha.28](https://github.com/dynamic-labs/DynamicAuth/compare/v3.0.0-alpha.27...v3.0.0-alpha.28) (2024-07-25)
|
|
15
|
+
|
|
2
16
|
## [3.0.0-alpha.27](https://github.com/dynamic-labs/DynamicAuth/compare/v3.0.0-alpha.26...v3.0.0-alpha.27) (2024-07-24)
|
|
3
17
|
|
|
4
18
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/embedded-wallet-solana",
|
|
3
|
-
"version": "3.0.0-alpha.
|
|
3
|
+
"version": "3.0.0-alpha.29",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/dynamic-labs/dynamic-auth.git",
|
|
@@ -33,14 +33,14 @@
|
|
|
33
33
|
"@turnkey/iframe-stamper": "2.0.0",
|
|
34
34
|
"@turnkey/solana": "0.3.1",
|
|
35
35
|
"@turnkey/webauthn-stamper": "0.5.0",
|
|
36
|
-
"@dynamic-labs/embedded-wallet": "3.0.0-alpha.
|
|
37
|
-
"@dynamic-labs/rpc-provider-solana": "3.0.0-alpha.
|
|
38
|
-
"@dynamic-labs/rpc-providers": "3.0.0-alpha.
|
|
39
|
-
"@dynamic-labs/solana-utils": "3.0.0-alpha.
|
|
40
|
-
"@dynamic-labs/types": "3.0.0-alpha.
|
|
41
|
-
"@dynamic-labs/utils": "3.0.0-alpha.
|
|
42
|
-
"@dynamic-labs/wallet-book": "3.0.0-alpha.
|
|
43
|
-
"@dynamic-labs/wallet-connector-core": "3.0.0-alpha.
|
|
36
|
+
"@dynamic-labs/embedded-wallet": "3.0.0-alpha.29",
|
|
37
|
+
"@dynamic-labs/rpc-provider-solana": "3.0.0-alpha.29",
|
|
38
|
+
"@dynamic-labs/rpc-providers": "3.0.0-alpha.29",
|
|
39
|
+
"@dynamic-labs/solana-utils": "3.0.0-alpha.29",
|
|
40
|
+
"@dynamic-labs/types": "3.0.0-alpha.29",
|
|
41
|
+
"@dynamic-labs/utils": "3.0.0-alpha.29",
|
|
42
|
+
"@dynamic-labs/wallet-book": "3.0.0-alpha.29",
|
|
43
|
+
"@dynamic-labs/wallet-connector-core": "3.0.0-alpha.29",
|
|
44
44
|
"viem": "2.9.25"
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {}
|
|
@@ -9,7 +9,6 @@ var webauthnStamper = require('@turnkey/webauthn-stamper');
|
|
|
9
9
|
var http = require('@turnkey/http');
|
|
10
10
|
var solana = require('@turnkey/solana');
|
|
11
11
|
var iframeStamper = require('@turnkey/iframe-stamper');
|
|
12
|
-
var walletConnectorCore = require('@dynamic-labs/wallet-connector-core');
|
|
13
12
|
var rpcProviderSolana = require('@dynamic-labs/rpc-provider-solana');
|
|
14
13
|
var utils = require('@dynamic-labs/utils');
|
|
15
14
|
var solanaUtils = require('@dynamic-labs/solana-utils');
|
|
@@ -233,8 +232,7 @@ class TurnkeySolanaWalletConnector extends embeddedWallet.TurnkeyWalletConnector
|
|
|
233
232
|
yield account.addSignature(transaction, address);
|
|
234
233
|
}
|
|
235
234
|
catch (err) {
|
|
236
|
-
if (err.message.includes(
|
|
237
|
-
err.message.includes(embeddedWallet.TURNKEY_API_KEY_NOT_FOUND_MESSAGE)) {
|
|
235
|
+
if (embeddedWallet.TURNKEY_SDK_SESSION_KEY_RETRYABLE_ERRORS.some((errorMsg) => err.message.includes(errorMsg))) {
|
|
238
236
|
yield this.removeSessionKeys();
|
|
239
237
|
yield this.createOrRestoreSession({
|
|
240
238
|
ignoreRestore: true,
|
|
@@ -243,7 +241,7 @@ class TurnkeySolanaWalletConnector extends embeddedWallet.TurnkeyWalletConnector
|
|
|
243
241
|
yield account.addSignature(transaction, address);
|
|
244
242
|
}
|
|
245
243
|
else {
|
|
246
|
-
|
|
244
|
+
embeddedWallet.logger.error('[TK] failed to perform activity', err);
|
|
247
245
|
throw err;
|
|
248
246
|
}
|
|
249
247
|
}
|
|
@@ -5,11 +5,10 @@ import { WebauthnStamper } from '@turnkey/webauthn-stamper';
|
|
|
5
5
|
import { TurnkeyClient } from '@turnkey/http';
|
|
6
6
|
import { TurnkeySigner } from '@turnkey/solana';
|
|
7
7
|
import { IframeStamper } from '@turnkey/iframe-stamper';
|
|
8
|
-
import { logger } from '@dynamic-labs/wallet-connector-core';
|
|
9
8
|
import { ProviderChain } from '@dynamic-labs/rpc-provider-solana';
|
|
10
9
|
import { DynamicError, getTLD, PlatformService, bufferToBase64 } from '@dynamic-labs/utils';
|
|
11
10
|
import { SolanaUiTransaction } from '@dynamic-labs/solana-utils';
|
|
12
|
-
import { TurnkeyWalletConnectorBase, findTurnkeyVerifiedCredential, PasskeyService, TURNKEY_API_BASE_URL,
|
|
11
|
+
import { TurnkeyWalletConnectorBase, findTurnkeyVerifiedCredential, PasskeyService, TURNKEY_API_BASE_URL, TURNKEY_SDK_SESSION_KEY_RETRYABLE_ERRORS, logger } from '@dynamic-labs/embedded-wallet';
|
|
13
12
|
import { createSolanaConnection } from '../utils/createSolanaConnection/createSolanaConnection.js';
|
|
14
13
|
import { getGenesisHashLSKey } from '../utils/getGenesisHashLSKey/getGenesisHashLSKey.js';
|
|
15
14
|
import { decodeTransaction, getTotalSolanaSpend, summarizeTransactionDecodedData } from '../utils/transactionDecoder/transactionDecoder.js';
|
|
@@ -229,8 +228,7 @@ class TurnkeySolanaWalletConnector extends TurnkeyWalletConnectorBase {
|
|
|
229
228
|
yield account.addSignature(transaction, address);
|
|
230
229
|
}
|
|
231
230
|
catch (err) {
|
|
232
|
-
if (err.message.includes(
|
|
233
|
-
err.message.includes(TURNKEY_API_KEY_NOT_FOUND_MESSAGE)) {
|
|
231
|
+
if (TURNKEY_SDK_SESSION_KEY_RETRYABLE_ERRORS.some((errorMsg) => err.message.includes(errorMsg))) {
|
|
234
232
|
yield this.removeSessionKeys();
|
|
235
233
|
yield this.createOrRestoreSession({
|
|
236
234
|
ignoreRestore: true,
|