week 22, 2021

Puck the cat

In the afternoon we went to the birthday party of my sister-in-law. Her daughter has a nice black-and-white cat called Puck. I took a few photos of Puck and picked the one below for this blog.

Puck the cat resting
Puck the cat resting.

She has grown a lot; compare with photos I took the 12th of July 2020.

The right tag for the job: why you should use semantic HTML

I’ve come across a lot of websites in my career (and in daily browsing) that are straight-up inaccessible. If you’ve ever worked on a project that is riddled with accessibility issues, you’ll know that fixing these problems is a mammoth task - it needs time, it needs people, it needs prioritisation… it costs money, basically. As I mentioned in my blog post 7 myths designers and developers believe about web accessibility, retrofitting accessibility is hard.

The key is to start out with the right tools for the job - or rather, the right tags for the job. In every website, underneath the layers of CSS, the bloated frameworks, the 45945 API calls, there’s good old HTML, and that’s the key to accessible websites. Specifically, semantic HTML.

Source: The right tag for the job: why you should use semantic HTML, an article by Sophie Koonin.

FreeBSD from a NetBSD user’s perspective

I’ve been a NetBSD developer for three years and it’s been my primary operating system for a long time too - on everything: routers, laptops, Raspberry Pis, PowerPC mac minis, Vortex86 embedded boards, and servers.

I’ve recently been using FreeBSD a lot at work. We have a lot of servers and embedded boards running it, and I was given the option of installing anything I wanted on my workstation. I chose FreeBSD to maintain a separation of BSDs between my work and home life ;)

I thought I’d write a little bit about some differences that stand out to me. Since everyone that knows me well knows that typical use cases like web hosting aren’t really my jam, and I’m more of an embedded, audio, and graphics person, maybe I can offer a more uncommon perspective.

Source: FreeBSD from a NetBSD user’s perspective.

Don't fall in love with your Mac—automate it!

Once you turn on the new Mac, what's next? Do you:

  1. Wait 6+ hours for a Time Machine restore (you do have a backup, right?) or use Migration Assistant to move all your old files and cruft from your old Mac?
  2. Manually install apps and click through tons of preference panes to set it up to your liking?
  3. Use a completely automated process like mac-dev-playbook to build everything fresh using mas, homebrew, and a tool like Ansible, so it's in a pristine state, with all your data and apps configured within an hour or two?

I choose the latter. And as a bonus, I can run the automation on both my new Macs frequently, to keep their configuration and app layout in sync!

Source: Don't fall in love with your Mac—automate it!, an article by Jeff Geerling.

Nice nginx features for developers

A lot of people use nginx as a web server and fallback for something like haproxy or traefik for service routing. But you can use nginx for that too! In my experience nginx provides rich and flexible ways to route your requests. Here are few things that worked well for me when I was wearing a developer hat.

Source: Nice nginx features for developers, an article by Alex Dzyoba.

Go Fuzzing is Beta Ready

We are excited to announce that native fuzzing is ready for beta testing in its development branch, dev.fuzz!

Fuzzing is a type of automated testing which continuously manipulates inputs to a program to find issues such as panics or bugs. These semi-random data mutations can discover new code coverage that existing unit tests may miss, and uncover edge case bugs which would otherwise go unnoticed. Since fuzzing can reach these edge cases, fuzz testing is particularly valuable for finding security exploits and vulnerabilities.

Source: Fuzzing is Beta Ready, an article by Katie Hockman and Jay Conrod.

HTML and CSS techniques to reduce your JavaScript

More and more websites are relying on JavaScript for the interactions they provide. It enables pleasant experiences but also comes with undesirable effects:

  • Longer page load times
  • Page is unusable until the JavaScript loads and if it does so without any errors
  • Usability, reactivity and accessibility can be lacking without a team with the means and resources to pay attention to those.

Given these drawbacks, relying on solutions provided natively by browsers enables you to benefit at low cost from the expertise of the community creating web standards. These solutions generally have the advantage of using less code, thus reducing maintenance efforts for a development team (for example, no need to update the libraries used).

In this article, we will explore some of these native solutions that are available to the majority of your users. We will see some examples but we won’t go into all the subtleties, because other resources do so very well. Rather, the goal is to inform you of the existence of these techniques.

Source: HTML and CSS techniques to reduce your JavaScript, an article by Anthony Ricaud.

The 17 Ways to Run Containers on AWS

As I mentioned on Twitter last week, there are 17 ways to run containers on AWS. While I pulled the number “17” out of the air, I have it on good faith that this caused something of a “meme explosion” inside of AWS. To that end, I can do no less but to enumerate the 17 container options, along with (and this is where I deviate from AWS itself) providing guidance and commentary as to which you should choose for a given task.

Source: The 17 Ways to Run Containers on AWS, an article by Corey Quinn.

Conditional HTTP GET: The fastest requests need no response body

Every browser implements its own in-memory caching. The information about the cache size per browser is spotty, but there’s one thing for sure: the cache sizes vary. The great thing is that browsers are smart nowadays – they manage their caches opaquely for us, the end-users.

There are a few ways to put these caches to use. But it all starts with HTTP caching directives (or headers). The two HTTP response headers used for specifying freshness (another word for should something be cached) are Cache-Control and Expires.

Source: Conditional HTTP GET: The fastest requests need no response body, an article by Ilija Eftimov.

Raspberry Silicon update: RP2040 on sale now at $1

Back in January, we launched Raspberry Pi Pico. This was a new kind of product for us: our first microcontroller-class board, and the first to be built on RP2040, a chip designed here at Raspberry Pi. At the same time, we announced RP2040-based products from our friends at Adafruit, Arduino, Sparkfun, and Pimoroni.

Today, we’re announcing the logical next step: RP2040 chips are now available from our Approved Reseller partners in single-unit quantities, allowing you to build your own projects and products on Raspberry Silicon.

Source: Raspberry Silicon update: RP2040 on sale now at $1 - Raspberry Pi, an article by Eben Upton.

Swift Concurrency

Swift is about to get its Concurrency features. Their development is going very well, with many proposals actively reviewed and a lot of the work already available in recent snapshots. The story is big and with many moving pieces interlinked with each other. That makes it a bit hard to wrap your head around the entire thing. Specially for those that don't read Swift Evolution as a hobby ^^.

Source: Swift Concurrency, an article by Alejandro Martinez.