Skip to content

Ensure proper error reporting #2

@we-taper

Description

@we-taper

When an error appeared when moving remote archives back to local archive, the error message was not explanatory, making debug difficult.

Example error:

[uwrapper] Reading file: /xxx/mac-backup2Synology.prf
[uwrapper] Found Root: Root(path='/xxx/', is_local=True, remote_name=None, remote_type=None)
[uwrapper] Found Root: Root(path='/xxx/MacMBPBackup/', is_local=False, remote_name='xxx', remote_type='Unix')
[uwrapper] Moved local archives back to "/xxx/archives_local".
Traceback (most recent call last):
  File "/xxx/bin/uwrapper", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/xxx/python3.11/site-packages/uwrapper.py", line 545, in main
    return restore(profile)
           ^^^^^^^^^^^^^^^^
  File "/xxx/lib/python3.11/site-packages/uwrapper.py", line 510, in restore
    profile.remote_ssh.copy_remote_archives_back(remote_archive)
  File "/xxx/.local/pipx/venvs/unison-wrapper/lib/python3.11/site-packages/uwrapper.py", line 196, in copy_remote_archives_back
    raise RuntimeError(
RuntimeError: Failed to copy back archives inside remote's "~/.unison". Check local folder /xxx/mac-backup2xxx/archives_remote and the remote "xxx224".

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions