[Python-ideas] Add appdirs module to stdlib

Philipp A. flying-sheep at web.de
Tue Sep 1 10:00:21 CEST 2015


When defining a place for config files, cache files, and so on, people
usually hack around in a OS-dependent, misinformed, and therefore wrong way.

Thanks to the tempfile API we at least don’t see people hardcoding /tmp/
too much.

There is a beautiful little module that does things right and is easy to
use: appdirs <https://pypi.python.org/pypi/appdirs>

TI think this is a *really* good candidate for the stdlib since this
functionality is useful for everything that needs a cache or config (so not
only GUI and CLI applications, but also scripts that download and cache
stuff from the internet for faster re-running)

probably we should build the API around pathlib, since i found myself not
touching os.path with a barge pole since pathlib exists.

i’ll write a PEP about this soon :)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20150901/fcc9aff6/attachment.html>


More information about the Python-ideas mailing list