Add BitcoinStore Initialization ensurement.
MODIFY
WalletWasabi/Services/WalletService.cs
WalletWasabi/Services/WalletService.cs
@@ -264,6 +264,13 @@ namespace WalletWasabi.Services
throw new NotSupportedException($"{nameof(Synchronizer)} is not running.");
}
+ while (!BitcoinStore.IsInitialized)
+ {
+ await Task.Delay(100).ConfigureAwait(false);
+
+ cancel.ThrowIfCancellationRequested();
+ }
+
await RuntimeParams.LoadAsync();
using (await HandleFiltersLock.LockAsync())

MODIFY
WalletWasabi/Stores/BitcoinStore.cs
WalletWasabi/Stores/BitcoinStore.cs
@@ -17,6 +17,7 @@ namespace WalletWasabi.Stores
/// </summary>
public class BitcoinStore
{
+ public bool IsInitialized { get; private set; }
private string WorkFolderPath { get; set; }
private Network Network { get; set; }
@@ -56,6 +57,8 @@ namespace WalletWasabi.Stores
await Task.WhenAll(initTasks).ConfigureAwait(false);
await IndexStore.InitializeAsync(indexStoreFolderPath, Network, HashChain).ConfigureAwait(false);
+
+ IsInitialized = true;
}
}
}

Add BitcoinStore Initialization ensurement.