[Python-ideas] Adding `pathlib.Path` method that would send file to recycle bin

Nick Coghlan ncoghlan at gmail.com
Sun Jan 4 21:25:01 CET 2015

On 5 Jan 2015 05:25, <random832 at fastmail.us> wrote:
> On Fri, Jan 2, 2015, at 20:50, Steven D'Aprano wrote:

> > You have a choice of desktop
> > environments, which may or may not provide a move-to-trash API,
> > including no desktop environment at all. Gnome provides an API for
> > moving to trash, but I don't know how well it supports the freedesktop
> > standard; KDE supports the freedesktop standard, but I don't know if it
> > provides an API that can be called. XFCE has partial support.
> I don't see why you need to call an API to the desktop enviroment. The
> entire point of the spec is to provide compatibility _between_
> implementations on the same filesystem - you can quit gnome and log into
> KDE and see the same trash.

That compatibility is implemented *by* the desktop environments. Yes, you
could write your own, but why would you, when the whole point of providing
a standard API would be to integrate more cleanly with the underlying OS.

> Python would just be a separate
> implementation that stands by itself.

The word "just" does not belong in that sentence. Reliable cross-platform
development & testing for operations that are tightly coupled to operating
system services is hard, period - the associated test matrix of platforms
and permission levels ensures that.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20150105/10de07ae/attachment.html>

More information about the Python-ideas mailing list