Bare OSError if the trash is not found when trying to delete a file

Bug #1000398 reported by Guilherme Salgado
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu One Client
Confirmed
Undecided
Ubuntu One Client Engineering team

Bug Description

In order to do QA on staging we run a separate syncdaemon with the HOME env var set to something else, which works fine most of the cases, but fails when the SD gets notified about a file deletion -- it will just log a warning

  ubuntuone.SyncDaemon.fsm - WARNING - OSError when trying to remove file/dir '/tmp/u1test/Ubuntu One/bar'

and leave the file untouched. After digging a bit, it turns out this is because move_to_trash() will convert any GLib.GError raised by .trash() into a bare OSError with code=2 and no error message.

FWIW, the error raised by .trash() in this case is this: GError('Unable to find or create trash directory',)

Rick McBride (rmcbride)
Changed in ubuntuone-client:
assignee: nobody → Ubuntu One Desktop+ team (ubuntuone-desktop+)
status: New → Confirmed
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.