minor fixes

OmarHatem committed Jan 17, 2026 at 21:04 UTC 6cb28d46482c3e564e722ffb7557768629861855
18 files changed +39 -36
cw_bitcoin/pubspec.lock
+1 -1
@@ -718,7 +718,7 @@ packages:
718 dependency: transitive
719 description:
720 path: "."
721 - ref: cake-update-v2
721 + ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
722 resolved-ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
723 url: "https://github.com/cake-tech/on_chain.git"
724 source: git
cw_core/pubspec.lock
+1 -1
@@ -478,7 +478,7 @@ packages:
478 dependency: "direct main"
479 description:
480 path: "."
481 - ref: cake-update-v2
481 + ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
482 resolved-ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
483 url: "https://github.com/cake-tech/on_chain.git"
484 source: git
cw_core/pubspec.yaml
+1 -1
@@ -33,7 +33,7 @@ dependencies:
33 on_chain:
34 git:
35 url: https://github.com/cake-tech/on_chain.git
36 - ref: cake-update-v2
36 + ref: 096865a8c6b89c260beadfec04f7e184c40a3273
37 socks_socket:
38 git:
39 url: https://github.com/sneurlax/socks_socket
cw_decred/pubspec.lock
+2 -2
@@ -501,8 +501,8 @@ packages:
501 dependency: transitive
502 description:
503 path: "."
504 - ref: cake-update-v2
505 - resolved-ref: "93440dc5126369b873ca1fccc13c3c1240b1c5c2"
504 + ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
505 + resolved-ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
506 url: "https://github.com/cake-tech/on_chain.git"
507 source: git
508 version: "3.7.0"
cw_monero/pubspec.lock
+1 -1
@@ -598,7 +598,7 @@ packages:
598 dependency: transitive
599 description:
600 path: "."
601 - ref: cake-update-v2
601 + ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
602 resolved-ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
603 url: "https://github.com/cake-tech/on_chain.git"
604 source: git
cw_nano/pubspec.lock
+2 -2
@@ -563,8 +563,8 @@ packages:
563 dependency: transitive
564 description:
565 path: "."
566 - ref: cake-update-v2
567 - resolved-ref: "01cbbacbb05d2113aafa8b7c4a2bb766f749d8d8"
566 + ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
567 + resolved-ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
568 url: "https://github.com/cake-tech/on_chain.git"
569 source: git
570 version: "3.7.0"
cw_solana/lib/solana_client.dart
-1
@@ -33,7 +33,6 @@ class TransactionFetchResult {
33 class SolanaWalletClient {
34 // Minimum amount in SOL to consider a transaction valid (to filter spam)
35 static const double minValidAmount = 0.00000003;
36 - final httpClient = ProxyWrapper().getHttpClient();
36 late final client = ProxyWrapper().getHttpIOClient();
37 SolanaRPC? _provider;
38
cw_solana/lib/solana_wallet.dart
+2 -1
@@ -98,7 +98,8 @@ abstract class SolanaWalletBase
98
99 @override
100 @observable
101 - late ObservableMap<CryptoCurrency, SolanaBalance> balance;
101 + ObservableMap<CryptoCurrency, SolanaBalance> balance =
102 + ObservableMap<CryptoCurrency, SolanaBalance>();
103
104 final Completer<SharedPreferences> _sharedPrefs = Completer();
105
cw_solana/pubspec.yaml
+1 -1
@@ -23,7 +23,7 @@ dependencies:
23 on_chain:
24 git:
25 url: https://github.com/cake-tech/on_chain.git
26 - ref: cake-update-v2
26 + ref: 096865a8c6b89c260beadfec04f7e184c40a3273
27 blockchain_utils:
28 git:
29 url: https://github.com/cake-tech/blockchain_utils
cw_tron/pubspec.yaml
+1 -1
@@ -18,7 +18,7 @@ dependencies:
18 on_chain:
19 git:
20 url: https://github.com/cake-tech/on_chain.git
21 - ref: cake-update-v2
21 + ref: 096865a8c6b89c260beadfec04f7e184c40a3273
22 blockchain_utils:
23 git:
24 url: https://github.com/cake-tech/blockchain_utils
cw_wownero/pubspec.lock
+2 -2
@@ -518,8 +518,8 @@ packages:
518 dependency: transitive
519 description:
520 path: "."
521 - ref: cake-update-v2
522 - resolved-ref: "93440dc5126369b873ca1fccc13c3c1240b1c5c2"
521 + ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
522 + resolved-ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
523 url: "https://github.com/cake-tech/on_chain.git"
524 source: git
525 version: "3.7.0"
cw_zano/pubspec.lock
+2 -2
@@ -515,8 +515,8 @@ packages:
515 dependency: transitive
516 description:
517 path: "."
518 - ref: cake-update-v2
519 - resolved-ref: "93440dc5126369b873ca1fccc13c3c1240b1c5c2"
518 + ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
519 + resolved-ref: "096865a8c6b89c260beadfec04f7e184c40a3273"
520 url: "https://github.com/cake-tech/on_chain.git"
521 source: git
522 version: "3.7.0"
lib/exchange/provider/jupiter_exchange_provider.dart
+12 -15
@@ -17,29 +17,16 @@ import 'package:cw_core/utils/print_verbose.dart';
17 import 'package:cw_core/utils/proxy_wrapper.dart';
18
19 class JupiterExchangeProvider extends ExchangeProvider {
20 - JupiterExchangeProvider() : super(pairList: _getSupportedPairs());
20 + JupiterExchangeProvider();
21
22 // Jupiter only supports Solana tokens
23 static const List<CryptoCurrency> _notSupported = [];
24
25 - static List<ExchangePair> _getSupportedPairs() {
26 - // Only support Solana and Solana tokens
27 - final solanaCurrencies = CryptoCurrency.all
25 + static final List<CryptoCurrency> _supportedCurrencies = CryptoCurrency.all
26 .where((c) => c.tag == 'SOL' || c == CryptoCurrency.sol)
27 .where((c) => !_notSupported.contains(c))
28 .toList();
29
32 - final pairs = <ExchangePair>[];
33 - for (final from in solanaCurrencies) {
34 - for (final to in solanaCurrencies) {
35 - if (from != to) {
36 - pairs.add(ExchangePair(from: from, to: to, reverse: true));
37 - }
38 - }
39 - }
40 - return pairs;
41 - }
42 -
30 static const _baseUrl = 'api.jup.ag';
31 static const _orderPath = '/ultra/v1/order';
32 static const _executePath = '/ultra/v1/execute';
@@ -148,6 +135,10 @@ class JupiterExchangeProvider extends ExchangeProvider {
135 required bool isReceiveAmount,
136 }) async {
137 try {
138 + // must support both
139 + if (!_supportedCurrencies.contains(from) || !_supportedCurrencies.contains(to)) {
140 + return 0.0;
141 + }
142 final inputMint = _getTokenMint(from);
143 final outputMint = _getTokenMint(to);
144
@@ -235,6 +226,12 @@ class JupiterExchangeProvider extends ExchangeProvider {
226 required bool isSendAll,
227 }) async {
228 try {
229 + // must support both
230 + if (!_supportedCurrencies.contains(request.fromCurrency) ||
231 + !_supportedCurrencies.contains(request.toCurrency)) {
232 + throw "not supported currencies";
233 + }
234 +
235 final inputMint = _getTokenMint(request.fromCurrency);
236 final outputMint = _getTokenMint(request.toCurrency);
237
lib/src/screens/new_wallet/advanced_privacy_settings_page.dart
+1 -1
@@ -300,7 +300,7 @@ class _AdvancedPrivacySettingsBodyState extends State<_AdvancedPrivacySettingsBo
300 bottomSectionPadding: EdgeInsets.all(24),
301 bottomSection: Column(
302 children: [
303 - const SizedBox(height: 24),
303 + const SizedBox(height: 4),
304 LayoutBuilder(
305 builder: (_, constraints) => SizedBox(
306 width: constraints.maxWidth * 0.8,
lib/src/screens/send/widgets/send_card.dart
+3 -1
@@ -361,7 +361,9 @@ class SendCardState extends State<SendCard> with AutomaticKeepAliveClientMixin<S
361 }
362
363 await Future.delayed(const Duration(seconds: 2));
364 - if (loadingBottomSheetContext != null && loadingBottomSheetContext!.mounted) {
364 + if (loadingBottomSheetContext != null &&
365 + loadingBottomSheetContext!.mounted &&
366 + Navigator.canPop(loadingBottomSheetContext!)) {
367 Navigator.of(loadingBottomSheetContext!).pop();
368 }
369
lib/view_model/exchange/exchange_view_model.dart
+1 -1
@@ -213,7 +213,7 @@ abstract class ExchangeViewModelBase extends WalletChangeListenerViewModel with
213 ].contains(wallet.type);
214
215 bool get hideAddressAfterExchange =>
216 - [WalletType.monero, WalletType.wownero].contains(wallet.type);
216 + [WalletType.monero, WalletType.wownero, WalletType.zcash].contains(wallet.type);
217
218 bool _useTorOnly;
219 final Box<Trade> trades;
pubspec_base.yaml
+1 -1
@@ -126,7 +126,7 @@ dependencies:
126 on_chain:
127 git:
128 url: https://github.com/cake-tech/on_chain.git
129 - ref: cake-update-v2
129 + ref: 096865a8c6b89c260beadfec04f7e184c40a3273
130 reown_walletkit:
131 path: ./scripts/reown_flutter/packages/reown_walletkit
132 blockchain_utils:
test/widget_test.dart
+5 -1
@@ -5,15 +5,19 @@
5 // gestures. You can also use WidgetTester to find child widgets in the widget
6 // tree, read text, and verify that the values of widget properties are correct.
7
8 +import 'dart:async';
9 +
10 import 'package:flutter/material.dart';
11 import 'package:flutter_test/flutter_test.dart';
12
13 import 'package:cake_wallet/main.dart';
14
15 +final quickActionsStream = StreamController<Uri?>.broadcast();
16 +
17 void main() {
18 testWidgets('Counter increments smoke test', (WidgetTester tester) async {
19 // Build our app and trigger a frame.
16 - await tester.pumpWidget(App());
20 + await tester.pumpWidget(App(quickActionsStream: quickActionsStream.stream));
21
22 // Verify that our counter starts at 0.
23 expect(find.text('0'), findsOneWidget);