miniblog.
← Back to all posts
Oct 31, 2013 at 18:29
Today I learnt about `with closing(opened_thing) as foo` in Python. Ensures cleanup in the face of errors.
28.7. contextlib — Utilities for with-statement contexts — Python 2.7.18 documentation
docs.python.org/2/library/contextlib.html#contextlib.closing
Wilfred Hughes
Related Posts
Apr 9, 2014 at 22:42
Emacs meetup was excellent! Put some faces to handles, learnt a number of things and was introduced to browse-kill-ring! #churchofemacs
Wilfred Hughes
Shared words: learnt, thing, face Score: 54.5
Jul 15, 2026 at 18:18
4
Today I learnt about yamllint: if you're using YAML, you can at least ensure you're not suffering from the 'Norway problem':
Rules — yamllint 1.38.0 documentation
yamllint.readthedocs.io/en/stable/rules.html#module-yamllint.rules.truthy
Wilfred Hughes
Shared words: learnt, Today, Ensures Score: 50.5
Jun 20, 2019 at 23:02
Today I learnt that Arch Linux has a paccache.timer built-in service. This service (you can enable it from systemctl) ensures your package cache doesn't grow excessively. Really handy, though I wonder why it isn't enabled by default.
Wilfred Hughes
Shared words: learnt, Today, Ensures Score: 50.5