Plurrrr

week 32, 2026

The Backslash Issue

In the early afternoon I fixed a bug in the create_page function of the Python version of tumblelog. If one used, for example, \1 in the blog title the program would stop with an PatternError exception stating "invalid group reference 1". The reason for this is that the sub method processes any backslash characters unless a function call is used. I explain this in more detail in Python re.sub gotcha.

Now, in the updated version, all substitutes are properly using a function call (lambda) instead of a string to prevent this issue from occuring. While it's unlikely someone uses, for example, \1 as an argument to --label-format and blowing up the archive, I decided to fix that substitution as well: better safe than sorry.

As usual the latest version is available on GitHub.

The Forward Slash Issue

Later, I also fixed a forward slash issue: if one forgets a trailing forward slash in the blog URL it's now autmatically added.

Some Other Fixes

Even later in the afternoon I learned that the Python module argpase supports positional arguments. So I removed the manual filename fetching. I also changed the parser call to parse_args instead of parse_known_args so tumblelog now warns if one has a typo in an option name.

I also made sure that an issue with the filename or the template filename printed a nice error message instead of a noisy stack trace.

Moreover, I now use a context object to pass around four common arguments. This reduces the number of parameters of several functions.

And just after I had pushed 6.5.3 to GitHub I discovered another issue in the Python version: if you create a site without a blog, just pages, the archive is still partially generated. So I fixed this bug and pushed 6.5.4 to GitHub.

The Last House (2026)

A family of four is suddenly sealed inside their house with no way out and must work together to survive against both their dwindling resources and the mysterious, looming threat that is keeping them trapped.

In the evening Jaiden, Alice, Esme, and I watched The Last House. The movie was OK and I rate it a 6 out of 10.

More tumblelog fixes

Last monday I bumped into a bug regarding how the archive of tumblelog is rendered if the blog only has a date of which the year and ISO year differ, for example 2018-12-31. No link was generated to the 2019 calendar page while the page itself was generated.

The next day, while checking a calendar page on my phone I noticed that the months didn't fit on the small screen.

And today I fixed both issues and did some more finetuning. Note that because I changed _tumblelog.scss you have to regenerate the style sheet for your site using sass.

The changelog for 6.5.0 is as follows:

  • Use grid and flex instead of float in .tl-archive (styles/_tumblelog.scss)
  • Make month in calendar view smaller on small screens (styles/_tumblelog.scss)
  • Fix bug regarding year not showing in Archive for e.g. 2025-12-31
  • Use assert instead of raising RuntimeError (tumblelog.py)
  • Format year correctly in create_year_pages (tumblelog.py)
  • Catch yaml.YAMLError instead of yaml.parser.ParserError (tumblelog.py)
  • Simplify create_archive to make every year count

As usual the latest version is available on GitHub.

And another tumblelog update

In the afternoon I pushed a small tumblelog update to GitHub. The changelog for version 6.3.0 is as follows:

  • Improve typing hints (tumblelog.py)
  • Use int for years in create_year_pages and create_tag_pages (tumblelog.py)
  • Check page names are unique and don't conflict with blog
  • Format year correctly (tumblelog.py)
  • Move setlocale to main (tumblelog.py)

I really like mypy to check type hints. Together with dataclasses, introduced in tumblelog version 6.2.0, it makes the code much cleaner.

And another one plus a bug

In the evening I finished a slightly larger tumblelog update. The changelog for version 6.4.0 is as follows:

  • Replace error function with raise (tumblelog.py)
  • Replace assert with raise RuntimeError (tumblelog.py)
  • Raise a RuntimeError if tags is None in create_tag_pages (tumblelog.py)
  • Remove cast of article.html to str (tumblelog.py)
  • Handle a TumblelogError exception end-user friendly (tumblelog.py)
  • Use longer variable names (tumblelog.py)
  • Use / instead of joinpath (tumblelog.py)
  • Replace Any with object (tumblelog.py)
  • Fix exception message (tumblelog.py)

I am really happy with what the Python version has become.

However, while testing the Perl version I noticed a subtle bug which I fixed:

  • Push to pages instead of days if state equals PAGE (tumblelog.pl)

After this fix and bumping the version of both to 6.4.1 I pushed to GitHub.