-
Notifications
You must be signed in to change notification settings - Fork 237
feat: add RWA filter list #782
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Changes from all commits
0793244
93def53
7de2f86
f58388a
cdd1338
e379163
a15e26f
e17d128
84314c6
e4ed504
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| { | ||
| "name": "@enkryptcom/hw-wallets", | ||
| "version": "0.0.13", | ||
| "version": "0.0.16", | ||
| "description": "Hardware wallet manager for enkrypt", | ||
| "type": "module", | ||
| "main": "src/index.ts", | ||
|
|
@@ -22,22 +22,22 @@ | |
| "node": ">=14.15.0" | ||
| }, | ||
| "devDependencies": { | ||
| "@types/node": "^24.10.2", | ||
| "@typescript-eslint/eslint-plugin": "^8.49.0", | ||
| "@typescript-eslint/parser": "^8.49.0", | ||
| "eslint": "^9.39.1", | ||
| "@types/node": "^25.0.10", | ||
| "@typescript-eslint/eslint-plugin": "^8.54.0", | ||
| "@typescript-eslint/parser": "^8.54.0", | ||
| "eslint": "^9.39.2", | ||
| "eslint-config-airbnb-base": "^15.0.0", | ||
| "eslint-config-prettier": "^10.1.8", | ||
| "eslint-import-resolver-alias": "^1.1.2", | ||
| "eslint-plugin-import": "^2.32.0", | ||
| "eslint-plugin-module-resolver": "^1.5.0", | ||
| "prettier": "^3.7.4", | ||
| "prettier": "^3.8.1", | ||
| "ts-node": "^10.9.2", | ||
| "tsconfig-paths": "^4.2.0", | ||
| "tsup": "^8.5.1", | ||
| "typescript": "^5.9.3", | ||
| "typescript-eslint": "8.49.0", | ||
| "vitest": "^4.0.15" | ||
| "typescript-eslint": "8.54.0", | ||
| "vitest": "^4.0.18" | ||
| }, | ||
| "repository": { | ||
| "type": "git", | ||
|
|
@@ -52,24 +52,24 @@ | |
| "@ethereumjs/rlp": "^5.0.2", | ||
| "@ethereumjs/tx": "^5.4.0", | ||
| "@ethereumjs/util": "^9.1.0", | ||
| "@ledgerhq/hw-app-btc": "^10.13.0", | ||
| "@ledgerhq/hw-app-eth": "^6.47.1", | ||
| "@ledgerhq/hw-app-solana": "^7.6.0", | ||
| "@ledgerhq/hw-transport": "^6.31.13", | ||
| "@ledgerhq/hw-transport-webusb": "^6.29.13", | ||
| "@ledgerhq/hw-app-btc": "^10.17.0", | ||
| "@ledgerhq/hw-app-eth": "^7.3.1", | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🌐 Web query:
💡 Result: I couldn’t find any official “v7 breaking changes / migration guide” specifically for Practical way to build your own v6 → v7 migration checklist (works even without a guide)
If you paste:
I can turn that into an exact, line-by-line migration patch. Sources: [1] [2] [3] 🏁 Script executed: # Find all files that import or use `@ledgerhq/hw-app-eth`
rg "@ledgerhq/hw-app-eth" --type json --type js --type ts -B 2 -A 2Repository: enkryptcom/enKrypt Length of output: 1208 🏁 Script executed: # Check if there are any version-specific comments or compatibility notes in the codebase
rg "hw-app-eth|ledgerhq.*eth" -A 3 -B 3Repository: enkryptcom/enKrypt Length of output: 3454 🌐 Web query:
💡 Result: In @ledgerhq/hw-app-eth@7.3.1, you should not deep-import Use: import Eth, { ledgerService } from "@ledgerhq/hw-app-eth";Sources: jsDelivr shows the package version 7.3.1 [3], and the README examples show References: Citations:
🏁 Script executed: # Check the actual structure and exports of the installed package
# Look for any TypeScript errors or build warnings
rg "lib/services/ledger" --type ts --type js -B 3 -A 3Repository: enkryptcom/enKrypt Length of output: 716 🏁 Script executed: # Search for any error messages, issues, or discussions about this import in commits/PRs
git log --all --oneline | head -20Repository: enkryptcom/enKrypt Length of output: 196 🏁 Script executed: # Check if there's a tsconfig or build configuration that might indicate issues
find . -name "tsconfig.json" -o -name ".eslintrc*" -o -name "vite.config*" | head -5Repository: enkryptcom/enKrypt Length of output: 254 🏁 Script executed: # Check for any build or test output that might reveal errors with the hw-app-eth import
rg "hw-app-eth|ledgerService" --type log --type txt 2>/dev/null | head -20Repository: enkryptcom/enKrypt Length of output: 44 The deep import path is incompatible with v7.x and will fail at runtime. Version 7.3.1 enforces strict package exports that disallow the current deep import: Fix: Update Import change required- import ledgerService from "@ledgerhq/hw-app-eth/lib/services/ledger";
- import EthApp from "@ledgerhq/hw-app-eth";
+ import EthApp, { ledgerService } from "@ledgerhq/hw-app-eth";🤖 Prompt for AI Agents |
||
| "@ledgerhq/hw-app-solana": "^7.7.0", | ||
| "@ledgerhq/hw-transport": "^6.32.0", | ||
| "@ledgerhq/hw-transport-webusb": "^6.30.0", | ||
| "@ledgerhq/live-common": "^34.20.0", | ||
| "@metamask/eth-sig-util": "^8.2.0", | ||
| "@polkadot/types": "^16.5.4", | ||
| "@polkadot/util": "^14.0.1", | ||
| "@trezor/connect": "^9.6.4", | ||
| "@trezor/connect-plugin-ethereum": "^9.1.3", | ||
| "@trezor/connect-web": "^9.6.4", | ||
| "@trezor/connect-webextension": "^9.6.4", | ||
| "@zondax/ledger-substrate": "^2.0.0", | ||
| "@trezor/connect": "^9.7.1", | ||
| "@trezor/connect-plugin-ethereum": "^9.1.5", | ||
| "@trezor/connect-web": "^9.7.1", | ||
| "@trezor/connect-webextension": "^9.7.1", | ||
| "@zondax/ledger-substrate": "^2.1.2", | ||
| "bitcoinjs-lib": "^6.1.7", | ||
| "bs58": "^6.0.0", | ||
| "hdkey": "^2.1.0", | ||
| "ledger-bitcoin": "^0.2.3", | ||
| "ledger-bitcoin": "^0.3.0", | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🌐 Web query:
💡 Result: I couldn’t find any official 0.3.0 changelog / release notes / “breaking changes” for the What is publicly confirmed:
If you need to identify breaking changes for an upgrade, the practical approach is to diff the upstream source corresponding to that release (often tagged in the upstream repo) against the previous version and scan API changes; however, I wasn’t able to retrieve a public “0.3.0 release notes” page directly from the available sources during this lookup. Sources Citations: 🌐 Web query:
💡 Result: The “ledger-bitcoin” Python package ( Relevant source folders inside that repo include:
Repo (source code): Legacy (older) Bitcoin app source code repo: In |
||
| "webextension-polyfill": "^0.12.0" | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -16,14 +16,15 @@ const getTrezorConnect = async () => { | |||||
| } else { | ||||||
| const TrezorConnect = ((await import("@trezor/connect-web")) as any) | ||||||
| .default; | ||||||
| await TrezorConnect.default.init({ | ||||||
| const initFunc = TrezorConnect.init ? TrezorConnect : TrezorConnect.default; | ||||||
| await initFunc.init({ | ||||||
| lazyLoad: true, | ||||||
| manifest: { | ||||||
| email: "info@enkrypt.com", | ||||||
| appUrl: "http://www.myetherwallet.com", | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Manifest appUrl references MyEtherWallet instead of Enkrypt. The Suggested fix manifest: {
email: "info@enkrypt.com",
- appUrl: "http://www.myetherwallet.com",
+ appUrl: "https://www.enkrypt.com",
},📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||
| }, | ||||||
| }); | ||||||
| return TrezorConnect.default as TrezorConnectType; | ||||||
| return initFunc as TrezorConnectType; | ||||||
|
Comment on lines
17
to
+27
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: # Find the complete trezorConnect.ts file to understand full context
find . -name "trezorConnect.ts" -type f | head -5Repository: enkryptcom/enKrypt Length of output: 111 🏁 Script executed: # Search for TrezorConnect usage patterns in the codebase
rg -n "TrezorConnect" --type ts -A 3 -B 3 -g '!node_modules' | head -100Repository: enkryptcom/enKrypt Length of output: 7851 🏁 Script executed: # Check package.json for `@trezor/connect-web` version
rg '"@trezor/connect-web"' --type jsonRepository: enkryptcom/enKrypt Length of output: 131 🏁 Script executed: # Look at imports and usage of the trezorConnect module itself
rg -n "from.*trezorConnect\|import.*trezorConnect" --type ts -A 3 -B 3Repository: enkryptcom/enKrypt Length of output: 44 🏁 Script executed: # Read the complete trezorConnect.ts file
cat -n packages/hw-wallets/src/trezor/trezorConnect.tsRepository: enkryptcom/enKrypt Length of output: 1323 🏁 Script executed: # Check for TrezorConnectType definition and imports in the file
rg -n "TrezorConnectType|import" packages/hw-wallets/src/trezor/trezorConnect.tsRepository: enkryptcom/enKrypt Length of output: 395 🏁 Script executed: # Check if there are any tests for trezorConnect.ts
find . -name "*trezor*test*" -o -name "*test*trezor*" -type f | grep -v node_modules | head -20Repository: enkryptcom/enKrypt Length of output: 44 🏁 Script executed: # Search for `@trezor/connect-web` documentation or type definitions if available locally
find . -path "*/node_modules/@trezor/connect-web*" -name "*.d.ts" -o -name "package.json" 2>/dev/null | grep -v ".map" | head -5Repository: enkryptcom/enKrypt Length of output: 218 🏁 Script executed: # Check if there's any documentation or comments about the module structure in the codebase
rg -n "trezor.*init|@trezor/connect" packages/ -A 2 -B 2 --type ts --type js | grep -E "(init|connect|default)" | head -30Repository: enkryptcom/enKrypt Length of output: 2130 🏁 Script executed: # Check the webextension branch to see how it handles the same scenario
rg -n "@trezor/connect-webextension" packages/hw-wallets/src/trezor/ -A 10 -B 2Repository: enkryptcom/enKrypt Length of output: 1252 🌐 Web query:
💡 Result: In @trezor/connect-web 9.7.1, the published package is CJS-first:
Practical interop guidanceCJS (require): const TrezorConnect = require('@trezor/connect-web');ESM (Node / bundlers): prefer default import or namespace import import TrezorConnect from '@trezor/connect-web';
// or
import * as TrezorConnect from '@trezor/connect-web';If you need named exports, import them from the source package that actually defines them: import { UI_EVENT } from '@trezor/connect/lib/exports';Sources: [1] [2] 🏁 Script executed: # Check if there are any actual error logs or issues related to this code path
rg -n "initFunc|TrezorConnect.*default" packages/hw-wallets/ --type ts -B 3 -A 3Repository: enkryptcom/enKrypt Length of output: 2248 🏁 Script executed: # Look at how the function is called and if there's any error handling around it
rg -n "getTrezorConnect\(\)" packages/hw-wallets/ --type ts -B 5 -A 5Repository: enkryptcom/enKrypt Length of output: 2584 Add defensive check for undefined Line 19's fallback logic ( Suggested improvements const TrezorConnect = ((await import("@trezor/connect-web")) as any)
.default;
const initFunc = TrezorConnect.init ? TrezorConnect : TrezorConnect.default;
+ if (!initFunc?.init) {
+ throw new Error("Failed to resolve TrezorConnect init function");
+ }
await initFunc.init({
lazyLoad: true,
manifest: {
email: "info@enkrypt.com",
- appUrl: "http://www.myetherwallet.com",
+ appUrl: "https://www.enkrypt.com",
},
});🤖 Prompt for AI Agents |
||||||
| } | ||||||
| }; | ||||||
|
|
||||||
|
|
||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: enkryptcom/enKrypt
Length of output: 1180
Inconsistent
@types/nodeversion across packages.This package uses
@types/node: ^25.0.10, but most other packages in the monorepo use^22.19.7(name-resolution, keyring, types, storage, utils, signers/massa, swap, extension-bridge, request, extension). Only five packages share the ^25.0.10 version (hw-wallets, signers/bitcoin, signers/polkadot, signers/ethereum, signers/kadena). This major version mismatch should be reconciled to prevent type definition inconsistencies and potential build issues. Consider aligning with the majority version or document the reason for the divergence.🤖 Prompt for AI Agents