Space in path on Linux causes error message when restoring on Windows
Output of restic version
restic 0.19.1 compiled with go1.26.4 on windows/amd64 (Windows) restic 0.18.1 compiled with go1.25.0 on linux/amd64 (Linux)
What backend/service did you use to store the repository?
My VPS, running Ubuntu 26. So the backup and restore commands looked like: "restic -r sftp:my_name@my_vps.com:/path-to-repo backup ." "restic -r sftp:my_name@my_vps.com:/path-to-repo restore latest --target ."
Problem description / Steps to reproduce
I performed a "backup" command on Linux, to backup some files. One directory in the backup data accidentally had a space at the end of the directory name - e.g.
data/dir-a/aaa.txt
data/dir-b /bbb.txt <- note the space
data/dir-c/ccc.txtThe backup completed with no errors.
I then restored that snapshot on Windows. The backup reported errors: "Unable to set timestamp of file data\dir-b\bbb.txt - no such file or directory" All files were restored. The 'dir-b' did not have a space at the end (which I think Windows forbids anyway).
I went back to Linux, removed the space, and did a new backup snapshot. The new snapshot restored on Windows without errors.
Expected behavior
Not sure :) Maybe warn about spaces at the end of path components on Linux? Or a more meaningful error message on Windows.
Actual behavior
See above
Did restic help you today? Did it make you happy in any way?
Restic is awesome! Keep up the good work.
Source: restic/restic