feat(sdk): add trezor support via RPC and SDK wrappers#77
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the WalkthroughThis update introduces comprehensive support for Trezor hardware wallet integration within the Komodo DeFi SDK and example application. It adds new managers, state management, RPC interfaces, and UI flows for Trezor device initialization and authentication. The authentication system is refactored to use the Bloc pattern, and pubkey strategy selection is updated to consider user-specific key policies. Changes
Sequence Diagram(s)Trezor Device Initialization FlowsequenceDiagram
participant UI
participant AuthBloc
participant TrezorManager
participant ApiClient
UI->>AuthBloc: Dispatch AuthTrezorInitAndAuth event
AuthBloc->>TrezorManager: initializeDevice()
TrezorManager->>ApiClient: Start Trezor init task (RPC)
ApiClient-->>TrezorManager: New taskId
loop Polling
TrezorManager->>ApiClient: Get Trezor status (taskId)
ApiClient-->>TrezorManager: Status response (in progress, user action, completed, error)
TrezorManager-->>AuthBloc: Stream TrezorInitializationState
AuthBloc-->>UI: Emit AuthState (e.g., pinRequired, passphraseRequired, ready)
alt User action required
UI->>AuthBloc: Dispatch AuthTrezorProvidePin/Passphrase event
AuthBloc->>TrezorManager: providePin/providePassphrase(taskId, input)
TrezorManager->>ApiClient: Send PIN/Passphrase (RPC)
end
alt Cancel requested
UI->>AuthBloc: Dispatch AuthTrezorCancel event
AuthBloc->>TrezorManager: cancelInitialization(taskId)
TrezorManager->>ApiClient: Cancel task (RPC)
TrezorManager-->>AuthBloc: Stream cancelled state
end
end
Pubkey Strategy SelectionsequenceDiagram
participant PubkeyManager
participant Asset
participant KdfUser
PubkeyManager->>KdfUser: Get current user
PubkeyManager->>Asset: asset.pubkeyStrategy(kdfUser)
Asset->>PubkeyStrategyFactory: createStrategy(protocol, kdfUser)
alt kdfUser.walletId.authOptions.privKeyPolicy == trezor
PubkeyStrategyFactory-->>Asset: TrezorHDWalletStrategy(kdfUser)
else kdfUser.walletId.authOptions.privKeyPolicy == contextPrivKey
PubkeyStrategyFactory-->>Asset: ContextPrivKeyHDWalletStrategy(kdfUser)
end
Suggested reviewers
Poem
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
Visit the preview URL for this PR (updated for commit db797af): https://komodo-defi-sdk--pr77-feat-trezor-support-wp8z6xhx.web.app (expires Fri, 20 Jun 2025 00:28:13 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: 7f9f5ac39928f333b6e8fcefb7138575e24ed347 |
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Actionable comments posted: 23
🔭 Outside diff range comments (2)
packages/komodo_defi_sdk/lib/komodo_defi_sdk.dart (1)
6-6:⚠️ Potential issueFix invalid
librarydirective
The statementlibrary;is syntactically incorrect. Either remove the directive or specify a valid name (e.g.,library komodo_defi_sdk;).packages/komodo_defi_rpc_methods/lib/src/rpc_methods_library.dart (1)
26-26: 💡 Verification agent🧩 Analysis chain
Potential breaking change: HdWalletMethods getter removed.
The removal of the
hdWalletgetter fromKomodoDefiRpcMethodscould break existing code that depends on this API.Please verify that:
- A replacement for the removed
hdWalletgetter exists and is properly exported- All existing code using
rpcMethods.hdWallethas been updated
🏁 Script executed:
#!/bin/bash # Description: Check for usage of the removed hdWallet getter and verify replacement exists # Expected: Find usages that need updating and confirm new implementation exists echo "Searching for usage of hdWallet getter..." rg -A 2 "\.hdWallet\." --type dart echo -e "\nSearching for new HdWalletMethods class definition..." rg "class HdWalletMethods" --type dart echo -e "\nSearching for HdWalletMethods exports..." rg "export.*HdWalletMethods" --type dartLength of output: 3332
Restore or re-export HdWalletMethods to prevent breaking changes
The
hdWalletgetter was removed fromKomodoDefiRpcMethods, but existing code still callsclient.rpc.hdWallet…, and althoughHdWalletMethodsis defined, it isn’t exported. This will break downstream code.• In
packages/komodo_defi_rpc_methods/lib/src/rpc_methods_library.dart(around line 26), thehdWalletgetter was removed.
• Usage remains in:
packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dartpackages/komodo_defi_rpc_methods/lib/src/strategies/balance/hd_wallet_balance_strategy.dart
•class HdWalletMethodsexists inlib/src/rpc_methods/hd_wallet/hd_wallet_methods.dartbut is never exported.Suggested fix—either re-add the getter or export the namespace so calls to
client.rpc.hdWalletresolve:--- a/packages/komodo_defi_rpc_methods/lib/src/rpc_methods_library.dart +++ b/packages/komodo_defi_rpc_methods/lib/src/rpc_methods_library.dart @@ -23,6 +23,7 @@ TrezorMethodsNamespace get trezor => TrezorMethodsNamespace(_client); + HdWalletMethods get hdWallet => HdWalletMethods(_client); }
🧹 Nitpick comments (13)
packages/komodo_defi_sdk/build.yaml (1)
5-5: Add newline at end of file
YAML lint reports require a trailing newline (new-line-at-end-of-file).🧰 Tools
🪛 YAMLlint (1.37.1)
[error] 5-5: no new line character at the end of file
(new-line-at-end-of-file)
packages/komodo_defi_sdk/lib/komodo_defi_sdk.dart (1)
25-25: Reorder new export for consistency
Place thetrezor_initialization_state.dartexport in alphabetical order or group it with related SDK initializations to maintain a logical export sequence.packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_event.dart (1)
18-29: Consider consolidating similar event classes.
AuthTrezorRegisterandAuthTrezorSignInhave identical structures. Consider using a single event class with anisRegisterflag to reduce code duplication.-/// Event to authenticate with Trezor device -class AuthTrezorSignIn extends AuthEvent { - const AuthTrezorSignIn({ - required this.walletName, - required this.derivationMethod, - }); - - final String walletName; - final DerivationMethod derivationMethod; - - @override - List<Object?> get props => [walletName, derivationMethod]; -} - -/// Event to register a new Trezor wallet -class AuthTrezorRegister extends AuthEvent { - const AuthTrezorRegister({ - required this.walletName, - required this.derivationMethod, - }); - - final String walletName; - final DerivationMethod derivationMethod; - - @override - List<Object?> get props => [walletName, derivationMethod]; -} +/// Event to authenticate or register with Trezor device +class AuthTrezorSignInOrRegister extends AuthEvent { + const AuthTrezorSignInOrRegister({ + required this.walletName, + required this.derivationMethod, + required this.isRegister, + }); + + final String walletName; + final DerivationMethod derivationMethod; + final bool isRegister; + + @override + List<Object?> get props => [walletName, derivationMethod, isRegister]; +}packages/komodo_defi_types/lib/src/public_key/pubkey_strategy.dart (1)
25-50: Consider adding a default case for future-proofing.The refactoring to use
KdfUserimproves the design. However, the switch statement should handle unexpectedPrivateKeyPolicyvalues defensively.switch (privKeyPolicy) { case PrivateKeyPolicy.trezor: return TrezorHDWalletStrategy(kdfUser: kdfUser); case PrivateKeyPolicy.contextPrivKey: return ContextPrivKeyHDWalletStrategy(kdfUser: kdfUser); + default: + throw UnsupportedProtocolException( + 'Unsupported private key policy: $privKeyPolicy', + ); }packages/komodo_defi_sdk/example/lib/widgets/auth/seed_dialog.dart (1)
56-69: Consider more robust mnemonic validationWhile the simplified validation aligns with the bloc architecture refactoring, checking only word count might allow invalid seed phrases to pass through.
Consider adding basic word validation or documenting that comprehensive validation happens in the AuthBloc:
- // Basic validation for plaintext mnemonic + // Basic validation for plaintext mnemonic + // Note: Comprehensive BIP39 validation is performed in AuthBloc final words = mnemonicController.text.trim().split(' '); if (words.length != 12 && words.length != 24) {packages/komodo_defi_sdk/lib/src/trezor/trezor_manager.dart (1)
64-143: Add timeout mechanism to prevent indefinite pollingThe polling loop could run indefinitely if the device never reaches a terminal state.
Consider adding a timeout:
Stream<TrezorInitializationState> initializeDevice({ String? devicePubkey, Duration pollingInterval = const Duration(seconds: 1), + Duration timeout = const Duration(minutes: 5), }) async* { int? taskId; StreamController<TrezorInitializationState>? controller; + final startTime = DateTime.now(); try { // ... existing code ... Future<void> pollStatus() async { if (isComplete || taskId == null) return; + + // Check timeout + if (DateTime.now().difference(startTime) > timeout) { + throw TrezorException('Initialization timeout', 'Operation took longer than $timeout'); + }packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dart (1)
16-20: Address the TODO comment for protocol support.The
protocolSupportedmethod currently returnstruefor all protocols, which may not be accurate. The commented logic suggests UTXO and SLP protocols should be supported.Would you like me to open an issue to track implementing proper protocol validation for HD wallets?
packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_mixin.dart (1)
56-183: Consider adding transaction safety for wallet operations.The method performs multiple async operations (sign out, register/sign in) that could leave the system in an inconsistent state if interrupted. Consider implementing a rollback mechanism or state validation.
Would you like assistance implementing a more robust state management approach that ensures atomicity of the Trezor initialization process?
packages/komodo_defi_sdk/example/lib/blocs/auth/auth_state.dart (1)
44-64: Consider adding error case documentationThe factory constructor handles all the Trezor initialization states correctly, but the error and cancelled cases both return
TrezorAuthStatus.none. Consider adding a comment explaining why these states map tononerather than having separate error/cancelled states inTrezorAuthStatus.case TrezorInitializationStatus.error: case TrezorInitializationStatus.cancelled: + // Error and cancelled states are handled at the AuthStatus level + // rather than maintaining separate Trezor-specific error states return TrezorAuthStatus.none;packages/komodo_defi_sdk/lib/src/trezor/trezor_initialization_state.dart (1)
108-109: Improve case-insensitive string comparisonThe current implementation creates a lowercase copy of the description string on each check. Consider creating it once for better performance.
final descriptionLower = description.toLowerCase(); + // Check for device connection status if (descriptionLower.contains('waiting') && descriptionLower.contains('connect')) {packages/komodo_defi_sdk/example/lib/widgets/instance_manager/instance_view.dart (2)
337-349: Consider using a more persistent notification for device confirmationA SnackBar with 3-second duration might disappear too quickly while the user is interacting with their Trezor device. Consider using a persistent notification or dialog.
} else if (state.isTrezorAwaitingConfirmation) { - // Show a non-blocking message - ScaffoldMessenger.of(context).showSnackBar( - SnackBar( - content: Text( - state.trezorMessage ?? 'Please confirm on your Trezor device', - ), - duration: const Duration(seconds: 3), - ), - ); + // Show a persistent message until state changes + ScaffoldMessenger.of(context).showSnackBar( + SnackBar( + content: Row( + children: [ + const CircularProgressIndicator(strokeWidth: 2), + const SizedBox(width: 12), + Expanded( + child: Text( + state.trezorMessage ?? 'Please confirm on your Trezor device', + ), + ), + ], + ), + duration: const Duration(days: 1), // Effectively persistent + ), + ); }
598-612: Improve Trezor button state managementThe Trezor button shows a loading indicator but doesn't clearly indicate when it's processing. Consider improving the visual feedback.
FilledButton.icon( - onPressed: _isTrezorInitializing ? null : _initializeTrezor, + onPressed: _isTrezorInitializing || isLoading ? null : _initializeTrezor, icon: _isTrezorInitializing ? const SizedBox( width: 16, height: 16, child: CircularProgressIndicator(strokeWidth: 2), ) : const Icon(Icons.security), label: Text( _isTrezorInitializing ? 'Initializing...' : 'Use Trezor', ), ),packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart (1)
1-3: Address the TODO comment to improve API consistency.The TODO comment highlights an important design inconsistency where some RPC methods accept individual parameters while others should use request class objects. This inconsistency can lead to maintenance issues and confusion for developers using the API.
Would you like me to help create a plan to refactor these methods to use a consistent parameter pattern?
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
packages/komodo_defi_sdk/example/pubspec.lockis excluded by!**/*.lock
📒 Files selected for processing (35)
packages/komodo_defi_framework/app_build/build_config.json(1 hunks)packages/komodo_defi_framework/lib/src/operations/kdf_operations_wasm.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/models/models.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/models/task_response_details.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/account_balance.dart(0 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/get_new_address_task.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/rpc_methods.dart(2 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/trezor_rpc_namespace.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods_library.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dart(4 hunks)packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/single_address_strategy.dart(1 hunks)packages/komodo_defi_rpc_methods/pubspec.yaml(1 hunks)packages/komodo_defi_sdk/build.yaml(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/auth_bloc.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/auth_event.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/auth_state.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_event.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_mixin.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/blocs.dart(1 hunks)packages/komodo_defi_sdk/example/lib/main.dart(2 hunks)packages/komodo_defi_sdk/example/lib/screens/auth_screen.dart(3 hunks)packages/komodo_defi_sdk/example/lib/widgets/auth/seed_dialog.dart(4 hunks)packages/komodo_defi_sdk/example/lib/widgets/instance_manager/instance_view.dart(6 hunks)packages/komodo_defi_sdk/example/pubspec.yaml(1 hunks)packages/komodo_defi_sdk/index_generator.yaml(1 hunks)packages/komodo_defi_sdk/lib/komodo_defi_sdk.dart(1 hunks)packages/komodo_defi_sdk/lib/src/_internal_exports.dart(1 hunks)packages/komodo_defi_sdk/lib/src/bootstrap.dart(2 hunks)packages/komodo_defi_sdk/lib/src/komodo_defi_sdk.dart(3 hunks)packages/komodo_defi_sdk/lib/src/pubkeys/pubkey_manager.dart(1 hunks)packages/komodo_defi_sdk/lib/src/trezor/_trezor_index.dart(1 hunks)packages/komodo_defi_sdk/lib/src/trezor/trezor_initialization_state.dart(1 hunks)packages/komodo_defi_sdk/lib/src/trezor/trezor_manager.dart(1 hunks)packages/komodo_defi_types/lib/src/public_key/pubkey_strategy.dart(2 hunks)
💤 Files with no reviewable changes (1)
- packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/account_balance.dart
🧰 Additional context used
🪛 YAMLlint (1.37.1)
packages/komodo_defi_sdk/build.yaml
[error] 5-5: no new line character at the end of file
(new-line-at-end-of-file)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: setup
🔇 Additional comments (45)
packages/komodo_defi_sdk/example/pubspec.yaml (1)
11-11: Dependency added for Bloc state equality
Addingequatable: ^2.0.7to dependencies aligns with the new Bloc-based auth events and states that extendEquatable.packages/komodo_defi_sdk/build.yaml (1)
1-5: Exclude example directory from SDK build
Theexample/**exclusion ensures Flutter-specific example code isn’t included in the core SDK build.🧰 Tools
🪛 YAMLlint (1.37.1)
[error] 5-5: no new line character at the end of file
(new-line-at-end-of-file)
packages/komodo_defi_framework/app_build/build_config.json (1)
66-66: Confirm updated bundled coins commit hash
Thebundled_coins_repo_commitwas bumped tob85229291413f9f9e26ad5b6db2da7f7bfb56ac5. Please verify this hash exists in the coins repo and includes the intended updates.packages/komodo_defi_sdk/example/lib/blocs/blocs.dart (1)
1-1: Export AuthBloc in barrel file
Exposingauth_bloc.dartallows the example app to import and instantiate the newAuthBloc.packages/komodo_defi_rpc_methods/lib/src/models/models.dart (1)
13-13: LGTM: Good consolidation of response handling.Adding the
task_response_details.dartexport centralizes theResponseDetailsclass, eliminating duplication and providing consistent response handling across RPC methods.packages/komodo_defi_rpc_methods/pubspec.yaml (2)
14-15: LGTM: Standard dependencies for code generation.The addition of
freezed_annotationandjson_annotationprovides the necessary annotations for the new data model classes mentioned in the AI summary.
22-25: LGTM: Appropriate dev dependencies for code generation.Adding
build_runner,freezed, andjson_serializableas dev dependencies enables code generation for immutable data classes and JSON serialization, which aligns with the new RPC methods and response classes being introduced.packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/single_address_strategy.dart (1)
31-33: LGTM: Updated comment reflects current architecture.The comment accurately reflects the replacement of the generic
HDWalletStrategywith the more specificContextPrivKeyHDWalletStrategyandTrezorHDWalletStrategy, improving clarity for developers.packages/komodo_defi_sdk/lib/src/_internal_exports.dart (1)
9-9: LGTM: Consistent integration of Trezor module.The export follows the established pattern used by other modules and properly integrates the new Trezor functionality into the SDK's internal exports.
packages/komodo_defi_sdk/lib/src/bootstrap.dart (2)
14-14: LGTM: Proper import for new dependency.The import for
TrezorManageris correctly added to support the new singleton registration.
201-204:Details
✅ Verification successful
LGTM: Proper dependency injection setup.
The
TrezorManagerregistration follows the established pattern with appropriate dependency onApiClient. Ensure thatTrezorManagerdisposal is handled properly in the main SDK class when the SDK is disposed.
🏁 Script executed:
#!/bin/bash # Description: Verify TrezorManager disposal is handled in the main SDK class # Expected: Find dispose method that properly cleans up TrezorManager # Search for TrezorManager disposal in SDK classes rg -A 10 -B 5 "dispose.*trezor|trezor.*dispose" --type dart # Also search for the main SDK class dispose method ast-grep --pattern 'class $_ { $$$ dispose() { $$$ } $$$ }'Length of output: 1435
LGTM: TrezorManager registration and disposal are correctly implemented.
- Verified in
packages/komodo_defi_sdk/lib/src/komodo_defi_sdk.dartwithin thedispose()method:final trezorManager = _container<TrezorManager>(); await trezorManager.dispose();No further changes needed.
packages/komodo_defi_sdk/lib/src/trezor/_trezor_index.dart (1)
1-8: LGTM! Consistent with established patterns.The internal index file follows the SDK's established patterns for modular organization and uses appropriate naming conventions for private/internal libraries.
packages/komodo_defi_sdk/lib/src/komodo_defi_sdk.dart (3)
11-11: LGTM! Import follows established patterns.The TrezorManager import is consistent with other manager imports in the SDK.
243-248: LGTM! Trezor manager getter implementation is consistent.The getter implementation follows the exact same pattern as other managers in the SDK, including proper initialization checks and documentation.
326-332: LGTM! Proper disposal handling with error resilience.The disposal logic correctly handles the case where the TrezorManager might not be initialized, using a try-catch block to prevent disposal failures from affecting other cleanup operations.
packages/komodo_defi_rpc_methods/lib/src/rpc_methods/rpc_methods.dart (2)
36-36:Details
✅ Verification successful
Verify the Trezor RPC namespace export exists and provides expected functionality.
The Trezor RPC namespace export is properly positioned and follows established naming conventions.
🏁 Script executed:
#!/bin/bash # Verify that the Trezor RPC namespace file exists and contains expected functionality echo "Checking Trezor RPC namespace export..." fd "trezor_rpc_namespace.dart" packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/ echo "Checking for TrezorMethodsNamespace class..." ast-grep --pattern 'class TrezorMethodsNamespace { $$$ }' packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/trezor_rpc_namespace.dartLength of output: 513
🏁 Script executed:
#!/bin/bash # Re-check for the TrezorMethodsNamespace class with a simple grep echo "Searching for TrezorMethodsNamespace class definition..." rg "class TrezorMethodsNamespace" -n packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/trezor_rpc_namespace.dartLength of output: 311
Trezor RPC namespace export verified
The file
packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/trezor_rpc_namespace.dartexists and defines theTrezorMethodsNamespaceclass extendingBaseRpcMethodNamespace. The export inrpc_methods.dartis correct and follows naming conventions—no further changes needed.
22-23:Details
✅ Verification successful
Verify the HD wallet method exports exist and provide expected functionality.
The new HD wallet exports follow proper naming conventions and are logically organized within the existing structure.
🏁 Script executed:
#!/bin/bash # Verify that the exported HD wallet files exist and contain expected classes echo "Checking HD wallet method exports..." fd "get_new_address_task.dart" packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/ fd "hd_wallet_methods.dart" packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/ echo "Checking for expected class definitions..." ast-grep --pattern 'class $_ { $$$ }' packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/get_new_address_task.dart packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dartLength of output: 756
🏁 Script executed:
#!/bin/bash # Inspect class definitions in the new HD wallet RPC files echo "Searching for class GetNewAddressTask in get_new_address_task.dart" rg -n "class GetNewAddressTask" packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/get_new_address_task.dart || echo "No match found" echo "Searching for class HdWalletMethods in hd_wallet_methods.dart" rg -n "class HdWalletMethods" packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart || echo "No match found"Length of output: 820
HD Wallet RPC exports verified
- Confirmed that
get_new_address_task.dartandhd_wallet_methods.dartexist underpackages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/.- Verified
get_new_address_task.dartdefines the expected request and response classes (e.g.,GetNewAddressTaskInitRequest,GetNewAddressTaskStatusRequest, etc.).- Verified
hd_wallet_methods.dartdefines theHdWalletMethodsnamespace class.All exports follow established naming conventions and are correctly organized.
packages/komodo_defi_sdk/index_generator.yaml (1)
22-31: LGTM! Configuration follows established patterns perfectly.The new Trezor library configuration entry is consistent with existing entries in structure, naming conventions, exclude patterns, and documentation format.
packages/komodo_defi_sdk/lib/src/pubkeys/pubkey_manager.dart (1)
33-39:Details
✅ Verification successful
LGTM! Enhanced strategy selection with proper error handling.
The refactor to pass the entire
KdfUserobject instead of a boolean parameter provides more context for strategy selection, which is essential for supporting different hardware wallet types like Trezor. The null check with appropriate exception throwing is good defensive programming.However, please verify that all callers of
asset.pubkeyStrategy()have been updated to match the new signature:
🏁 Script executed:
#!/bin/bash # Description: Verify that all asset.pubkeyStrategy calls use the new signature # Expected: All calls should use the kdfUser parameter instead of isHdWallet echo "Searching for pubkeyStrategy method calls..." rg -A 3 "\.pubkeyStrategy\(" --type dart echo -e "\nSearching for pubkeyStrategy method definitions..." ast-grep --pattern 'pubkeyStrategy($$$)'Length of output: 636
No further updates required: all
asset.pubkeyStrategycalls use the newkdfUserparameter
- Search across all Dart files found only one call in
packages/komodo_defi_sdk/lib/src/pubkeys/pubkey_manager.dart- That call already uses
asset.pubkeyStrategy(kdfUser: currentUser)as intendedpackages/komodo_defi_rpc_methods/lib/src/rpc_methods_library.dart (1)
44-45: Good addition of Trezor hardware wallet namespace.The addition of
TrezorMethodsNamespaceproperly organizes Trezor-specific RPC methods under a dedicated namespace, following the established pattern for protocol-specific namespaces.packages/komodo_defi_sdk/example/lib/main.dart (2)
6-6: Good addition of AuthBloc import for reactive state management.
198-224: Excellent refactor to bloc-based authentication state management.This refactor eliminates manual state management in favor of a reactive bloc pattern, which provides several benefits:
- Centralized auth logic: All authentication operations are now handled through
AuthBloc- Reactive UI updates: The
BlocListenerautomatically updates the UI when auth state changes- Cleaner component interfaces:
InstanceViewno longer needscurrentUseroronUserChangedparameters- Better separation of concerns: State management is decoupled from UI components
The implementation correctly:
- Creates an
AuthBlocinstance for each SDK instance- Uses
BlocListenerto react to auth state changes- Maintains the existing
_updateInstanceUsercallback for compatibilitypackages/komodo_defi_rpc_methods/lib/src/models/task_response_details.dart (2)
7-11: Solid design with proper validation.The constructor assertion correctly ensures exactly one of the three fields is non-null, which maintains data integrity for the wrapper class.
19-23: Convenient error handling utility.The
throwIfErrorgetter provides a clean way to propagate errors when they exist.packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_event.dart (5)
3-15: Well-implemented Trezor sign-in event.The event class properly encapsulates the required data for Trezor authentication with appropriate equality implementation.
31-43: LGTM!The event properly handles initialization and authentication flow with appropriate default values.
45-54: PIN event implementation looks good.The event correctly encapsulates PIN input for Trezor initialization.
56-68: Passphrase event properly structured.The event correctly handles passphrase input for Trezor initialization.
70-78: Cancellation event correctly implemented.The event properly handles task cancellation with minimal required data.
packages/komodo_defi_types/lib/src/public_key/pubkey_strategy.dart (1)
56-63: Extension method correctly updated.The signature change properly propagates the
KdfUserparameter to the factory method.packages/komodo_defi_sdk/example/lib/screens/auth_screen.dart (2)
62-73: Navigation properly updated with repository provider.The use of
RepositoryProvider.valuecorrectly provides the SDK instance to the asset page.
83-96: Bloc pattern correctly implemented.The refactoring properly introduces
BlocProviderand createsAuthBlocwith the required instance state.packages/komodo_defi_sdk/example/lib/blocs/auth/auth_event.dart (1)
1-88: Well-structured authentication event classes!The event hierarchy is clean and follows Flutter Bloc best practices. All events properly implement Equatable for reliable state comparisons.
packages/komodo_defi_sdk/example/lib/widgets/auth/seed_dialog.dart (1)
156-163: Clean architectural improvement!The change from callback-based to return value via Navigator.pop is a good improvement that simplifies the widget and aligns with the bloc pattern.
packages/komodo_defi_sdk/example/lib/blocs/auth/auth_bloc.dart (1)
17-247: Well-structured authentication bloc implementation!The AuthBloc is properly designed with clear separation of concerns, comprehensive error handling, and good integration of Trezor support via the mixin pattern. The helper methods provide clean APIs for consumers.
packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dart (2)
6-87: Clean refactoring to mixin pattern!The extraction of shared HD wallet logic into
HDWalletMixinis well-designed. The public method names (getAccountBalance,convertBalanceInfoToAssetPubkeys) follow Dart conventions properly.
89-157: Well-implemented strategy classes!Both
ContextPrivKeyHDWalletStrategyandTrezorHDWalletStrategyproperly implement their respective address generation approaches:
- Context strategy uses direct RPC calls
- Trezor strategy uses task-based polling with proper error propagation
The polling mechanism in Trezor strategy is appropriate for hardware wallet interactions.
packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_mixin.dart (1)
16-41: Secure password management implementation!Good use of
FlutterSecureStoragefor persisting Trezor wallet passwords and proper error handling for missing passwords. The secure password generation with 16 characters provides adequate security.packages/komodo_defi_sdk/example/lib/blocs/auth/auth_state.dart (2)
1-1: LGTM!Correct use of
part ofdirective for the BLoC pattern.
3-22: LGTM!The
AuthStatusenum covers all necessary authentication states with clear documentation.packages/komodo_defi_sdk/lib/src/trezor/trezor_initialization_state.dart (2)
1-2: LGTM!Appropriate import for RPC methods dependency.
3-28: LGTM!The
TrezorInitializationStatusenum comprehensively covers all initialization states with clear documentation.packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/trezor_rpc_namespace.dart (1)
4-6: LGTM!Clean namespace class definition extending the base RPC namespace.
packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart (2)
51-83: LGTM: Consistent rpcPass handling.The account balance methods properly handle the
rpcPassparameter with fallback tothis.rpcPass, providing a good user experience by using the instance-level password when none is explicitly provided.
85-122: LGTM: Consistent task-based methods implementation.The task-based
getNewAddressmethods properly implement the init/status/cancel pattern with consistent parameter handling and appropriate fallbacks for therpcPassparameter.
packages/komodo_defi_framework/lib/src/operations/kdf_operations_wasm.dart
Show resolved
Hide resolved
packages/komodo_defi_rpc_methods/lib/src/models/task_response_details.dart
Show resolved
Hide resolved
packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/get_new_address_task.dart
Outdated
Show resolved
Hide resolved
| ), | ||
| keyboardType: TextInputType.number, |
There was a problem hiding this comment.
🛠️ Refactor suggestion
Clarify PIN input instructions
The helper text mentions "PIN pad on your Trezor device" but the user is entering the PIN in the app. This could be confusing.
helperText: 'Use the PIN pad on your Trezor device',
+ helperMaxLines: 2,And update the text to:
- helperText: 'Use the PIN pad on your Trezor device',
+ helperText: 'Enter PIN based on the positions shown on your Trezor device',📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| ), | |
| keyboardType: TextInputType.number, | |
| helperText: 'Enter PIN based on the positions shown on your Trezor device', | |
| helperMaxLines: 2, | |
| ), | |
| keyboardType: TextInputType.number, |
🤖 Prompt for AI Agents
In
packages/komodo_defi_sdk/example/lib/widgets/instance_manager/instance_view.dart
around lines 149 to 150, the helper text for the PIN input incorrectly
references the "PIN pad on your Trezor device," which is misleading since the
user enters the PIN in the app. Update the helper text to clearly instruct the
user to enter their PIN directly in the app input field, removing any mention of
the Trezor device PIN pad to avoid confusion.
packages/komodo_defi_sdk/example/lib/widgets/instance_manager/instance_view.dart
Show resolved
Hide resolved
packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart
Show resolved
Hide resolved
packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart
Show resolved
Hide resolved
packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart
Show resolved
Hide resolved
funded addresses not being scanned for fresh trezor logins (maybe not believed to be a "fresh" wallet)?
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Pull Request Overview
This PR introduces hardware wallet support for Trezor by extending the RPC layer and updating the Flutter SDK example to integrate a new authentication flow.
- Added task-based
get_new_addressRPC methods and Trezor namespace in the RPC library. - Created
TrezorAuthMixin, related events and states, and hooked upAuthBlocwith Trezor flows in the example. - Refactored HD wallet strategies into a shared mixin and provided separate strategies for context-based and Trezor-based HD wallets.
Reviewed Changes
Copilot reviewed 38 out of 38 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| example/lib/main.dart | Integrated AuthBloc with Trezor login button into the example app. |
| example/lib/blocs/auth/trezor_auth_mixin.dart | Implemented Trezor initialization/authentication logic in a mixin. |
| example/lib/blocs/auth/trezor_auth_event.dart | Defined new events for Trezor PIN, passphrase, and cancellation. |
| example/lib/blocs/auth/auth_state.dart | Extended AuthState to include Trezor-specific statuses and fields. |
| example/lib/blocs/auth/auth_bloc.dart | Set up Trezor handlers and wired events into the main auth BLoC. |
| packages/komodo_defi_rpc_methods/lib/src/rpc_methods_library.dart | Exposed new trezor RPC namespace. |
| packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/get_new_address_task.dart | Added init/status/cancel request/response classes for task::get_new_address. |
| packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dart | Refactored HD wallet logic into HDWalletMixin and added Trezor strategy. |
| packages/komodo_defi_framework/lib/src/operations/kdf_operations_wasm.dart | Enhanced debug logging around raw JS responses. |
Comments suppressed due to low confidence (2)
packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_mixin.dart:9
- FlutterSecureStorage does not have a const constructor; change
static consttostatic finalto avoid a compilation error.
static const FlutterSecureStorage _secureStorage = FlutterSecureStorage();
packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dart:7
- The original
HDWalletStrategyclass was removed and replaced by a mixin; this breaks any code referencingHDWalletStrategy. Consider reintroducing the strategy class or renaming the mixin to maintain backward compatibility.
mixin HDWalletMixin on PubkeyStrategy {
There was a problem hiding this comment.
Actionable comments posted: 0
♻️ Duplicate comments (3)
packages/komodo_defi_sdk/lib/src/trezor/trezor_manager.dart (1)
200-202: Replace print with proper logging mechanismUsing
packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_mixin.dart (1)
73-74: Add error logging as indicated by the commentThe comment states "Log the error but continue" but no logging is implemented in the catch block.
packages/komodo_defi_sdk/example/lib/widgets/instance_manager/instance_view.dart (1)
132-196: Comprehensive Trezor PIN dialog implementationThe PIN dialog properly handles dismissal with
PopScopeand integrates well with the BLoC pattern. However, there's still a confusing helper text issue from previous reviews.The helper text on line 161 still references "PIN pad on your Trezor device" which was flagged in previous reviews as confusing since users enter the PIN in the app interface.
🧹 Nitpick comments (2)
packages/komodo_defi_types/lib/src/protocols/utxo/utxo_protocol.dart (1)
25-30: Update or remove the outdated TODO commentThe TODO comment is no longer accurate since this implementation now supports configuring activation parameters for Trezor via the
privKeyPolicyparameter. Consider updating or removing this comment to reflect the current implementation.- // TODO: Consider the limitation this is likely to impose in the near - // future when we need to confirgure activation parameters e.g. for Trezor. - // A better solution may be to create a separate activation strategy rather - // than adding the activation parameters to the protocol. - // Hint: It may be useful to refactor `[ActivationStrategy.supportsAssetType]` - // to be async.packages/komodo_defi_sdk/example/lib/blocs/auth/auth_bloc.dart (1)
53-54: Consider using a proper logging mechanismWhile
debugPrintis acceptable for development, consider injecting a logger instance for more flexible and production-ready error logging.Also applies to: 282-283
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (17)
packages/komodo_defi_framework/lib/src/operations/kdf_operations_wasm.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/get_new_address_task.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/trezor_rpc_namespace.dart(1 hunks)packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dart(4 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/auth_bloc.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/auth_event.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/auth_state.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_event.dart(1 hunks)packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_mixin.dart(1 hunks)packages/komodo_defi_sdk/example/lib/widgets/instance_manager/instance_view.dart(6 hunks)packages/komodo_defi_sdk/lib/src/trezor/_trezor_index.dart(1 hunks)packages/komodo_defi_sdk/lib/src/trezor/trezor_exception.dart(1 hunks)packages/komodo_defi_sdk/lib/src/trezor/trezor_initialization_state.dart(1 hunks)packages/komodo_defi_sdk/lib/src/trezor/trezor_manager.dart(1 hunks)packages/komodo_defi_types/lib/src/protocols/utxo/utxo_protocol.dart(1 hunks)packages/komodo_defi_types/lib/src/public_key/pubkey_strategy.dart(2 hunks)
✅ Files skipped from review due to trivial changes (1)
- packages/komodo_defi_sdk/lib/src/trezor/trezor_exception.dart
🚧 Files skipped from review as they are similar to previous changes (10)
- packages/komodo_defi_framework/lib/src/operations/kdf_operations_wasm.dart
- packages/komodo_defi_sdk/lib/src/trezor/_trezor_index.dart
- packages/komodo_defi_types/lib/src/public_key/pubkey_strategy.dart
- packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/get_new_address_task.dart
- packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_event.dart
- packages/komodo_defi_rpc_methods/lib/src/rpc_methods/hd_wallet/hd_wallet_methods.dart
- packages/komodo_defi_sdk/example/lib/blocs/auth/auth_state.dart
- packages/komodo_defi_rpc_methods/lib/src/strategies/pubkey/hd_multi_address_strategy.dart
- packages/komodo_defi_sdk/lib/src/trezor/trezor_initialization_state.dart
- packages/komodo_defi_rpc_methods/lib/src/rpc_methods/trezor/trezor_rpc_namespace.dart
🔇 Additional comments (12)
packages/komodo_defi_types/lib/src/protocols/utxo/utxo_protocol.dart (1)
31-47: Implementation correctly handles Trezor scan policyThe changes appropriately set
ScanPolicy.scanfor Trezor wallets to ensure funded addresses appear upon first activation, while maintaining backward compatibility with the defaultScanPolicy.scanIfNewWalletfor other wallet types.packages/komodo_defi_sdk/example/lib/blocs/auth/auth_event.dart (1)
1-99: Well-structured authentication eventsThe authentication event classes are properly implemented with correct Equatable usage and comprehensive coverage of authentication workflows.
packages/komodo_defi_sdk/lib/src/trezor/trezor_manager.dart (1)
7-207: Well-implemented Trezor device managementThe
TrezorManagerclass provides a comprehensive and well-documented API for Trezor device initialization with proper stream handling, error management, and resource cleanup.packages/komodo_defi_sdk/example/lib/blocs/auth/auth_bloc.dart (1)
17-315: Well-implemented authentication blocThe
AuthBlocimplementation provides comprehensive authentication state management with proper event handling, error management, and clean separation of Trezor-specific logic via the mixin pattern.packages/komodo_defi_sdk/example/lib/blocs/auth/trezor_auth_mixin.dart (1)
3-350: Excellent implementation of Trezor authentication flowThe mixin provides a well-structured implementation of Trezor hardware wallet authentication with:
- Secure password management using
FlutterSecureStorage- Comprehensive state handling for all Trezor initialization phases
- Proper error handling and user feedback
- Clean separation of concerns
The approach of generating and securely storing passwords for Trezor wallets is a good security practice.
packages/komodo_defi_sdk/example/lib/widgets/instance_manager/instance_view.dart (7)
5-6: LGTM! Clean BLoC integrationThe import additions properly support the transition to BLoC-based state management for authentication.
39-50: Well-structured state initializationThe local state management with proper controller initialization and BLoC event dispatching in
initStatefollows Flutter best practices.
54-58: Proper resource cleanupControllers are correctly disposed to prevent memory leaks.
60-82: Robust mnemonic retrieval with proper error handlingThe async implementation with null checks and mounted state verification is well-implemented.
198-275: Well-designed Trezor passphrase dialogThe passphrase dialog provides clear user options between standard and hidden wallet configurations with proper event handling.
334-412: Excellent BLoC integration with comprehensive state handlingThe
BlocConsumerimplementation properly handles:
- Error states with user feedback
- Form field updates on user selection
- Trezor-specific state transitions
- Loading state management
This is a well-architected reactive UI pattern.
472-642: Thorough authentication form with Trezor integrationThe form implementation includes:
- Proper loading state handling
- Known users display with chips
- Form validation
- Comprehensive Trezor status feedback
- Clean separation of concerns
The UI correctly disables interactions during loading states and provides clear feedback to users.
There was a problem hiding this comment.
@takenagain If both this PR and #81 (pending review into this PR) are ready for review, then why not merge #81 in? If you don't have perms to merge the PR, then you can merge the branches with git.
…#81) This is a concept solution that moves the Trezor initialization and authentication flow from the example BLoC to the SDK KomodoDefiAuth class & package. Two issues that make integrating the trezor login flow with the current SDK difficult: - Trezor login is a multi-step process that uses task-based RPCs, so Stream-based versions of the signin and register methods are required. - Async user inputs (i.e. passphrase or pin) need to be sent to trezor as part of login process. Solution implemented in this PR: - Add stream-based signInStream and registerStream functions to KomodoDefiAuth with a new Authentication state/status class. - Alternative (breaking): modify the existing functions to return Stream - Add input methods for passphrase and pin to KomodoDefiAuth - Alternative 1: Ask user for passphrase before starting trezor sign-in and pass it through the existing wallet password field. - Alternative 2: SDK consumers use device-specific managers (e.g. sdk.trezor.sendPassphrase). Commits: * Use TrezorWalletManager in example bloc * refactor(trezor,auth): move trezor auth into komodo_defi_local_auth * refactor: implement coderabbitai suggestions
I've merged #81 and |
@takenagain |
* migrate models to freezed * fix(types): revert changes to seed_node and auth_options
commit 0303d39 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Fri Aug 1 15:52:14 2025 +0200 chore: switch KDF to `dev` Switch KDF to `dev` to allow usage of unreleased changes (particularly related to fees/priorities) commit 1fae456 Author: Francois <takenagain@users.noreply.github.com> Date: Fri Aug 1 17:46:34 2025 +0200 fix(market-data-price): try fetch current price from komodo price repository first before cex repository (#167) * fix(market-data-manager): default to KomodoPriceRepository Binance CexRepository supports a limited number of symbols and no longer lists KMD price history after the delisting * refactor(market-data-manager): deduplicate and clarify intent * refactor(review): remove zero check and add log statements also simplify the priceIfKnown function commit f8064f2 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Fri Aug 1 15:50:09 2025 +0200 fix(types): comprehensive bip39 validation commit 60e5f2e Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 30 21:18:06 2025 +0200 feat: offline private key export (#160) * feat(hd): integrate hd privkey export * chore: roll KDF * chore: enable tendermint hd support * refactor(rpc): Misc rpc class formats/fixes * feat: private keys + fixed Tendermint * refactor(sdk): implement co-ordinated activation manager * fix: invalid path error Possible fix for paths containing special characters on Windows. * fix: remove unnecessary activation logging * chore(pr): apply formatting and fixes to PR Apply Dart formatting and fixes to all files modified in this PR. * feat(example): integrate private key export to example app * chore: roll KDF * chore: roll KDF * feat: fee estimation * fix(build): make re-build failure stand out * chore: roll KDF Roll KDF for optimisation for key export time. * feat(tx): further progress on fee/priority integration * chore: roll KDF fro `v2.6.1` TODO: Change from CI builds to GitHub release when artefacts are available. * fix(api): disable fee/priority features Disable fee/priority features because they are not included in the pending KDF release. They should be included in the following release (likely `2.7.0`) * fix: Temporarily disable fee/priority features Temporarily disable fee/priority features until the feature is available in the API (KDF) * feat: add memo support protocol value * fix: resolve incorrect `unban_pubkeys` parsing * fix: resolve regression in legacy withdrawal manager * feat(security): Include failed activations in privkey export * docs(build): expand asset build failure explination * fix: tweak private key type json to match class properties * fix(RPC): fix new address generation types * chore: bump version tags * fix: apply Claude PR review suggestions commit 834b83f Merge: 1526a23 a41f81f Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 30 20:12:37 2025 +0200 Merge pull request #165 from KomodoPlatform/migrate/dragon_logs_flutter feat: migrate dragon_logs_flutter to monorepo packages commit a41f81f Merge: 1526a23 a6a9a6e Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 30 18:19:07 2025 +0200 Merge commit 'a6a9a6ef4a308f95be1fafbb018449f198d8b4db' as 'packages/dragon_logs' commit a6a9a6e Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 30 18:19:07 2025 +0200 Squashed 'packages/dragon_logs/' content from commit 399ef1d1 git-subtree-dir: packages/dragon_logs git-subtree-split: 399ef1d17034029155b63b6bc1d9ab0a5a0fbb04 commit 1526a23 Merge: dc093db acda1d9 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 28 21:10:37 2025 +0200 Merge branch 'codex/implement-pubkey-unbanning-feature' into dev commit acda1d9 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 28 21:07:58 2025 +0200 fix(ui): resolve stale asset balance widget commit dc093db Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 28 20:18:02 2025 +0200 feat(pubkeys): add unbanning support (#161) * feat(pubkeys): add unbanning support * Update packages/komodo_defi_rpc_methods/lib/src/rpc_methods/wallet/unban_pubkeys.dart Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fix(types): export missing RPC types --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> commit 7d7e888 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 28 20:14:54 2025 +0200 fix(types): export missing RPC types commit 9621aa2 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 28 20:00:48 2025 +0200 Update packages/komodo_defi_rpc_methods/lib/src/rpc_methods/wallet/unban_pubkeys.dart Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> commit 4a3d9c8 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 28 18:33:47 2025 +0200 feat(pubkeys): add unbanning support commit b18af0b Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Sun Jul 27 16:59:11 2025 +0200 feat(ui): add hero support for coin icons (#159) * feat(ui): add hero support for asset icons * fix(ui): Hero Tag Ignored in AssetLogo Placeholder * fix: Move Hero widget outside Opacity widget for proper animation continuity - Fix AssetLogo.placeholder to pass heroTag parameter to _AssetLogoPlaceholder - Move Hero widget outside Opacity widget in AssetIcon to prevent animation interference - Ensures Hero animations work correctly for both asset icons and placeholder logos - Maintains visual continuity by placing Hero widgets as outermost components commit c2d985a Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Fri Jul 25 15:20:29 2025 +0200 feat(fees): integrate fee management (#152) * feat(fees): add fee management support * docs(sdk): Document withdrawal manager Document withdrawal manager and implement PR review comments. * docs(sdk): Add documentation for fee manager commit e1a63e2 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Fri Jul 25 11:15:26 2025 +0200 feat(activation): disable tx history when using external strategy (#151) * feat(activation): disable kdf tx history when using external strategy * docs: clarify mm2 history helper (#154) commit 74d8eff Author: Francois <takenagain@users.noreply.github.com> Date: Thu Jul 24 18:30:54 2025 +0200 Revert "fix(activation): track activation status to avoid duplicate activation requests (#80)" (#153) This reverts commit abd3de0. commit 7eefbd8 Author: dragonhound <35845239+smk762@users.noreply.github.com> Date: Mon Jul 21 20:24:39 2025 +0800 adds `max_connected: 1` to utxo activation (#148) commit b8ff967 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 21 14:24:16 2025 +0200 Revert "feat(rpc): support max_connected on activation (#149)" (#150) This reverts commit eac2b8f. commit eac2b8f Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 21 13:11:54 2025 +0200 feat(rpc): support max_connected on activation (#149) * feat(rpc): support max_connected on activation * fix: limit max connections to 1 commit bb57e87 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Sun Jul 20 00:15:49 2025 +0200 fix(build): update config format commit 6534d47 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Sun Jul 20 00:04:09 2025 +0200 feat(wallet_build_transformer): add flexible CDN support (#144) commit abd3de0 Author: Francois <takenagain@users.noreply.github.com> Date: Thu Jul 17 18:54:01 2025 +0200 fix(activation): track activation status to avoid duplicate activation requests (#80) * Track activation streams to avoid duplicate requests * fix activation stream propagation * fix(activation): provide historical states to late stream subscribers * fix(activation): use asset lookup in parent grouping using the asset itself as a placeholder led to assertion errors being thrown if the child asset is activated individually. commit 9351c22 Author: Francois <takenagain@users.noreply.github.com> Date: Wed Jul 16 19:55:00 2025 +0200 feat(ui): allow customizing SourceAddressField header (#135) * feat(ui): make source address field customizable * refactor: remove content override from SourceAddressField commit a521a80 Author: Francois <takenagain@users.noreply.github.com> Date: Wed Jul 16 14:37:28 2025 +0200 fix(withdraw): revert temporary IBC channel type changes (#136) #63 commit a44acf3 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 14 16:14:45 2025 +0200 fix(ui): make Divided button min width commit aa51985 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jul 7 17:15:04 2025 +0200 feat: protect SDK after disposal (#116) * feat: prevent SDK reuse after disposal * refactor(sdk): promote dispose helper (#127) commit 9cf9e37 Author: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon Jul 7 15:08:29 2025 +0200 chore: roll KDF version to commit fbab8ec for branch main (#124) * chore: roll KDF version to commit fbab8ec for branch main * chore: update binaries * chore: roll coins assets --------- Co-authored-by: GitHub Actions <github-actions[bot]@users.noreply.github.com> Co-authored-by: CharlVS <77973576+CharlVS@users.noreply.github.com> commit ce68c7a Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Sat Jul 5 19:24:33 2025 +0200 feat(seed): update seed node format (#87) * feat(seed): update seed node format with netid * Update packages/komodo_defi_types/lib/src/seed_node/seed_node.dart Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * feat(core): use constant netid in seed node filtering (#111) * fix: add missing imports/exports --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> commit d7b6ede Author: Francois <takenagain@users.noreply.github.com> Date: Sat Jul 5 18:37:15 2025 +0200 feat(pubkey): add streamed new address API with Trezor confirmations (#123) * feat(pubkey): add streamed new address API with Trezor confirmations (#117) * Implement streamed new address state with confirmations * refactor: remove unused imports and make polling interval configurable * refactor: move confirm address details to types (#120) * refactor: move confirm address details to types * refactor: fix warnings * feat(example): use streamed address creation (#119) * Use streamed address generation * refactor: add cancel action and use normal stream rather than broadcast * chore: add json conversion support to `NewAddressState` * fix(asset-filter): exclude BCH and yield address creation error states * refactor: add task description parser and try cancel task if user cancel commit d6d83c6 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Fri Jul 4 18:30:50 2025 +0200 fix(local_auth): ensure kdf running before wallet deletion (#118) commit cda8498 Author: Francois <takenagain@users.noreply.github.com> Date: Thu Jul 3 20:44:32 2025 +0200 feat(ui): add helper constructors for AssetLogo from legacy ticker and AssetId (#109) * feat(ui): add AssetLogo constructors * fix: correct protocol overlay for child assets (#115) * fix(example): use parent protocol for child assets in trailing icon * feat(ui): add placeholder asset logo used in legacy maker and taker forms in KW * feat(ui): add asset exists helper functions used in KW fiat onramp form * refactor: clarify doc comments and rename constructors * fix(assets): tendermint token parent parsing logic - place tendermint before tendermint token - replace subclass check with canBeParentOf * refactor(asset-logo): use theme `disabledColor` in place of Opacity --------- Co-authored-by: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> commit 3dc37d0 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Thu Jul 3 19:16:58 2025 +0200 add(ui): enhance TrendPercentageText Enhance `TrendPercentageText` with expanded use cases and automatic animations. commit c5c30d4 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 2 18:45:02 2025 +0200 fix: resolve bug with dispose logic TODO(@CharlVS): Consider separating the KDF-related concerns of dispose into a separate method named terminate(). This helps differentiate between KDF resource clean-up and UI resource clean-up commit 9d63c56 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 2 15:34:14 2025 +0200 add(auth): auth stream method with initial value commit 81ba643 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 2 11:09:33 2025 +0200 fix: stop KDF when disposed commit c8f27a7 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Wed Jul 2 10:33:27 2025 +0200 fix: SIA support Disable SIA as it is not yet supported. The SIA activation strategy will be merged soon, but this depends on a specific branch of KDF and will likely still be very long before it is available in a public release of KDF. commit a02c4a2 Author: Francois <takenagain@users.noreply.github.com> Date: Wed Jul 2 09:48:09 2025 +0200 fix(trezor): improve trezor error handling (#110) * chore(deps): bump logging version to 1.3.0 as in komodo-wallet * fix(trezor): sign out of existing wallet if initialisation fails fixes the following scenarios - trezor device not found - trezor device not selected and other edge cases that may cause trezor init or auth to fail, ensuring that the user already exists error is not thrown * feat(trezor): add priv_key_policy to tendermint, erc20, and zhtlc params * fix(trezor): yield error states rather than exceptions in streams * feat(activation,rpc): task-based eth activation * feat(asset-manager): asset filter strategy based on current wallet (#107) * feat(asset-manager): asset filter strategy based on current wallet * featasset-manager): limit trezor asset filter to utxo and qtum only * refactor: add error response check and evm subclasses set coderabbitai suggestions * feat: add name-based filter strategy (#108) * refactor: update authOptions references to use walletId * refactor(asset-filter): rename `name` to `strategyId` * ci(example): re-enable dry build run commit 8a1daea Author: Francois <takenagain@users.noreply.github.com> Date: Wed Jul 2 09:45:18 2025 +0200 feat(ui): adjust error display layout for narrow screens (#114) * chore(deps): bump logging version to 1.3.0 as in komodo-wallet * fix(trezor): sign out of existing wallet if initialisation fails fixes the following scenarios - trezor device not found - trezor device not selected and other edge cases that may cause trezor init or auth to fail, ensuring that the user already exists error is not thrown * feat(trezor): add priv_key_policy to tendermint, erc20, and zhtlc params * fix(trezor): yield error states rather than exceptions in streams * feat(activation,rpc): task-based eth activation * feat(asset-manager): asset filter strategy based on current wallet (#107) * feat(asset-manager): asset filter strategy based on current wallet * featasset-manager): limit trezor asset filter to utxo and qtum only * refactor: add error response check and evm subclasses set coderabbitai suggestions * feat: add name-based filter strategy (#108) * refactor: update authOptions references to use walletId * refactor(asset-filter): rename `name` to `strategyId` * refactor: extract show details button * Refactor error display components * refactor: convert toggle to stateless widget * feat(ui): add toggle for icon and expose breakpoint * fix(ui): button interactivity no-op when showDetailsOverride is true Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> * refactor: remove unnecessary spread operator --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> commit 5f7da9e Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 30 15:34:29 2025 +0200 ci: skip melos init Disabled melos generation due to circular dependency issues caused by komodo_defi_rpc_methods and komodo_defi_types packages. This will be revisited in the. The app should already have the necessary generated files committed to the repository. If this is not the case, we have bigger issues. commit f6f5820 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 30 15:25:59 2025 +0200 add: Wallet deletion example and fix global error parsing flaw (#99) * feat(auth): add wallet deletion * feat(example): add wallet deletion * add: wallet deletion for Trezor wallets * chore: re-generate melos * refactor: fix flaw in response error parsing Fix flaw in response error parsing where the custom error parser function would never be called because of the inheritence structure. * feat(example): move delete wallet action (#104) commit fafc707 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 30 14:57:00 2025 +0200 feat(asset): add message signing support flag (#105) commit 3701f49 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 30 14:41:23 2025 +0200 fix: kdf hashes commit a2face7 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 30 14:16:56 2025 +0200 chore(kdf): update build config to latest staging (#103) commit 41fb498 Author: Francois <takenagain@users.noreply.github.com> Date: Mon Jun 30 11:45:18 2025 +0200 chore(deps): bump komodo-defi-framework to a25aea614 (#102) latest staging with hotfix for trezor coin activation commit 7dfe68b Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Fri Jun 27 14:58:42 2025 +0200 chore: roll KDF (#100) commit e5d022b Author: Francois <takenagain@users.noreply.github.com> Date: Thu Jun 26 16:41:13 2025 +0200 fix(pubkey-strategy): use new PrivateKeyPolicy constructors for checks (#97) commit 24d09fd Author: Francois <takenagain@users.noreply.github.com> Date: Wed Jun 25 16:08:18 2025 +0200 fix(activation): eth PrivateKeyPolicy enum breaking changes (#96) * fix(rpc,activation): breaking EVM private key policy enum change * fix(activation-params): use pascal case for to and from json * test(example): add asset activation integration test * test(example): run in zone to catch microtask and uncaught exceptions * fix(auth): merge issues and update privkeypolicy comparisons * docs: expand doc comments and remove runzonedguarded commit 2a50691 Author: Francois <takenagain@users.noreply.github.com> Date: Tue Jun 24 18:52:35 2025 +0200 feat(sdk): add trezor support via RPC and SDK wrappers (#77) * fix(trezor,activation): add PrivateKeyPolicy to AuthOptions and beyond * feat(rpc): add trezor init task RPCs * feat(sdk): trezor manager for init and user input requests * feat(rpc): add task-based address generation RPCs * feat(rpc): add trezor pubkey strategy with task-based address creation * WIP: trezor login option in SDK example * refactor(example): trezor auth mixin and remove previous trezor ui code * fix(trezor): device info parsing and example auth state transitions * refactor(trezor): add auth listener & implement coderabbitai suggestions * fix(example): auth restoration and listener order * fix(trezor): workaround for trezor-specifc scan issue funded addresses not being scanned for fresh trezor logins (maybe not believed to be a "fresh" wallet)? * fix(rpc): get new address task status response parsing * refactor(trezor): move authentication and initialization logic to SDK (#81) This is a concept solution that moves the Trezor initialization and authentication flow from the example BLoC to the SDK KomodoDefiAuth class & package. Two issues that make integrating the trezor login flow with the current SDK difficult: - Trezor login is a multi-step process that uses task-based RPCs, so Stream-based versions of the signin and register methods are required. - Async user inputs (i.e. passphrase or pin) need to be sent to trezor as part of login process. Solution implemented in this PR: - Add stream-based signInStream and registerStream functions to KomodoDefiAuth with a new Authentication state/status class. - Alternative (breaking): modify the existing functions to return Stream - Add input methods for passphrase and pin to KomodoDefiAuth - Alternative 1: Ask user for passphrase before starting trezor sign-in and pass it through the existing wallet password field. - Alternative 2: SDK consumers use device-specific managers (e.g. sdk.trezor.sendPassphrase). Commits: * Use TrezorWalletManager in example bloc * refactor(trezor,auth): move trezor auth into komodo_defi_local_auth * refactor: implement coderabbitai suggestions * refactor(trezor): migrate auth options and state models to freezed (#90) * migrate models to freezed * fix(types): revert changes to seed_node and auth_options commit b863ccb Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Tue Jun 24 17:40:41 2025 +0200 fix(auth): allow custom seeds for legacy wallets (#95) commit 3e9f73c Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 23 15:32:19 2025 +0200 chore: re-generate melos configs commit 1a4ec66 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 23 15:31:36 2025 +0200 fix: remove obsolete coins transformer Remove ETH coins config transformer which was temporarily required because of a breaking ETH change in KDF. commit 58acbc2 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 23 15:21:36 2025 +0200 bug: fix missing pubkey equality operators commit d05c13b Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 23 15:19:50 2025 +0200 chore: update KDF to release preview version commit fdeb713 Author: dragonhound <35845239+smk762@users.noreply.github.com> Date: Wed Jun 18 20:38:33 2025 +0800 removes BCH from _filteredCoins (#83) commit a36357e Author: Francois <takenagain@users.noreply.github.com> Date: Wed Jun 18 14:38:12 2025 +0200 feat(ui): add AssetLogo widget (#78) * Use AssetLogo in example and tweak imports * style: match the styling with the existing komodo-wallet implementation commit 8990c9c Author: DeckerSU <support@decker.su> Date: Wed Jun 18 14:37:22 2025 +0200 fix KDF not found warnings in _tryRenameFile of FetchDefiApiStep (#76) If the KDF binaries were already renamed from `mm2` to `kdf`—i.e., if the target folder already contained `kdf.exe` or `libkdf.a` after the last successful rename from `*mm2*`—the warning `KDF not found at` would still appear, which was a bit confusing. Now, if the folder already contains the renamed binary, the warning no longer appears. commit 55176e1 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Mon Jun 16 01:02:04 2025 +0200 fix: revert ETH coins config migration transformer commit 7d438bd Author: Francois <takenagain@users.noreply.github.com> Date: Sun Jun 15 17:31:26 2025 +0200 fix(kdf): enable p2p in noAuth mode (#86) * fix(kdf): enable p2p in noAuth mode * refactor(kdf): use SeedNodeService to get seednodes for noAuth commit 4038b86 Author: CharlVS <77973576+CharlVS@users.noreply.github.com> Date: Sun Jun 15 02:15:36 2025 +0200 chore: refresh KDF checksums commit aa8148b Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Sun Jun 15 00:17:09 2025 +0200 feat: add configurable seed node system with remote fetching (#85) * feat: add custom seed nodes - Add custom seed nodes to accommodate breaking KDF changes. - Upgrade KDF for latest seed node changes. * feat: add configurable seed node system with remote fetching Implement a comprehensive seed node configuration system that fetches seed nodes from the Komodo Platform repository with automatic fallback to hardcoded defaults. ### New Features: - Add SeedNode and SeedNodeContact types for type-safe configuration - Implement SeedNodeUpdater for fetching remote seed nodes - Add SeedNodeService with automatic fallback mechanism - Add SeedNodeValidator with enhanced P2P configuration validation - Export seed node service from komodo_defi_framework ### Configuration Updates: - Update build_config.json to include seed-nodes.json mapping - Add seed_nodes.json to gitignore for dynamic assets - Change API branch from 'dev' to 'alt-main' - Update all platform binary checksums and commit hashes ### Framework Integration: - Add automatic seed node fetching to KdfStartupConfig - Integrate SeedNodeService into auth service for wallet creation - Fix trading protocol parameter name (trading_proto_v2 -> use_trading_proto_v2) - Improve boolean validation in SeedNodeValidator ### Documentation: - Add comprehensive SEED_NODES_GUIDE.md with usage examples - Include example code for seed node functionality - Add complete test coverage for new types and services ### Dependencies: - Add komodo_coin_updates dependency to komodo_defi_framework - Export seed node types from komodo_defi_types - Update pubspec.lock files across packages The seed node system ensures applications always have access to current seed nodes while maintaining backwards compatibility through fallback mechanisms. This addresses the upcoming requirement in v2.5.0-beta where seed nodes will be mandatory unless P2P is disabled. Breaking changes: None - all changes are additive with sensible defaults. * chore: PR cleanup commit 2768355 Author: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> Date: Tue Jun 10 16:34:01 2025 +0200 chore(android): downgrade Java compatibility from 21 to 17 (#79) Co-authored-by: DeckerSU <deckersu@protonmail.com> commit f63bebb Author: Francois <takenagain@users.noreply.github.com> Date: Fri Jun 6 13:46:17 2025 +0200 fix(trezor,activation): add PrivateKeyPolicy to AuthOptions (#75) * fix(trezor,activation): add PrivateKeyPolicy to AuthOptions and beyond * refactor(types): replace `.from` with `.of` of has type annotations Co-authored-by: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> --------- Co-authored-by: Charl (Nitride) <77973576+CharlVS@users.noreply.github.com> commit 040c040 Author: dragonhound <35845239+smk762@users.noreply.github.com> Date: Fri Jun 6 19:20:28 2025 +0800 Update/ethscan v2 (#71) * update etherscan-proxy to v2 * add distinct token url paths
Changes:
task::get_new_addressRPCstask::init_trezor::initKomodoDefiAuthwith a new Authentication state/status class.KomodoDefiAuthNOTE:
ScanPolicy.scanalways used for Trezor in 455d5db to ensure that funded addresses appear on first activation. This is a workaround for the issue of having to manually add addresses to "scan" for existing, funded wallets. This increases the activation time.Known issues:
Summary by CodeRabbit
New Features
Improvements
Bug Fixes
Chores