[pbs-devel] [PATCH proxmox-backup] fix #6624: ui: improve task log output for protected entry

Shan Shaji s.shaji at proxmox.com
Fri Aug 22 18:45:48 CEST 2025


Using 'Prune All' with 'Dry Run' gives incomplete task-log
output for a 'protected' entry. To fix this, add an additional
check to return the string 'would keep', since a protected
entry is always kept.

Signed-off-by: Shan Shaji <s.shaji at proxmox.com>
---
 src/server/prune_job.rs | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/src/server/prune_job.rs b/src/server/prune_job.rs
index 1c86647a..6108d32d 100644
--- a/src/server/prune_job.rs
+++ b/src/server/prune_job.rs
@@ -69,7 +69,15 @@ pub fn prune_datastore(
             let keep = keep_all || mark.keep();
             info!(
                 "{}{mark} {}/{}/{}",
-                if dry_run { "would " } else { "" },
+                if dry_run {
+                    if mark.protected() {
+                        "would keep "
+                    } else {
+                        "would "
+                    }
+                } else {
+                    ""
+                },
                 group.backup_type(),
                 group.backup_id(),
                 info.backup_dir.backup_time_string()
-- 
2.47.2





More information about the pbs-devel mailing list