Merge lp://qastaging/~mterry/duplicity/giobackend-display-name-0.7 into lp://qastaging/~duplicity-team/duplicity/0.7-series

Proposed by Michael Terry
Status: Merged
Merge reported by: Kenneth Loafman
Merged at revision: not available
Proposed branch: lp://qastaging/~mterry/duplicity/giobackend-display-name-0.7
Merge into: lp://qastaging/~duplicity-team/duplicity/0.7-series
Diff against target: 37 lines (+13/-4)
1 file modified
duplicity/backends/giobackend.py (+13/-4)
To merge this branch: bzr merge lp://qastaging/~mterry/duplicity/giobackend-display-name-0.7
Reviewer Review Type Date Requested Status
duplicity-team Pending
Review via email: mp+328633@code.qastaging.launchpad.net

This proposal supersedes a proposal from 2017-08-05.

Description of the change

I was doing some testing on the google-drive: GIO backend (this is not the gdoc: duplicity backend, but rather using GNOME's abstraction layer to talk to Google through the giobackend code) and noticed some problems.

(A) Getting a list of files was broken because this backend chooses to use internal IDs for all its filename. Only the display_name() call gets the real user-set filename. Which, OK. We can use that instead. This will work for google-drive: as well as all other backends, since that is the user-set/user-visible name that we want to work with anyway.

(B) Getting files wasn't working because we had been passing NOFOLLOW_SYMLINKS. Apparently the google-drive: backend treats all internal files as symlinks to other internal files? Doesn't matter, we can avoid having to care about what a backup does in that regard by simply not passing that flag. It was a level of precaution that we don't really need. Normally, duplicity will always be dealing with real files. If it's trying to get a symlink, it's because the user manually created one. In which case, maybe we should follow it, since the user wants us to.

Together, these fixes let google-drive: work (and maybe other similarly bizarre GIO backends). I also tested on a couple other backends (SSH and local) and they worked fine still.

To post a comment you must log in.
Revision history for this message
Kenneth Loafman (kenneth-loafman) wrote :
Revision history for this message
Kenneth Loafman (kenneth-loafman) wrote :

I used the diff and patched just giobackend.py. Did not mean to mark rejected earlier.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches