cleanup/sftp: "Couldn't delete file: Failure'" only logged on level 9

Bug #669225 reported by Daniel Hahler
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Duplicity
Fix Released
Medium
Unassigned

Bug Description

With verbosity 8 I am getting the following log entries:
sftp command: 'rm "duplicity-full.20101022T002340Z.vol1.difftar.gpg"'
sftp command: 'rm "duplicity-full.20101022T002340Z.vol2.difftar.gpg"'

Only using the max verbosity (9) the error shows up:
sftp command: 'rm "duplicity-full.20101022T002340Z.vol1.difftar.gpg"'
State = sftp, Before = 'rm "duplicity-full.20101022T002340Z.vol1.difftar.gpg"^M
Removing /moby/duplicity-full.20101022T002340Z.vol1.difftar.gpg^M
Couldn't delete file: Failure'

(note that there are extra ^M characters for messages of this level, too).

These errors should show up on every level, but apparently on the default log level of 4.

This is duplicity 0.6.10.

From a quick glance at the source in duplicity/backends/sshbackend.py it looks like there is nothing implemented to log error responses from sftp, and also child.exitstatus does not reflect the failure.

Related branches

Daniel Hahler (blueyed)
description: updated
Revision history for this message
Daniel Hahler (blueyed) wrote :

I am attaching a branch/patch meant to fix this, but have not tested it.

If you're unsure if this fix works, I can setup a test environment (i.e. fill up the backup space again and hope that it fails again when trying to remove files), or a mocked test could be used instead (which would return this result).

Changed in duplicity:
status: New → Fix Committed
importance: Undecided → Medium
milestone: none → 0.6.11
Changed in duplicity:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.