Weeknotes for the week finishing Friday, 10th April 2026.

This week, I:

  • Fixed a bug in production. The SSL certificate didn’t automatically renew. It expired, leaving a Cloudflare “Invalid SSL certificate” message in place of OpenPrescribing v2 for about 40 minutes early this morning.
  • Started work on a new feature: the ability to query by form/route and ingredient in OpenPrescribing v2’s backend. (Peter added the ability to fetch/ingest dm+d data and to fetch/ingest a mapping from dm+d codes to BNF codes.) I didn’t finish work on it this week, because of the bug in production.
  • Finished reading Simon Willison’s guide to Agentic Engineering Patterns.

Another bug in production

I fixed a bug in production last week, too. I’m not concerned that they exist or that they caused long outages; not today, anyway. OpenPrescribing v2 is still beta, signalled by the subdomain and the banner at the top of the page.1 It takes time to fit together two reverse proxys (Cloudflare, Nginx), SSL certificates (Let’s Encrypt), a web server (Gunicorn), and a web application (Django). Sometimes, a long time: it’s likely that today’s bug was caused by a change I made nearly two months ago in response to an issue with OpenPrescribing v1.

More than last week, this week I leaned heavily on ChatGPT. I asked it to suggest reasons for the error, based on the message and code. I asked it about Dokku and the Let’s Encrypt plugin, because it wasn’t clear to me whether the error originated at the system-level or the app-level. And when the fix we — yes, ChatGPT and me — agreed on didn’t work, I asked it about Cloudflare’s reverse proxy. At this point, however, I ignored its suggestions to disable Cloudflare’s reverse proxy and to use DNS-01 rather than HTTP-01, and instead added a Cloudflare security rule.

Time’s up!


  1. Respectively, https://beta.openprescribing.net/ and “This is a beta version of a new OpenPrescribing”.