Chosen links

Links - 2nd April 2023

Content negotiation considered harmful

  • Most web developers are not aware that conneg exists. This is usually fine, since it’s uncommon, but can be an unpleasant surprise when they first hit it and don’t understand it.

  • The Accept header is notoriously complicated to parse, generate, and fully comply with. Imo much of that complexity is unneeded in practice.

  • It often breaks caching when it’s first introduced. Internal and external caches generally ignore Content-Type and Accept (etc) by default, so when conneg is first introduced, clients often get the wrong response type. Developers learn the hard way that they need to add Accept to Vary and to their framework’s cache.

  • URLs leak across contexts. They may start out within a single service or API, but they gradually proliferate into user-visible links, object identifiers in other systems, add-on services, third party tools, etc. These generally don’t know the original conneg requirements, which causes unpleasant surprises.

Writing a C Compiler, Part 1

This is the first post in a series on writing your own C compiler. Here are some reasons to write a compiler:

  1. You’ll learn about abstract syntax trees (ASTs) and how programs can represent and manipulate other programs. Handy for working with linters, static analyzers, and metaprogramming of all sorts.

  2. You’ll learn about assembly, calling conventions, and all the gritty, low-level details of how computers, like, do stuff.

  3. It seems like an impossibly hard project (but isn’t!), so writing one will make you feel like a badass.

A response to Jacob Kaplan-Moss’s “Incompetent but nice”

What can managers do about employees who are easy to work with, and are trying their best, but can’t seem to get the job done?

Data feminism: 2. Collect, analyze, imagine, teach

Women faculty comprise less than a third of computer science and statistics faculty. More than 80 percent of artificial intelligence professors are men. This gender imbalance, and the narrowness of vision that results, is compounded by the fact that data science is often framed as an abstract and technical pursuit. Steps like cleaning and wrangling data are presented as solely technical conundrums; there is less discussion of the social context, ethics, values, or politics of data. This perpetuates the myth that data science about astrophysics is the same as data science about criminal justice is the same as data science about carbon emissions. This limits the transformative work that can be done. Finally, because the goal of learning data science is modeled as individual mastery of technical concepts and skills, communities are not engaged and conversations are restricted. Instead, teachers impart technical knowledge via lectures, and students complete assignments and quizzes individually. We might call this model of teaching “the Horace Mann Factory Model of Data Science”, because it represents the exclusionary view that Mann himself advanced. But let’s just call it the Man Factory for short.