this could crash in two cases:
- if a directory is deleted between restic stating it and trying to list
its directory content.
- when restic tries to list the parent directory of a backup target, but
the parent directory has been deleted.
return an error in this case instead.