#1049972 rdiff-backup: "remove increments older than" exits with error when there are no increments to remove

Package:
rdiff-backup
Source:
rdiff-backup
Description:
remote incremental backup
Submitter:
Santiago Vila
Date:
2023-08-17 17:33:03 UTC
Severity:
normal
Tags:
#1049972#5
Date:
2023-08-17 17:29:17 UTC
From:
To:
Dear maintainer:

As the subject says, when I try something like this:

rdiff-backup remove increments --older-than 1m /some/destination

the command exits with status 2 (indicating error), when it's the
case that there are no increments to remove.

This is a regression, as it did not use to happen in Debian 11,
where an equivalent command

rdiff-backup --remove-older-than 1m

never seemed to fail when there are no increments to remove.


Intuitively, in the spirit of "rm -f", one might think that using --force would help:

rdiff-backup --force remove increments --older-than 1m /some/destination

but that does not seem to be the case either.

Note: I'm not using any special severity here, but I would consider this worthy to be
fixed in a point release, as it breaks current scripts (I mean, even if the syntax
has changed, one would expect that an "equivalent" script using the new syntax
would behave the same as the old one). Maybe it does not worth an upload by itself,
but if this bug is going to be fixed in some point release:

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1035725

then maybe this one could be fixed as well in the same upload (of course, if it's
confirmed that it's a bug and a fix is available).

Thanks.