From 46428936c4e009747ce981ca012664ba4fdd3bbd Mon Sep 17 00:00:00 2001 From: Kenneth Skovhede Date: Fri, 14 Nov 2025 15:45:19 +0100 Subject: [PATCH] Various updates after the upgrade --- Duplicati.slnx | 2 +- .../Interface/Duplicati.Library.Interface.csproj | 4 ---- .../Main/Operation/Backup/FileEnumerationProcess.cs | 12 +++++++++++- Duplicati/Library/Main/Operation/BackupHandler.cs | 6 +++--- .../Library/Main/Operation/FilelistProcessor.cs | 2 +- .../Library/Main/Operation/ListChangesHandler.cs | 2 +- .../Library/Main/Operation/ListFolderHandler.cs | 2 +- Executables/Duplicati.Agent/Duplicati.Agent.csproj | 6 +++--- .../Duplicati.CommandLine.AutoUpdater.csproj | 4 ++-- .../Duplicati.CommandLine.BackendTester.csproj | 4 ++-- .../Duplicati.CommandLine.BackendTool.csproj | 4 ++-- .../Duplicati.CommandLine.DatabaseTool.csproj | 4 ++-- .../Duplicati.CommandLine.RecoveryTool.csproj | 4 ++-- .../Duplicati.CommandLine.SecretTool.csproj | 4 ++-- .../Duplicati.CommandLine.ServerUtil.csproj | 4 ++-- .../Duplicati.CommandLine.SharpAESCrypt.csproj | 4 ++-- .../Duplicati.CommandLine.Snapshots.csproj | 4 ++-- .../Duplicati.CommandLine.SourceTool.csproj | 4 ++-- .../Duplicati.CommandLine.SyncTool.csproj | 4 ++-- .../Duplicati.CommandLine.csproj | 4 ++-- .../Duplicati.GUI.TrayIcon.csproj | 8 ++++---- Executables/Duplicati.Server/Duplicati.Server.csproj | 4 ++-- .../Duplicati.Service/Duplicati.Service.csproj | 4 ++-- .../Duplicati.WindowsModulesLoader.csproj | 4 ++-- .../Duplicati.WindowsService.csproj | 4 ++-- 25 files changed, 57 insertions(+), 51 deletions(-) diff --git a/Duplicati.slnx b/Duplicati.slnx index 2bbaccdee..40c5f903e 100644 --- a/Duplicati.slnx +++ b/Duplicati.slnx @@ -28,7 +28,7 @@ - + diff --git a/Duplicati/Library/Interface/Duplicati.Library.Interface.csproj b/Duplicati/Library/Interface/Duplicati.Library.Interface.csproj index e7cd592ec..a9b0c43a6 100644 --- a/Duplicati/Library/Interface/Duplicati.Library.Interface.csproj +++ b/Duplicati/Library/Interface/Duplicati.Library.Interface.csproj @@ -12,8 +12,4 @@ - - - - diff --git a/Duplicati/Library/Main/Operation/Backup/FileEnumerationProcess.cs b/Duplicati/Library/Main/Operation/Backup/FileEnumerationProcess.cs index c09235b7a..68f7588f9 100644 --- a/Duplicati/Library/Main/Operation/Backup/FileEnumerationProcess.cs +++ b/Duplicati/Library/Main/Operation/Backup/FileEnumerationProcess.cs @@ -119,7 +119,17 @@ namespace Duplicati.Library.Main.Operation.Backup } } } - worklist = ExpandSources(changedfilelist).WhereAwait(FilterEntry); + + async IAsyncEnumerable FilterExpandedSources(IAsyncEnumerable source) + { + await foreach (var entry in source.ConfigureAwait(false)) + { + if (await FilterEntry(entry).ConfigureAwait(false)) + yield return entry; + } + } + + worklist = FilterExpandedSources(ExpandSources(changedfilelist)); } else if (journalService != null) { diff --git a/Duplicati/Library/Main/Operation/BackupHandler.cs b/Duplicati/Library/Main/Operation/BackupHandler.cs index 359ff96e9..0543ad711 100644 --- a/Duplicati/Library/Main/Operation/BackupHandler.cs +++ b/Duplicati/Library/Main/Operation/BackupHandler.cs @@ -232,7 +232,7 @@ namespace Duplicati.Library.Main.Operation // all of the local database classes handle this), as the constructor // is not async and shouldn't be executing "heavy" code, such as // database queries. - var journalData = m_database.GetChangeJournalData(lastfilesetid, m_taskReader.ProgressToken).ToEnumerable(); + var journalData = m_database.GetChangeJournalData(lastfilesetid, m_taskReader.ProgressToken).ToBlockingEnumerable(); var service = new UsnJournalService(fileProvider.SnapshotService, filter, m_options.FileAttributeFilter, m_options.SkipFilesLargerThan, journalData, cancellationTokenSource.Token); @@ -586,11 +586,11 @@ namespace Duplicati.Library.Main.Operation .ConfigureAwait(false); // Calculate the number of samples to test, using the largest number of file of a given type - long remoteVolumeCount = await m_database + var remoteVolumeCount = await m_database .GetRemoteVolumes(m_result.TaskControl.ProgressToken) .Where(x => x.State == RemoteVolumeState.Verified) .GroupBy(x => x.Type) - .SelectAwait(async x => await x.LongCountAsync()) + .Select(x => x.LongCount()) .MaxAsync() .ConfigureAwait(false); diff --git a/Duplicati/Library/Main/Operation/FilelistProcessor.cs b/Duplicati/Library/Main/Operation/FilelistProcessor.cs index 5bf01708b..25e8fdfef 100644 --- a/Duplicati/Library/Main/Operation/FilelistProcessor.cs +++ b/Duplicati/Library/Main/Operation/FilelistProcessor.cs @@ -222,7 +222,7 @@ namespace Duplicati.Library.Main.Operation s.Serialize(stream, db.GetRemoteVolumes(cancellationToken) .Where(x => x.State != RemoteVolumeState.Temporary) - .ToEnumerable() + .ToBlockingEnumerable() .Cast() .ToArray() ); diff --git a/Duplicati/Library/Main/Operation/ListChangesHandler.cs b/Duplicati/Library/Main/Operation/ListChangesHandler.cs index 71bfe0fd2..4853afeee 100644 --- a/Duplicati/Library/Main/Operation/ListChangesHandler.cs +++ b/Duplicati/Library/Main/Operation/ListChangesHandler.cs @@ -188,7 +188,7 @@ namespace Duplicati.Library.Main.Operation ); if (callback != null) - callback(m_result, lst.ToEnumerable()); + callback(m_result, lst.ToBlockingEnumerable()); return; } diff --git a/Duplicati/Library/Main/Operation/ListFolderHandler.cs b/Duplicati/Library/Main/Operation/ListFolderHandler.cs index 0305812f2..cffd2e957 100644 --- a/Duplicati/Library/Main/Operation/ListFolderHandler.cs +++ b/Duplicati/Library/Main/Operation/ListFolderHandler.cs @@ -73,7 +73,7 @@ internal static class ListFolderHandler { result.Entries = await db .ListFolder( - db.GetPrefixIds(folders, result.TaskControl.ProgressToken).ToEnumerable(), + db.GetPrefixIds(folders, result.TaskControl.ProgressToken).ToBlockingEnumerable(), filesetIds[0], offset, limit, diff --git a/Executables/Duplicati.Agent/Duplicati.Agent.csproj b/Executables/Duplicati.Agent/Duplicati.Agent.csproj index 429305005..093fa0fce 100644 --- a/Executables/Duplicati.Agent/Duplicati.Agent.csproj +++ b/Executables/Duplicati.Agent/Duplicati.Agent.csproj @@ -5,12 +5,12 @@ net10.0 The Duplicati Agent implementation Copyright © 2025 Team Duplicati, MIT license - ..\..\..\Duplicati\GUI\Duplicati.GUI.TrayIcon\Duplicati.ico + ..\..\Duplicati\GUI\Duplicati.GUI.TrayIcon\Duplicati.ico - - + + diff --git a/Executables/Duplicati.CommandLine.AutoUpdater/Duplicati.CommandLine.AutoUpdater.csproj b/Executables/Duplicati.CommandLine.AutoUpdater/Duplicati.CommandLine.AutoUpdater.csproj index 7756b8591..ce4a265df 100644 --- a/Executables/Duplicati.CommandLine.AutoUpdater/Duplicati.CommandLine.AutoUpdater.csproj +++ b/Executables/Duplicati.CommandLine.AutoUpdater/Duplicati.CommandLine.AutoUpdater.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.BackendTester/Duplicati.CommandLine.BackendTester.csproj b/Executables/Duplicati.CommandLine.BackendTester/Duplicati.CommandLine.BackendTester.csproj index 2889b44c1..8107ad6ce 100644 --- a/Executables/Duplicati.CommandLine.BackendTester/Duplicati.CommandLine.BackendTester.csproj +++ b/Executables/Duplicati.CommandLine.BackendTester/Duplicati.CommandLine.BackendTester.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.BackendTool/Duplicati.CommandLine.BackendTool.csproj b/Executables/Duplicati.CommandLine.BackendTool/Duplicati.CommandLine.BackendTool.csproj index fb1e1921f..1c1386723 100644 --- a/Executables/Duplicati.CommandLine.BackendTool/Duplicati.CommandLine.BackendTool.csproj +++ b/Executables/Duplicati.CommandLine.BackendTool/Duplicati.CommandLine.BackendTool.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.DatabaseTool/Duplicati.CommandLine.DatabaseTool.csproj b/Executables/Duplicati.CommandLine.DatabaseTool/Duplicati.CommandLine.DatabaseTool.csproj index 76e74c3bc..04130fb14 100644 --- a/Executables/Duplicati.CommandLine.DatabaseTool/Duplicati.CommandLine.DatabaseTool.csproj +++ b/Executables/Duplicati.CommandLine.DatabaseTool/Duplicati.CommandLine.DatabaseTool.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.RecoveryTool/Duplicati.CommandLine.RecoveryTool.csproj b/Executables/Duplicati.CommandLine.RecoveryTool/Duplicati.CommandLine.RecoveryTool.csproj index 60948f0ab..888a4a766 100644 --- a/Executables/Duplicati.CommandLine.RecoveryTool/Duplicati.CommandLine.RecoveryTool.csproj +++ b/Executables/Duplicati.CommandLine.RecoveryTool/Duplicati.CommandLine.RecoveryTool.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.SecretTool/Duplicati.CommandLine.SecretTool.csproj b/Executables/Duplicati.CommandLine.SecretTool/Duplicati.CommandLine.SecretTool.csproj index 75a3db8ac..cd769cec1 100644 --- a/Executables/Duplicati.CommandLine.SecretTool/Duplicati.CommandLine.SecretTool.csproj +++ b/Executables/Duplicati.CommandLine.SecretTool/Duplicati.CommandLine.SecretTool.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.ServerUtil/Duplicati.CommandLine.ServerUtil.csproj b/Executables/Duplicati.CommandLine.ServerUtil/Duplicati.CommandLine.ServerUtil.csproj index a3780ca27..cdfabfb75 100644 --- a/Executables/Duplicati.CommandLine.ServerUtil/Duplicati.CommandLine.ServerUtil.csproj +++ b/Executables/Duplicati.CommandLine.ServerUtil/Duplicati.CommandLine.ServerUtil.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.SharpAESCrypt/Duplicati.CommandLine.SharpAESCrypt.csproj b/Executables/Duplicati.CommandLine.SharpAESCrypt/Duplicati.CommandLine.SharpAESCrypt.csproj index 71b984867..5e0935495 100644 --- a/Executables/Duplicati.CommandLine.SharpAESCrypt/Duplicati.CommandLine.SharpAESCrypt.csproj +++ b/Executables/Duplicati.CommandLine.SharpAESCrypt/Duplicati.CommandLine.SharpAESCrypt.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.Snapshots/Duplicati.CommandLine.Snapshots.csproj b/Executables/Duplicati.CommandLine.Snapshots/Duplicati.CommandLine.Snapshots.csproj index 52d8dc277..c193a2acb 100644 --- a/Executables/Duplicati.CommandLine.Snapshots/Duplicati.CommandLine.Snapshots.csproj +++ b/Executables/Duplicati.CommandLine.Snapshots/Duplicati.CommandLine.Snapshots.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.SourceTool/Duplicati.CommandLine.SourceTool.csproj b/Executables/Duplicati.CommandLine.SourceTool/Duplicati.CommandLine.SourceTool.csproj index 6dcfc5736..86b363cc7 100644 --- a/Executables/Duplicati.CommandLine.SourceTool/Duplicati.CommandLine.SourceTool.csproj +++ b/Executables/Duplicati.CommandLine.SourceTool/Duplicati.CommandLine.SourceTool.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine.SyncTool/Duplicati.CommandLine.SyncTool.csproj b/Executables/Duplicati.CommandLine.SyncTool/Duplicati.CommandLine.SyncTool.csproj index 9e396b7c2..e39007305 100644 --- a/Executables/Duplicati.CommandLine.SyncTool/Duplicati.CommandLine.SyncTool.csproj +++ b/Executables/Duplicati.CommandLine.SyncTool/Duplicati.CommandLine.SyncTool.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.CommandLine/Duplicati.CommandLine.csproj b/Executables/Duplicati.CommandLine/Duplicati.CommandLine.csproj index c36259837..34391dde0 100644 --- a/Executables/Duplicati.CommandLine/Duplicati.CommandLine.csproj +++ b/Executables/Duplicati.CommandLine/Duplicati.CommandLine.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.GUI.TrayIcon/Duplicati.GUI.TrayIcon.csproj b/Executables/Duplicati.GUI.TrayIcon/Duplicati.GUI.TrayIcon.csproj index 2452a1b06..7d2f3a92b 100644 --- a/Executables/Duplicati.GUI.TrayIcon/Duplicati.GUI.TrayIcon.csproj +++ b/Executables/Duplicati.GUI.TrayIcon/Duplicati.GUI.TrayIcon.csproj @@ -4,7 +4,7 @@ WinExe net10.0 The Duplicati Tray implementation - ..\..\..\Duplicati\GUI\Duplicati.GUI.TrayIcon\Duplicati.ico + ..\..\Duplicati\GUI\Duplicati.GUI.TrayIcon\Duplicati.ico Copyright © 2025 Team Duplicati, MIT license @@ -23,15 +23,15 @@ - <_WinMods Include="..\..\..\Duplicati\Library\WindowsModules\bin\$(Configuration)\net10.0-windows7.0\**\*.dll" /> + <_WinMods Include="..\..\Duplicati\Library\WindowsModules\bin\$(Configuration)\net10.0-windows7.0\**\*.dll" /> - - + + diff --git a/Executables/Duplicati.Server/Duplicati.Server.csproj b/Executables/Duplicati.Server/Duplicati.Server.csproj index af4db23a7..c0f3732e0 100644 --- a/Executables/Duplicati.Server/Duplicati.Server.csproj +++ b/Executables/Duplicati.Server/Duplicati.Server.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.Service/Duplicati.Service.csproj b/Executables/Duplicati.Service/Duplicati.Service.csproj index c772b8d8d..6298a40ac 100644 --- a/Executables/Duplicati.Service/Duplicati.Service.csproj +++ b/Executables/Duplicati.Service/Duplicati.Service.csproj @@ -8,8 +8,8 @@ - - + + diff --git a/Executables/Duplicati.WindowsModulesLoader/Duplicati.WindowsModulesLoader.csproj b/Executables/Duplicati.WindowsModulesLoader/Duplicati.WindowsModulesLoader.csproj index 1fa8feb21..d1f60debf 100644 --- a/Executables/Duplicati.WindowsModulesLoader/Duplicati.WindowsModulesLoader.csproj +++ b/Executables/Duplicati.WindowsModulesLoader/Duplicati.WindowsModulesLoader.csproj @@ -9,8 +9,8 @@ - - + + diff --git a/Executables/Duplicati.WindowsService/Duplicati.WindowsService.csproj b/Executables/Duplicati.WindowsService/Duplicati.WindowsService.csproj index 1947491ce..3c7c71761 100644 --- a/Executables/Duplicati.WindowsService/Duplicati.WindowsService.csproj +++ b/Executables/Duplicati.WindowsService/Duplicati.WindowsService.csproj @@ -9,8 +9,8 @@ - - + +