Comment 1 for bug 340277

Revision history for this message
Andrea Francia (andrea-francia) wrote :

The trash-cli version shipped with ubuntu is quite old.
In the current upstream version it doesn't crash but simply print an error:

    $ trash-put --version
    trash-put 0.2.1
    $ sudo mount test-volume.img ./test-volume -o loop
    $ sudo mkdir ./test-volume/.Trash-1000/
    $ sudo chmod a-r ./test-volume/.Trash-1000/
    $ trash-put ./test-volume/foo
    trash: cannot trash `./test-volume/foo': [Errno 13] Permission denied: '/home/andrea/Desktop/bug-ubuntu-340277/test-volume/.Trash-1000/info'

I'm hope that the new version could be early packaged in Ubuntu, in the meantime you can install the upstream version with these commands:

   sudo apt-get install python-setuptools
   sudo easy_install trash-cli

As far I know the trashcan spec does NOT says that "the home trash directory SHALL be used as fallback" but they say that it COULD be used and the choice is up to the implementation. I personally thinks that using it a fallback is not a good idea, but if many users want this I could add this features. If you want this feature fill a bug in http://code.google.com/p/trash-cli/issues page.