diff --git a/miner-app/lib/features/miner/miner_controls.dart b/miner-app/lib/features/miner/miner_controls.dart index 70b9c5f56..9c32370df 100644 --- a/miner-app/lib/features/miner/miner_controls.dart +++ b/miner-app/lib/features/miner/miner_controls.dart @@ -2,7 +2,6 @@ import 'dart:async'; import 'dart:io'; import 'package:flutter/material.dart'; -import 'package:quantus_miner/src/config/miner_config.dart'; import 'package:quantus_miner/src/services/miner_wallet_service.dart'; import 'package:quantus_miner/src/services/mining_orchestrator.dart'; import 'package:quantus_miner/src/services/mining_stats_service.dart'; @@ -38,7 +37,6 @@ class _MinerControlsState extends State { int _cpuWorkers = 8; int _gpuDevices = 0; int _detectedGpuCount = 0; - String _chainId = MinerConfig.defaultChainId; final _settingsService = MinerSettingsService(); @override @@ -51,13 +49,11 @@ class _MinerControlsState extends State { Future _loadSettings() async { final savedCpuWorkers = await _settingsService.getCpuWorkers(); final savedGpuDevices = await _settingsService.getGpuDevices(); - final savedChainId = await _settingsService.getChainId(); if (mounted) { setState(() { _cpuWorkers = savedCpuWorkers ?? (Platform.numberOfProcessors > 0 ? Platform.numberOfProcessors : 8); _gpuDevices = savedGpuDevices ?? 0; - _chainId = savedChainId; }); } } @@ -93,13 +89,6 @@ class _MinerControlsState extends State { Future _startNode() async { _log.i('Starting node'); - // Reload chain ID in case it was changed in settings - final chainId = await _settingsService.getChainId(); - if (mounted) { - setState(() => _chainId = chainId); - } - - // Get rewards preimage directly from the wallet (not from file) final walletService = MinerWalletService(); final wormholeKeyPair = await walletService.getWormholeKeyPair(); if (wormholeKeyPair == null) { @@ -110,7 +99,6 @@ class _MinerControlsState extends State { return; } - // Check for required files final quantusHome = await BinaryManager.getQuantusHomeDirectoryPath(); final identityFile = File('$quantusHome/node_key.p2p'); final nodeBinPath = await BinaryManager.getNodeBinaryFilePath(); @@ -126,7 +114,6 @@ class _MinerControlsState extends State { return; } - // Create new orchestrator final orchestrator = MiningOrchestrator(); widget.onOrchestratorChanged(orchestrator); @@ -138,7 +125,6 @@ class _MinerControlsState extends State { identityFile: identityFile, rewardsInnerHash: wormholeKeyPair.rewardsPreimageHex, wormholeAddress: wormholeKeyPair.address, - chainId: _chainId, cpuWorkers: _cpuWorkers, gpuDevices: _gpuDevices, detectedGpuCount: _detectedGpuCount, diff --git a/miner-app/lib/features/settings/settings_screen.dart b/miner-app/lib/features/settings/settings_screen.dart index d484c34f2..c8d534d86 100644 --- a/miner-app/lib/features/settings/settings_screen.dart +++ b/miner-app/lib/features/settings/settings_screen.dart @@ -1,10 +1,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:quantus_miner/features/settings/settings_app_bar.dart'; -import 'package:quantus_miner/main.dart'; -import 'package:quantus_miner/src/config/miner_config.dart'; import 'package:quantus_miner/src/services/binary_manager.dart'; -import 'package:quantus_miner/src/services/miner_settings_service.dart'; import 'package:quantus_miner/src/services/miner_wallet_service.dart'; import 'package:quantus_sdk/quantus_sdk.dart'; @@ -20,10 +17,7 @@ class _SettingsScreenState extends State { BinaryVersion? _nodeUpdateInfo; bool _isLoading = true; - // Chain selection - final MinerSettingsService _settingsService = MinerSettingsService(); final MinerWalletService _walletService = MinerWalletService(); - String _selectedChainId = MinerConfig.defaultChainId; @override void initState() { @@ -39,77 +33,15 @@ class _SettingsScreenState extends State { BinaryManager.getMinerBinaryVersion(), ]); - final chainId = await _settingsService.getChainId(); - if (mounted) { setState(() { _minerUpdateInfo = minerUpdateInfo; _nodeUpdateInfo = nodeUpdateInfo; - _selectedChainId = chainId; _isLoading = false; }); } } - Future _onChainChanged(String? newChainId) async { - if (newChainId == null || newChainId == _selectedChainId) return; - - // Check if mining is currently running - final orchestrator = GlobalMinerManager.getOrchestrator(); - final isMining = orchestrator?.isRunning ?? false; - - if (isMining) { - // Show warning dialog - final shouldChange = await showDialog( - context: context, - builder: (context) => AlertDialog( - backgroundColor: const Color(0xFF1C1C1C), - shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(16)), - title: const Text('Stop Mining?', style: TextStyle(color: Colors.white)), - content: const Text( - 'Changing the chain requires stopping mining first. ' - 'Do you want to stop mining and switch chains?', - style: TextStyle(color: Colors.white70), - ), - actions: [ - TextButton( - onPressed: () => Navigator.of(context).pop(false), - child: Text('Cancel', style: TextStyle(color: Colors.white.useOpacity(0.7))), - ), - TextButton( - onPressed: () => Navigator.of(context).pop(true), - style: TextButton.styleFrom(foregroundColor: const Color(0xFF00E676)), - child: const Text('Stop & Switch'), - ), - ], - ), - ); - - if (shouldChange != true) return; - - // Stop mining - await orchestrator?.stop(); - } - - // Save the new chain ID - await _settingsService.saveChainId(newChainId); - - if (mounted) { - setState(() { - _selectedChainId = newChainId; - }); - - // Show confirmation - ScaffoldMessenger.of(context).showSnackBar( - SnackBar( - content: Text('Switched to ${MinerConfig.getChainById(newChainId).displayName}'), - backgroundColor: const Color(0xFF00E676), - behavior: SnackBarBehavior.floating, - ), - ); - } - } - @override Widget build(BuildContext context) { // Define a theme-consistent accent color (e.g., a tech green or teal) @@ -177,23 +109,6 @@ class _SettingsScreenState extends State { const SizedBox(height: 32), - // Network Section Header - Text( - 'NETWORK', - style: TextStyle( - color: Colors.white.useOpacity(0.5), - fontSize: 12, - letterSpacing: 1.5, - fontWeight: FontWeight.w600, - ), - ), - const SizedBox(height: 16), - - // Chain Selector - _buildChainSelector(accentColor), - - const SizedBox(height: 32), - // Wallet Section Header Text( 'WALLET', @@ -291,79 +206,6 @@ class _SettingsScreenState extends State { ); } - Widget _buildChainSelector(Color accentColor) { - final selectedChain = MinerConfig.getChainById(_selectedChainId); - - return Container( - padding: const EdgeInsets.all(16), - decoration: BoxDecoration( - color: const Color(0xFF1C1C1C), - borderRadius: BorderRadius.circular(16), - border: Border.all(color: Colors.white.useOpacity(0.05), width: 1), - boxShadow: [BoxShadow(color: Colors.black.useOpacity(0.2), blurRadius: 10, offset: const Offset(0, 4))], - ), - child: Row( - children: [ - // Icon Container - Container( - padding: const EdgeInsets.all(10), - decoration: BoxDecoration(color: accentColor.useOpacity(0.1), borderRadius: BorderRadius.circular(12)), - child: Icon(Icons.link_rounded, color: accentColor, size: 20), - ), - const SizedBox(width: 16), - - // Title and description - Expanded( - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - const Text( - 'Chain', - style: TextStyle(color: Colors.white, fontSize: 16, fontWeight: FontWeight.w500), - ), - const SizedBox(height: 2), - Text(selectedChain.description, style: TextStyle(color: Colors.white.useOpacity(0.5), fontSize: 12)), - ], - ), - ), - - // Dropdown - if (_isLoading) - SizedBox( - width: 16, - height: 16, - child: CircularProgressIndicator(strokeWidth: 2, color: Colors.white.useOpacity(0.3)), - ) - else - Container( - padding: const EdgeInsets.symmetric(horizontal: 8), - decoration: BoxDecoration( - color: Colors.black, - borderRadius: BorderRadius.circular(8), - border: Border.all(color: Colors.white.useOpacity(0.1)), - ), - child: DropdownButton( - value: _selectedChainId, - dropdownColor: const Color(0xFF1C1C1C), - underline: const SizedBox(), - icon: Icon(Icons.arrow_drop_down, color: Colors.white.useOpacity(0.7)), - style: TextStyle( - color: Colors.white.useOpacity(0.9), - fontFamily: 'Courier', - fontWeight: FontWeight.bold, - fontSize: 13, - ), - items: MinerConfig.availableChains.map((chain) { - return DropdownMenuItem(value: chain.id, child: Text(chain.displayName)); - }).toList(), - onChanged: _onChainChanged, - ), - ), - ], - ), - ); - } - Widget _buildActionTile({ required String title, required String subtitle, diff --git a/miner-app/lib/features/withdrawal/claim_rewards_dialog.dart b/miner-app/lib/features/withdrawal/claim_rewards_dialog.dart index 05eab0b8a..3b9807d14 100644 --- a/miner-app/lib/features/withdrawal/claim_rewards_dialog.dart +++ b/miner-app/lib/features/withdrawal/claim_rewards_dialog.dart @@ -2,7 +2,6 @@ import 'dart:io'; import 'package:flutter/material.dart'; import 'package:quantus_miner/src/services/binary_manager.dart'; -import 'package:quantus_miner/src/services/miner_settings_service.dart'; import 'package:quantus_miner/src/services/miner_wallet_service.dart'; import 'package:quantus_miner/src/services/wormhole_claim_service.dart'; import 'package:quantus_miner/src/utils/app_logger.dart'; @@ -32,7 +31,6 @@ class _ClaimRewardsDialogState extends State<_ClaimRewardsDialog> { final _addressController = TextEditingController(); final _claimService = WormholeClaimService(); final _walletService = MinerWalletService(); - final _settingsService = MinerSettingsService(); _Screen _screen = _Screen.input; String? _addressError; @@ -101,18 +99,15 @@ class _ClaimRewardsDialogState extends State<_ClaimRewardsDialog> { throw StateError('Wormhole key pair not available'); } - final chainConfig = await _settingsService.getChainConfig(); final binsDir = '${await BinaryManager.getQuantusHomeDirectoryPath()}/generated-bins'; await Directory(binsDir).create(recursive: true); - final rpcUrl = chainConfig.rpcUrl; _log.i('Starting claim for ${keyPair.address} to ${_addressController.text.trim()}'); final result = await _claimService.claimRewards( wormholeAddress: keyPair.address, secretHex: keyPair.secretHex, destinationAddress: _addressController.text.trim(), - rpcUrl: rpcUrl, circuitBinsDir: binsDir, onProgress: (progress) { if (!mounted) return; diff --git a/miner-app/lib/src/config/miner_config.dart b/miner-app/lib/src/config/miner_config.dart index bf76e1854..e3ce8f5b1 100644 --- a/miner-app/lib/src/config/miner_config.dart +++ b/miner-app/lib/src/config/miner_config.dart @@ -101,41 +101,9 @@ class MinerConfig { // Chain Configuration // ============================================================ - /// Available chain IDs - static const List availableChains = [ - ChainConfig( - id: 'dev', - displayName: 'Development', - description: 'Local development chain', - rpcUrl: 'http://127.0.0.1:9933', - subsquidUrl: 'http://127.0.0.1:4350/graphql', - isDefault: false, - ), - ChainConfig( - id: 'dirac', - displayName: 'Dirac', - description: 'Dirac testnet', - rpcUrl: 'https://a1-dirac.quantus.cat', - subsquidUrl: 'https://subsquid.quantus.com/blue/graphql', - isDefault: false, - ), - ChainConfig( - id: 'planck', - displayName: 'Planck Testnet', - description: 'Planck testnet', - rpcUrl: 'https://a1-planck.quantus.cat', - subsquidUrl: 'http://127.0.0.1:4000/graphql', // Local Subsquid for testing - isDefault: true, - ), - ]; - - /// Get chain config by ID, returns dev chain if not found - static ChainConfig getChainById(String id) { - return availableChains.firstWhere((chain) => chain.id == id, orElse: () => availableChains.first); - } - - /// The default chain ID - static String get defaultChainId => availableChains.firstWhere((c) => c.isDefault).id; + /// Chain spec passed to the local node binary via `--chain`. + /// Wallet/UTXO/claim endpoints come from `AppConstants` in the SDK. + static const String chainId = 'planck'; // ============================================================ // Process Names (for cleanup) @@ -170,30 +138,3 @@ class MinerConfig { /// Number of ports to try when finding an alternative static const int portSearchRange = 10; } - -/// Configuration for a blockchain network. -/// -/// Named ChainConfig to avoid conflict with ChainInfo in chain_rpc_client.dart -class ChainConfig { - final String id; - final String displayName; - final String description; - final String rpcUrl; - final String? subsquidUrl; - final bool isDefault; - - const ChainConfig({ - required this.id, - required this.displayName, - required this.description, - required this.rpcUrl, - this.subsquidUrl, - this.isDefault = false, - }); - - /// Whether this chain uses the local node RPC - bool get isLocalNode => rpcUrl.contains('127.0.0.1') || rpcUrl.contains('localhost'); - - @override - String toString() => 'ChainConfig(id: $id, displayName: $displayName, rpcUrl: $rpcUrl)'; -} diff --git a/miner-app/lib/src/services/miner_settings_service.dart b/miner-app/lib/src/services/miner_settings_service.dart index be6f26295..3a4f14bc3 100644 --- a/miner-app/lib/src/services/miner_settings_service.dart +++ b/miner-app/lib/src/services/miner_settings_service.dart @@ -1,10 +1,8 @@ import 'dart:io'; -import 'package:quantus_miner/src/config/miner_config.dart'; import 'package:quantus_miner/src/services/binary_manager.dart'; import 'package:quantus_miner/src/services/miner_wallet_service.dart'; import 'package:quantus_miner/src/utils/app_logger.dart'; -import 'package:quantus_sdk/quantus_sdk.dart'; import 'package:shared_preferences/shared_preferences.dart'; final _log = log.withTag('Settings'); @@ -13,14 +11,12 @@ final _log = log.withTag('Settings'); /// /// This is a singleton - use `MinerSettingsService()` to get the instance. class MinerSettingsService { - // Singleton static final MinerSettingsService _instance = MinerSettingsService._internal(); factory MinerSettingsService() => _instance; MinerSettingsService._internal(); static const String _keyCpuWorkers = 'cpu_workers'; static const String _keyGpuDevices = 'gpu_devices'; - static const String _keyChainId = 'chain_id'; Future saveCpuWorkers(int cpuWorkers) async { final prefs = await SharedPreferences.getInstance(); @@ -42,64 +38,6 @@ class MinerSettingsService { return prefs.getInt(_keyGpuDevices); } - /// Save the selected chain ID and configure endpoints accordingly. - Future saveChainId(String chainId) async { - final prefs = await SharedPreferences.getInstance(); - await prefs.setString(_keyChainId, chainId); - // Update GraphQL endpoint for the selected chain - _configureEndpointsForChain(chainId); - } - - /// Configure RPC and GraphQL endpoints based on chain ID. - void _configureEndpointsForChain(String chainId) { - final chain = MinerConfig.getChainById(chainId); - _log.i('Configuring endpoints for chain $chainId:'); - _log.i(' RPC: ${chain.rpcUrl}'); - _log.i(' GraphQL: ${chain.subsquidUrl ?? 'not configured'}'); - - // Configure RPC endpoint for SubstrateService - final rpcService = RpcEndpointService(); - _log.i(' RPC endpoints before: ${rpcService.endpoints.length}'); - // rpcService.setEndpoints([chain.rpcUrl]); - // _log.i(' RPC endpoints after: ${rpcService.endpoints.length}'); - // _log.i(' Best RPC endpoint: ${rpcService.bestEndpointUrl}'); - - // Configure GraphQL endpoint (for any remaining Subsquid usage) - // if (chain.subsquidUrl != null) { - // GraphQlEndpointService().setEndpoints([chain.subsquidUrl!]); - // } else { - // GraphQlEndpointService().setEndpoints([]); - // } - } - - /// Get the saved chain ID, returns default if not set. - /// Also configures GraphQL endpoints for the chain. - Future getChainId() async { - final prefs = await SharedPreferences.getInstance(); - final savedChainId = prefs.getString(_keyChainId); - String chainId; - if (savedChainId == null) { - chainId = MinerConfig.defaultChainId; - } else { - // Validate that the chain ID is still valid - final validIds = MinerConfig.availableChains.map((c) => c.id).toList(); - if (!validIds.contains(savedChainId)) { - chainId = MinerConfig.defaultChainId; - } else { - chainId = savedChainId; - } - } - // Configure endpoints for this chain - _configureEndpointsForChain(chainId); - return chainId; - } - - /// Get the ChainConfig for the saved chain ID. - Future getChainConfig() async { - final chainId = await getChainId(); - return MinerConfig.getChainById(chainId); - } - Future logout() async { _log.i('Starting app logout/reset...'); diff --git a/miner-app/lib/src/services/mining_orchestrator.dart b/miner-app/lib/src/services/mining_orchestrator.dart index 8cca8c4f0..214338af6 100644 --- a/miner-app/lib/src/services/mining_orchestrator.dart +++ b/miner-app/lib/src/services/mining_orchestrator.dart @@ -64,9 +64,6 @@ class MiningSessionConfig { /// Used for transfer tracking. final String? wormholeAddress; - /// Chain ID to connect to. - final String chainId; - /// Number of CPU worker threads. final int cpuWorkers; @@ -85,7 +82,6 @@ class MiningSessionConfig { required this.identityFile, required this.rewardsInnerHash, this.wormholeAddress, - this.chainId = 'dev', this.cpuWorkers = 8, this.gpuDevices = 0, this.detectedGpuCount = 0, @@ -221,11 +217,9 @@ class MiningOrchestrator { _statsService.updateGpuCapacity(config.detectedGpuCount); _emitStats(); - // Perform pre-start cleanup _setState(MiningState.startingNode); - await ProcessCleanupService.performPreStartCleanup(config.chainId); + await ProcessCleanupService.performPreStartCleanup(); - // Ensure ports are available final ports = await ProcessCleanupService.ensurePortsAvailable( quicPort: config.minerListenPort, metricsPort: MinerConfig.defaultMinerMetricsPort, @@ -233,13 +227,11 @@ class MiningOrchestrator { _actualMetricsPort = ports['metrics']!; _updateMetricsClient(); - // Start node with rewards inner hash directly from config await _nodeManager.start( NodeConfig( binary: config.nodeBinary, identityFile: config.identityFile, rewardsInnerHash: config.rewardsInnerHash, - chainId: config.chainId, minerListenPort: config.minerListenPort, ), ); @@ -278,7 +270,6 @@ class MiningOrchestrator { minerBinary: _currentConfig!.minerBinary, identityFile: _currentConfig!.identityFile, rewardsInnerHash: _currentConfig!.rewardsInnerHash, - chainId: _currentConfig!.chainId, cpuWorkers: cpuWorkers ?? _currentConfig!.cpuWorkers, gpuDevices: gpuDevices ?? _currentConfig!.gpuDevices, detectedGpuCount: _currentConfig!.detectedGpuCount, diff --git a/miner-app/lib/src/services/node_process_manager.dart b/miner-app/lib/src/services/node_process_manager.dart index 98604f009..6b66ba3e9 100644 --- a/miner-app/lib/src/services/node_process_manager.dart +++ b/miner-app/lib/src/services/node_process_manager.dart @@ -24,9 +24,6 @@ class NodeConfig { /// Must be hex-encoded with 0x prefix. final String rewardsInnerHash; - /// Chain ID to connect to ('dev' or 'dirac'). - final String chainId; - /// Port for the QUIC miner connection. final int minerListenPort; @@ -43,7 +40,6 @@ class NodeConfig { required this.binary, required this.identityFile, required this.rewardsInnerHash, - this.chainId = 'dev', this.minerListenPort = 9833, this.rpcPort = 9933, this.prometheusPort = 9616, @@ -136,19 +132,25 @@ class NodeProcessManager extends BaseProcessManager { List _buildArgs(NodeConfig config, String basePath) { return [ - // Only use --base-path for non-dev chains (dev uses temp storage for fresh state) - if (config.chainId != 'dev') ...['--base-path', basePath], - '--node-key-file', config.identityFile.path, - '--rewards-inner-hash', config.rewardsInnerHash, + '--base-path', + basePath, + '--node-key-file', + config.identityFile.path, + '--rewards-inner-hash', + config.rewardsInnerHash, '--validator', - // Chain selection - if (config.chainId == 'dev') '--dev' else ...['--chain', config.chainId], - '--port', config.p2pPort.toString(), - '--prometheus-port', config.prometheusPort.toString(), + '--chain', + MinerConfig.chainId, + '--port', + config.p2pPort.toString(), + '--prometheus-port', + config.prometheusPort.toString(), '--experimental-rpc-endpoint', 'listen-addr=${MinerConfig.localhost}:${config.rpcPort},methods=unsafe,cors=all', - '--name', 'QuantusMinerGUI', - '--miner-listen-port', config.minerListenPort.toString(), + '--name', + 'QuantusMinerGUI', + '--miner-listen-port', + config.minerListenPort.toString(), '--enable-peer-sharing', ]; } diff --git a/miner-app/lib/src/services/process_cleanup_service.dart b/miner-app/lib/src/services/process_cleanup_service.dart index a144e6870..59f8faefc 100644 --- a/miner-app/lib/src/services/process_cleanup_service.dart +++ b/miner-app/lib/src/services/process_cleanup_service.dart @@ -307,10 +307,10 @@ class ProcessCleanupService { // ============================================================ /// Cleanup database lock files that may prevent node startup. - static Future cleanupDatabaseLocks(String chainId) async { + static Future cleanupDatabaseLocks() async { try { final quantusHome = await BinaryManager.getQuantusHomeDirectoryPath(); - final lockFilePath = '$quantusHome/node_data/chains/$chainId/db/full/LOCK'; + final lockFilePath = '$quantusHome/node_data/chains/${MinerConfig.chainId}/db/full/LOCK'; final lockFile = File(lockFilePath); if (await lockFile.exists()) { @@ -318,8 +318,7 @@ class ProcessCleanupService { _log.d(' Deleted lock file: $lockFilePath'); } - // Also check for other potential lock files - final dbDir = Directory('$quantusHome/node_data/chains/$chainId/db/full'); + final dbDir = Directory('$quantusHome/node_data/chains/${MinerConfig.chainId}/db/full'); if (await dbDir.exists()) { await for (final entity in dbDir.list()) { if (entity is File && entity.path.contains('LOCK')) { @@ -338,10 +337,10 @@ class ProcessCleanupService { } /// Check and fix database directory permissions. - static Future ensureDatabaseDirectoryAccess(String chainId) async { + static Future ensureDatabaseDirectoryAccess() async { try { final quantusHome = await BinaryManager.getQuantusHomeDirectoryPath(); - final dbPath = '$quantusHome/node_data/chains/$chainId/db'; + final dbPath = '$quantusHome/node_data/chains/${MinerConfig.chainId}/db'; final dbDir = Directory(dbPath); // Create the directory if it doesn't exist @@ -380,11 +379,11 @@ class ProcessCleanupService { /// - Existing miner processes /// - Database locks /// - Ensures directory access - static Future performPreStartCleanup(String chainId) async { + static Future performPreStartCleanup() async { await cleanupExistingNodeProcesses(); await cleanupExistingMinerProcesses(); - await cleanupDatabaseLocks(chainId); - await ensureDatabaseDirectoryAccess(chainId); + await cleanupDatabaseLocks(); + await ensureDatabaseDirectoryAccess(); } /// Kill all quantus processes by name. diff --git a/miner-app/lib/src/services/wormhole_claim_service.dart b/miner-app/lib/src/services/wormhole_claim_service.dart index 540c8adf9..2f2d79135 100644 --- a/miner-app/lib/src/services/wormhole_claim_service.dart +++ b/miner-app/lib/src/services/wormhole_claim_service.dart @@ -79,14 +79,13 @@ class WormholeClaimService { required String wormholeAddress, required String secretHex, required String destinationAddress, - required String rpcUrl, required String circuitBinsDir, required ClaimProgressCallback onProgress, }) async { final cancelCompleter = Completer(); _cancelCompleter = cancelCompleter; - final rpc = ChainRpcClient(rpcUrl: rpcUrl, timeout: const Duration(seconds: 30)); + final rpc = ChainRpcClient(rpcUrl: AppConstants.rpcEndpoints.first, timeout: const Duration(seconds: 30)); try { final flow = _runClaimFlow( rpc: rpc, diff --git a/miner-app/macos/Runner/Info.plist b/miner-app/macos/Runner/Info.plist index 4789daa6a..47451231f 100644 --- a/miner-app/macos/Runner/Info.plist +++ b/miner-app/macos/Runner/Info.plist @@ -28,5 +28,9 @@ MainMenu NSPrincipalClass NSApplication + LSApplicationQueriesSchemes + + mailto + diff --git a/miner-app/pubspec.lock b/miner-app/pubspec.lock index 0f34f005c..f3d218844 100644 --- a/miner-app/pubspec.lock +++ b/miner-app/pubspec.lock @@ -499,8 +499,8 @@ packages: dependency: transitive description: path: dart - ref: "v2.0.1" - resolved-ref: "57ac13fd7f92afe8e89da30b94fc69fd68125f6f" + ref: "v2.2.0" + resolved-ref: cd1beb73c12e574dc6f6ac9a4cd6896d3603b62b url: "https://github.com/Quantus-Network/qp-human-checkphrase.git" source: git version: "0.1.0" diff --git a/miner-app/pubspec.yaml b/miner-app/pubspec.yaml index 0a15d6716..8b022777f 100644 --- a/miner-app/pubspec.yaml +++ b/miner-app/pubspec.yaml @@ -1,6 +1,6 @@ name: quantus_miner description: Quantus PoW miner (desktop / mobile) -version: 0.4.0 +version: 0.4.1 publish_to: none environment: diff --git a/mobile-app/android/app/src/main/AndroidManifest.xml b/mobile-app/android/app/src/main/AndroidManifest.xml index 84a2a60ab..11654c360 100644 --- a/mobile-app/android/app/src/main/AndroidManifest.xml +++ b/mobile-app/android/app/src/main/AndroidManifest.xml @@ -79,6 +79,10 @@ + + + + diff --git a/mobile-app/android/app/src/main/res/drawable-v21/background.png b/mobile-app/android/app/src/main/res/drawable-v21/background.png index 8fa49a7c4..ae38b570a 100644 Binary files a/mobile-app/android/app/src/main/res/drawable-v21/background.png and b/mobile-app/android/app/src/main/res/drawable-v21/background.png differ diff --git a/mobile-app/android/app/src/main/res/drawable/background.png b/mobile-app/android/app/src/main/res/drawable/background.png index 8fa49a7c4..ae38b570a 100644 Binary files a/mobile-app/android/app/src/main/res/drawable/background.png and b/mobile-app/android/app/src/main/res/drawable/background.png differ diff --git a/mobile-app/android/app/src/main/res/values-night-v31/styles.xml b/mobile-app/android/app/src/main/res/values-night-v31/styles.xml index bab4e97cb..fe0b1f0c7 100644 --- a/mobile-app/android/app/src/main/res/values-night-v31/styles.xml +++ b/mobile-app/android/app/src/main/res/values-night-v31/styles.xml @@ -6,10 +6,10 @@ false false shortEdges - #141414 + #0E0E0E @drawable/android12branding @drawable/android12splash - #141414 + #0E0E0E