@pioneer-platform/pioneer-sdk 8.15.24 → 8.15.27

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 CHANGED
@@ -538,7 +538,7 @@ async function fetchStableCoins(pioneer, primaryAddress, blockchains, balances,
538
538
  };
539
539
  const results = await Promise.allSettled(networksToCheck.map(async (networkId) => {
540
540
  try {
541
- const response = await withTimeout2(pioneer.GetStableCoins({ networkId, address: primaryAddress }), 2000);
541
+ const response = await withTimeout2(pioneer.GetStableCoins({ networkId, address: primaryAddress }), 5000);
542
542
  const stableCoins = response?.data?.tokens || [];
543
543
  console.log(tag2, `Found ${stableCoins.length} stable coins on ${networkId}`);
544
544
  for (const token of stableCoins) {
@@ -1006,6 +1006,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1006
1006
  "bip122:00000000001a91e3dace36e2be3bf030": "UTXO",
1007
1007
  "bip122:12a765e31ffd4059bada1e25190f6e98": "UTXO",
1008
1008
  "bip122:4da631f2ac1bed857bd968c67c913978": "UTXO",
1009
+ "bip122:00040fe8ec8471911baa1db1266ea15d": "UTXO",
1009
1010
  "cosmos:mayachain-mainnet-v1": "MAYACHAIN",
1010
1011
  "cosmos:osmosis-1": "OSMOSIS",
1011
1012
  "cosmos:cosmoshub-4": "COSMOS",
@@ -1015,6 +1016,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1015
1016
  "eip155:137": "EVM",
1016
1017
  "eip155:*": "EVM",
1017
1018
  "ripple:4109c6f2045fc7eff4cde8f9905d19c2": "XRP",
1019
+ "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp": "SOLANA",
1018
1020
  "zcash:main": "UTXO"
1019
1021
  };
1020
1022
  const networkType = networkIdToType[networkId];
@@ -1045,6 +1047,9 @@ var getPubkey = async (networkId, path, sdk, context) => {
1045
1047
  case "XRP":
1046
1048
  ({ address } = await sdk.address.xrpGetAddress(addressInfo));
1047
1049
  break;
1050
+ case "SOLANA":
1051
+ console.warn(`⚠️ Solana address derivation not yet supported by KeepKey SDK. Skipping ${networkId}`);
1052
+ return null;
1048
1053
  default:
1049
1054
  throw new Error(`Unsupported network type for networkId: ${networkId}`);
1050
1055
  }
@@ -1128,6 +1133,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1128
1133
  pubkey.path = import_pioneer_coins.addressNListToBIP32(path.addressNList);
1129
1134
  pubkey.pathMaster = import_pioneer_coins.addressNListToBIP32(path.addressNListMaster);
1130
1135
  }
1136
+ pubkey.symbol = chain;
1131
1137
  pubkey.scriptType = path.script_type;
1132
1138
  pubkey.note = path.note;
1133
1139
  pubkey.available_scripts_types = path.available_scripts_types;
@@ -4460,7 +4466,8 @@ async function syncPubkeysForBlockchains(blockchains, paths, existingPubkeys, ke
4460
4466
  logger2.debug(tag, `Fetching pubkey for path ${pathBip32}...`);
4461
4467
  const newPubkey = await getPubkeyFn(blockchain, path, keepKeySdk, context);
4462
4468
  if (!newPubkey) {
4463
- throw new Error(`Pubkey fetch failed for ${networkId} at path ${pathBip32}. ` + `Ensure hardware wallet is connected and unlocked.`);
4469
+ logger2.warn(tag, `Skipping unsupported path ${pathBip32} for ${networkId}`);
4470
+ continue;
4464
4471
  }
4465
4472
  addPubkeyCallback(newPubkey);
4466
4473
  logger2.debug(tag, `✓ Added pubkey for ${pathBip32}`);
package/dist/index.es.js CHANGED
@@ -529,7 +529,7 @@ async function fetchStableCoins(pioneer, primaryAddress, blockchains, balances,
529
529
  };
530
530
  const results = await Promise.allSettled(networksToCheck.map(async (networkId) => {
531
531
  try {
532
- const response = await withTimeout2(pioneer.GetStableCoins({ networkId, address: primaryAddress }), 2000);
532
+ const response = await withTimeout2(pioneer.GetStableCoins({ networkId, address: primaryAddress }), 5000);
533
533
  const stableCoins = response?.data?.tokens || [];
534
534
  console.log(tag2, `Found ${stableCoins.length} stable coins on ${networkId}`);
535
535
  for (const token of stableCoins) {
@@ -1190,6 +1190,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1190
1190
  "bip122:00000000001a91e3dace36e2be3bf030": "UTXO",
1191
1191
  "bip122:12a765e31ffd4059bada1e25190f6e98": "UTXO",
1192
1192
  "bip122:4da631f2ac1bed857bd968c67c913978": "UTXO",
1193
+ "bip122:00040fe8ec8471911baa1db1266ea15d": "UTXO",
1193
1194
  "cosmos:mayachain-mainnet-v1": "MAYACHAIN",
1194
1195
  "cosmos:osmosis-1": "OSMOSIS",
1195
1196
  "cosmos:cosmoshub-4": "COSMOS",
@@ -1199,6 +1200,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1199
1200
  "eip155:137": "EVM",
1200
1201
  "eip155:*": "EVM",
1201
1202
  "ripple:4109c6f2045fc7eff4cde8f9905d19c2": "XRP",
1203
+ "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp": "SOLANA",
1202
1204
  "zcash:main": "UTXO"
1203
1205
  };
1204
1206
  const networkType = networkIdToType[networkId];
@@ -1229,6 +1231,9 @@ var getPubkey = async (networkId, path, sdk, context) => {
1229
1231
  case "XRP":
1230
1232
  ({ address } = await sdk.address.xrpGetAddress(addressInfo));
1231
1233
  break;
1234
+ case "SOLANA":
1235
+ console.warn(`⚠️ Solana address derivation not yet supported by KeepKey SDK. Skipping ${networkId}`);
1236
+ return null;
1232
1237
  default:
1233
1238
  throw new Error(`Unsupported network type for networkId: ${networkId}`);
1234
1239
  }
@@ -1312,6 +1317,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1312
1317
  pubkey.path = addressNListToBIP32(path.addressNList);
1313
1318
  pubkey.pathMaster = addressNListToBIP32(path.addressNListMaster);
1314
1319
  }
1320
+ pubkey.symbol = chain;
1315
1321
  pubkey.scriptType = path.script_type;
1316
1322
  pubkey.note = path.note;
1317
1323
  pubkey.available_scripts_types = path.available_scripts_types;
@@ -4644,7 +4650,8 @@ async function syncPubkeysForBlockchains(blockchains, paths, existingPubkeys, ke
4644
4650
  logger2.debug(tag, `Fetching pubkey for path ${pathBip32}...`);
4645
4651
  const newPubkey = await getPubkeyFn(blockchain, path, keepKeySdk, context);
4646
4652
  if (!newPubkey) {
4647
- throw new Error(`Pubkey fetch failed for ${networkId} at path ${pathBip32}. ` + `Ensure hardware wallet is connected and unlocked.`);
4653
+ logger2.warn(tag, `Skipping unsupported path ${pathBip32} for ${networkId}`);
4654
+ continue;
4648
4655
  }
4649
4656
  addPubkeyCallback(newPubkey);
4650
4657
  logger2.debug(tag, `✓ Added pubkey for ${pathBip32}`);
package/dist/index.js CHANGED
@@ -529,7 +529,7 @@ async function fetchStableCoins(pioneer, primaryAddress, blockchains, balances,
529
529
  };
530
530
  const results = await Promise.allSettled(networksToCheck.map(async (networkId) => {
531
531
  try {
532
- const response = await withTimeout2(pioneer.GetStableCoins({ networkId, address: primaryAddress }), 2000);
532
+ const response = await withTimeout2(pioneer.GetStableCoins({ networkId, address: primaryAddress }), 5000);
533
533
  const stableCoins = response?.data?.tokens || [];
534
534
  console.log(tag2, `Found ${stableCoins.length} stable coins on ${networkId}`);
535
535
  for (const token of stableCoins) {
@@ -1190,6 +1190,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1190
1190
  "bip122:00000000001a91e3dace36e2be3bf030": "UTXO",
1191
1191
  "bip122:12a765e31ffd4059bada1e25190f6e98": "UTXO",
1192
1192
  "bip122:4da631f2ac1bed857bd968c67c913978": "UTXO",
1193
+ "bip122:00040fe8ec8471911baa1db1266ea15d": "UTXO",
1193
1194
  "cosmos:mayachain-mainnet-v1": "MAYACHAIN",
1194
1195
  "cosmos:osmosis-1": "OSMOSIS",
1195
1196
  "cosmos:cosmoshub-4": "COSMOS",
@@ -1199,6 +1200,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1199
1200
  "eip155:137": "EVM",
1200
1201
  "eip155:*": "EVM",
1201
1202
  "ripple:4109c6f2045fc7eff4cde8f9905d19c2": "XRP",
1203
+ "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp": "SOLANA",
1202
1204
  "zcash:main": "UTXO"
1203
1205
  };
1204
1206
  const networkType = networkIdToType[networkId];
@@ -1229,6 +1231,9 @@ var getPubkey = async (networkId, path, sdk, context) => {
1229
1231
  case "XRP":
1230
1232
  ({ address } = await sdk.address.xrpGetAddress(addressInfo));
1231
1233
  break;
1234
+ case "SOLANA":
1235
+ console.warn(`⚠️ Solana address derivation not yet supported by KeepKey SDK. Skipping ${networkId}`);
1236
+ return null;
1232
1237
  default:
1233
1238
  throw new Error(`Unsupported network type for networkId: ${networkId}`);
1234
1239
  }
@@ -1312,6 +1317,7 @@ var getPubkey = async (networkId, path, sdk, context) => {
1312
1317
  pubkey.path = addressNListToBIP32(path.addressNList);
1313
1318
  pubkey.pathMaster = addressNListToBIP32(path.addressNListMaster);
1314
1319
  }
1320
+ pubkey.symbol = chain;
1315
1321
  pubkey.scriptType = path.script_type;
1316
1322
  pubkey.note = path.note;
1317
1323
  pubkey.available_scripts_types = path.available_scripts_types;
@@ -4644,7 +4650,8 @@ async function syncPubkeysForBlockchains(blockchains, paths, existingPubkeys, ke
4644
4650
  logger2.debug(tag, `Fetching pubkey for path ${pathBip32}...`);
4645
4651
  const newPubkey = await getPubkeyFn(blockchain, path, keepKeySdk, context);
4646
4652
  if (!newPubkey) {
4647
- throw new Error(`Pubkey fetch failed for ${networkId} at path ${pathBip32}. ` + `Ensure hardware wallet is connected and unlocked.`);
4653
+ logger2.warn(tag, `Skipping unsupported path ${pathBip32} for ${networkId}`);
4654
+ continue;
4648
4655
  }
4649
4656
  addPubkeyCallback(newPubkey);
4650
4657
  logger2.debug(tag, `✓ Added pubkey for ${pathBip32}`);
package/package.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "author": "highlander",
3
3
  "name": "@pioneer-platform/pioneer-sdk",
4
- "version": "8.15.24",
4
+ "version": "8.15.27",
5
5
  "dependencies": {
6
6
  "@keepkey/keepkey-sdk": "^0.2.62",
7
- "@pioneer-platform/pioneer-caip": "^9.10.2",
7
+ "@pioneer-platform/pioneer-caip": "^9.10.5",
8
8
  "@pioneer-platform/pioneer-client": "^9.10.12",
9
- "@pioneer-platform/pioneer-coins": "^9.11.2",
10
- "@pioneer-platform/pioneer-discovery": "^8.15.17",
11
- "@pioneer-platform/pioneer-events": "^8.12.0",
9
+ "@pioneer-platform/pioneer-coins": "^9.11.5",
10
+ "@pioneer-platform/pioneer-discovery": "^8.15.27",
11
+ "@pioneer-platform/pioneer-events": "^8.12.2",
12
12
  "coinselect": "^3.1.13",
13
13
  "eventemitter3": "^5.0.1",
14
14
  "neotraverse": "^0.6.8",
package/src/charts/evm.ts CHANGED
@@ -320,13 +320,13 @@ async function fetchStableCoins(
320
320
  });
321
321
  };
322
322
 
323
- // Fetch stable coins for each network in parallel with short timeouts
323
+ // Fetch stable coins for each network in parallel with timeouts
324
324
  const results = await Promise.allSettled(
325
325
  networksToCheck.map(async (networkId) => {
326
326
  try {
327
327
  const response = await withTimeout(
328
328
  pioneer.GetStableCoins({ networkId, address: primaryAddress }),
329
- 2000
329
+ 5000 // Increased from 2000ms to 5000ms to reduce timeout errors
330
330
  );
331
331
  const stableCoins = response?.data?.tokens || [];
332
332
  console.log(tag, `Found ${stableCoins.length} stable coins on ${networkId}`);
package/src/getPubkey.ts CHANGED
@@ -28,6 +28,7 @@ export const getPubkey = async (networkId: string, path: any, sdk: any, context:
28
28
  'bip122:00000000001a91e3dace36e2be3bf030': 'UTXO', // Dogecoin
29
29
  'bip122:12a765e31ffd4059bada1e25190f6e98': 'UTXO', // Litecoin
30
30
  'bip122:4da631f2ac1bed857bd968c67c913978': 'UTXO', // DigiByte
31
+ 'bip122:00040fe8ec8471911baa1db1266ea15d': 'UTXO', // Zcash
31
32
  'cosmos:mayachain-mainnet-v1': 'MAYACHAIN',
32
33
  'cosmos:osmosis-1': 'OSMOSIS',
33
34
  'cosmos:cosmoshub-4': 'COSMOS',
@@ -37,6 +38,7 @@ export const getPubkey = async (networkId: string, path: any, sdk: any, context:
37
38
  'eip155:137': 'EVM',
38
39
  'eip155:*': 'EVM',
39
40
  'ripple:4109c6f2045fc7eff4cde8f9905d19c2': 'XRP',
41
+ 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp': 'SOLANA', // Solana (not yet supported by KeepKey)
40
42
  'zcash:main': 'UTXO',
41
43
  };
42
44
 
@@ -70,6 +72,9 @@ export const getPubkey = async (networkId: string, path: any, sdk: any, context:
70
72
  case 'XRP':
71
73
  ({ address } = await sdk.address.xrpGetAddress(addressInfo));
72
74
  break;
75
+ case 'SOLANA':
76
+ console.warn(`⚠️ Solana address derivation not yet supported by KeepKey SDK. Skipping ${networkId}`);
77
+ return null; // Skip Solana for now until KeepKey SDK supports it
73
78
  default:
74
79
  throw new Error(`Unsupported network type for networkId: ${networkId}`);
75
80
  }
@@ -167,6 +172,7 @@ export const getPubkey = async (networkId: string, path: any, sdk: any, context:
167
172
  pubkey.pathMaster = addressNListToBIP32(path.addressNListMaster);
168
173
  }
169
174
 
175
+ pubkey.symbol = chain; // Add symbol for balance lookups
170
176
  pubkey.scriptType = path.script_type;
171
177
  pubkey.note = path.note;
172
178
  pubkey.available_scripts_types = path.available_scripts_types;
@@ -41,10 +41,8 @@ export async function syncPubkeysForBlockchains(
41
41
  const newPubkey = await getPubkeyFn(blockchain, path, keepKeySdk, context);
42
42
 
43
43
  if (!newPubkey) {
44
- throw new Error(
45
- `Pubkey fetch failed for ${networkId} at path ${pathBip32}. ` +
46
- `Ensure hardware wallet is connected and unlocked.`
47
- );
44
+ log.warn(tag, `Skipping unsupported path ${pathBip32} for ${networkId}`);
45
+ continue; // Skip unsupported chains (e.g., Solana until KeepKey SDK supports it)
48
46
  }
49
47
 
50
48
  addPubkeyCallback(newPubkey);