Python

Test that forking code!

18 minute read

Not only should the final commit in a pull request patch series pass all its tests but also each commit back to where the pull request branched from main. A...

Basic Python project setup

6 minute read

Setting up an existing Python project from a fresh clone shouldn’t be a chore. Automate the process with a setup script.

Evaporating a pot of water

16 minute read

As part of tutoring physics and maths to high school students, I sometimes write up deep-dive explanations of questions arising during lessons. The question...

Reverting migrations in Django

4 minute read

When developing Django applications it’s sometimes necessary to revert (i.e. undo) a migration, especially if something didn’t quite work as planned. If som...

Test suite profiling

15 minute read

Recently at $work I found that our test suite was taking longer and longer to run and had begun to slow down development. A long-running test suite smells of...