Version txstore so it starts from zero
MODIFY
WalletWasabi.Tests/UnitTests/Transactions/AllTransactionStoreTests.cs
WalletWasabi.Tests/UnitTests/Transactions/AllTransactionStoreTests.cs
@@ -38,7 +38,7 @@ namespace WalletWasabi.Tests.UnitTests.Transactions
var dir = GetWorkDir();
var mempoolFile = Path.Combine(dir, "Mempool", "Transactions.dat");
- var txFile = Path.Combine(dir, "ConfirmedTransactions", "Transactions.dat");
+ var txFile = Path.Combine(dir, "ConfirmedTransactions", "2", "Transactions.dat");
var mempoolContent = await File.ReadAllBytesAsync(mempoolFile);
var txContent = await File.ReadAllBytesAsync(txFile);
@@ -54,7 +54,7 @@ namespace WalletWasabi.Tests.UnitTests.Transactions
string dir = PrepareWorkDir();
var network = Network.TestNet;
var mempoolFile = Path.Combine(dir, "Mempool", "Transactions.dat");
- var txFile = Path.Combine(dir, "ConfirmedTransactions", "Transactions.dat");
+ var txFile = Path.Combine(dir, "ConfirmedTransactions", "2", "Transactions.dat");
IoHelpers.EnsureContainingDirectoryExists(mempoolFile);
IoHelpers.EnsureContainingDirectoryExists(txFile);
@@ -225,7 +225,7 @@ namespace WalletWasabi.Tests.UnitTests.Transactions
string dir = PrepareWorkDir();
var network = Network.TestNet;
var mempoolFile = Path.Combine(dir, "Mempool", "Transactions.dat");
- var txFile = Path.Combine(dir, "ConfirmedTransactions", "Transactions.dat");
+ var txFile = Path.Combine(dir, "ConfirmedTransactions", "2", "Transactions.dat");
IoHelpers.EnsureContainingDirectoryExists(mempoolFile);
IoHelpers.EnsureContainingDirectoryExists(txFile);
@@ -388,7 +388,7 @@ namespace WalletWasabi.Tests.UnitTests.Transactions
dir = PrepareWorkDir(caller);
network = Network.TestNet;
mempoolFile = Path.Combine(dir, "Mempool", "Transactions.dat");
- txFile = Path.Combine(dir, "ConfirmedTransactions", "Transactions.dat");
+ txFile = Path.Combine(dir, "ConfirmedTransactions", "2", "Transactions.dat");
IoHelpers.EnsureContainingDirectoryExists(mempoolFile);
IoHelpers.EnsureContainingDirectoryExists(txFile);

MODIFY
WalletWasabi/Blockchain/Transactions/AllTransactionStore.cs
WalletWasabi/Blockchain/Transactions/AllTransactionStore.cs
@@ -15,6 +15,7 @@ namespace WalletWasabi.Blockchain.Transactions
{
#region Initializers
+ private const int ConfirmedTransactionsVersion = 2;
private string WorkFolderPath { get; set; }
private Network Network { get; set; }
@@ -34,7 +35,7 @@ namespace WalletWasabi.Blockchain.Transactions
Lock = new object();
var mempoolWorkFolder = Path.Combine(WorkFolderPath, "Mempool");
- var confirmedWorkFolder = Path.Combine(WorkFolderPath, "ConfirmedTransactions");
+ var confirmedWorkFolder = Path.Combine(WorkFolderPath, "ConfirmedTransactions", ConfirmedTransactionsVersion.ToString());
var initTasks = new[]
{

MODIFY
WalletWasabi/Blockchain/Transactions/TransactionStore.cs
WalletWasabi/Blockchain/Transactions/TransactionStore.cs
@@ -33,7 +33,7 @@ namespace WalletWasabi.Blockchain.Transactions
Transactions = new Dictionary<uint256, SmartTransaction>();
TransactionsLock = new object();
- var fileName = Path.Combine(WorkFolderPath, "Transactions.dat");
+ var fileName = Path.Combine(WorkFolderPath, $"Transactions.dat");
var transactionsFilePath = Path.Combine(WorkFolderPath, fileName);
TransactionsFileManager = new MutexIoManager(transactionsFilePath);

Version txstore so it starts from zero