No helpful error message when `par2+` is forgotten
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Duplicity |
New
|
Undecided
|
Unassigned |
Bug Description
(I think this might be related to 1406173 but it seems different as it is old and marked as fixed)
When backing up with par2 turned on (eg a par2+ssh://... url), *.par2 files get created.
`I just wanted to restore from this and I forgot to add the `par2+` part (I used `file://...` instead of `par2+file://` and I got an AssertionError in `add_filename` (see log below)
I know this is my fault and everything, but if it's not much of a hassle it would be cool if duplicity could recognize this situation and display some meaningful warning (something like "Directory contains .par2 files. Did you mean to say par2+file:///...?")
/tmp/0N2AeR# duplicity restore file://
Using archive dir: /root/.
Using backup name: 28xxxxef
GPG binary is gpg, version 2.2.15
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Import of duplicity.
Main action: restore
Acquiring lockfile /root/.
=======
duplicity 0.7.18.2 (October 17, 2018)
Args: /usr/bin/duplicity restore file://
Linux dirk 5.0.13-arch1-1-ARCH #1 SMP PREEMPT Sun May 5 18:05:41 UTC 2019 x86_64
/usr/bin/python2 2.7.16 (default, Mar 11 2019, 18:59:25)
[GCC 8.2.1 20181127]
=======
Using temporary directory /tmp/duplicity-
Registering (mkstemp) temporary file /tmp/duplicity-
Temp has 5367005184 available, backup will use approx 272629760.
Local and Remote metadata are synchronized, no sync needed.
658 files exist on backend
31 files exist in cache
Extracting backup chains from list of files: [...
# >200 archives, for each one there's three files: .gpg, .gpg.par2, .gpg.vol000+
...
Traceback (innermost last):
File "/usr/bin/
with_
File "/usr/bin/
fn()
File "/usr/bin/
do_
File "/usr/bin/
action)
File "/usr/lib/
self.
File "/usr/lib/
add_to_sets(f)
File "/usr/lib/
if set.add_
File "/usr/lib/
(self.
AssertionError: ({..., 42: 'duplicity-