week 32, 2021

HTTP/3 From A To Z: Core Concepts (Part 1)

After almost five years in development, the new HTTP/3 protocol is nearing its final form. Earlier iterations were already available as an experimental feature, but you can expect the availability and use of HTTP/3 proper to ramp up over in 2021. So what exactly is HTTP/3? Why was it needed so soon after HTTP/2? How can or should you use it? And especially, how does it improve web performance? Let’s find out.

Source: HTTP/3 From A To Z: Core Concepts (Part 1), an article by Robin Marx.

Best practices for writing code comments

While there are many resources to help programmers write better code—such as books and static analyzers—there are few for writing better comments. While it's easy to measure the quantity of comments in a program, it's hard to measure the quality, and the two are not necessarily correlated. A bad comment is worse than no comment at all. Here are some rules to help you achieve a happy medium.

Source: Best practices for writing code comments, an article by Ellen Spertus.

Python Mock Gotchas

Mock is a Python mocking and testing library. It has become a de facto standard and is now included in the Python standard library.

Lately I’ve had the chance to work on a fairly large code base built upon a service-oriented architecture. In order to test each service in isolation, we make extensive use of Mock to simulate services that the code under test depends on.

During this process, we noticed that each member our team seemed to be hitting the same pitfalls, which I’m going to present in this article in the hope that it might help other developers.

Source: Python Mock Gotchas, an article by Alex Marandon.

Double Homicide

For the first time ever, bestselling novelists Jonathan and Faye Kellermen team up to deliver the launch book in a thrilling new series of short crime novels. This book--printed as a reversible volume with two different covers--contains two stories featuring different detectives solving crimes in different cities.

In the evening I started in the first story of Double Homicide, written by Jonathan Kellerman.

How to Setup Monorepos with Git for JavaScript and TypeScript

When your app gets bigger, managing files within a project gets more complex. You may start to have modules shared between front-end and back-end projects. Often, you also need to manage different versions of those modules.

A monorepo is a way to structure your projects to manage that kind of complexity all in one place.

Source: How to Setup Monorepos with Git for JavaScript and TypeScript, an article by Hieu C Nguyen.

How Actors Work Internally in Swift

Actors is a feature that is part of Swift's Structured Concurrency, bringing a brand new format to write and deal with asynchronous code. Although what Swift brings is new to the language, it's not new to tech itself. Many languages supported actors and async/await before Swift, but one interesting thing is that they are all implemented similarly. By having these features now in Swift, there's much we can learn from what developers experienced by using them in other languages.

Source: How Actors Work Internally in Swift, an article by Bruno Rocha.

Breaking the web forward

Safari is holding back the web. It is the new IE, after all. In contrast, Chrome is pushing the web forward so hard that it’s starting to break. Meanwhile web developers do nothing except moan and complain. The only thing left to do is to pick our poison.

Source: Breaking the web forward, an article by Peter-Paul Koch.

A fast port scanner in 100 lines of Rust

To write a fast port scanner, a programming language requires:

  • A Good I/O model, not to eat all the resources of the system.
  • High-level abstractions and a good packaging system to isolate low-level code and reuse it easily.
  • To be type and memory safe, because who wants offensive tools with vulnerabilities?
  • And, ideally, to be compiled, because most of the time, it’s worth trading a little bit of compile time for extreme runtime speed.

Guess what? These are precisely Rust’s selling points. So let see how to build a high-speed port scanner in 100 lines of Rust.

Source: A fast port scanner in 100 lines of Rust, an article by Sylvain Kerkour.

Bloom Filters - Much, much more than a space efficient hashmap!

A bloom filter is one of those data structures you are probably already aware of, or have at least heard about. For those looking for a simple recap, they are a probabilistic data structure which can be used to determine if something is in a set or not, giving a slight chance of returning a false positive result for some checks but while using less space than a full hashmap.

What you may not know is that while you can use them as a space efficient hash/dictionary there are other use cases you might not be aware of.

Source: Bloom Filters - Much, much more than a space efficient hashmap!, an article by Ben E. C. Boyter.

A brief intro to MTL

Recently a blog post came out which I quite like, it describes how to use the concrete base transformers. It’s very thorough and gives a concrete example for using transformers. Although it looks quite low level and I think you’ll get more out of transformers by using full MTL.

Source: A brief intro to MTL.

We are pleased to announce a new, major privacy enhancement to Firefox’s cookie handling that lets you fully erase your browser history for any website. Today’s new version of Firefox Strict Mode lets you easily delete all cookies and supercookies that were stored on your computer by a website or by any trackers embedded in it.

Source: Firefox 91 Introduces Enhanced Cookie Clearing, an article by Paul Zühlcke, Johann Hofmann, and Arthur Edelstein.

Neither Star nor Planet: A Strange Brown Dwarf Puzzles Astronomers

Astronomers now think Caselden found a brown dwarf — a failed star that lacks the necessary bulk to begin nuclear fusion in its core. “It forms like a star,” said Sarah Casewell, an astronomer at the University of Leicester in the U.K. “However, it never gains enough mass to fuse hydrogen into helium and start burning anything.”

Source: Neither Star nor Planet: A Strange Brown Dwarf Puzzles Astronomers, an article by Jonathan O'Callaghan.

The World of CSS Transforms

Like so many things in CSS, the transform property is surprisingly remarkable.

At first glance, it may seem like a pretty niche thing. How often do we need to rotate or skew something, after all? And yet, the more I learn about transform, the more I find myself taking advantage of it. In my blog's codebase, I've used the transform property more than 350 times!

In this blog post, we're diving deep into the transform property. I'll show you some of the cool and unexpected things you can do with it!

Source: CSS Transforms tutorial, an article by Joshua Comeau.

Is it Time to Ditch the Design Grid?

I came across this website, Gridless Design recently, and it immediately struck a chord. It’s something I’ve been thinking about for a long time — the way that the usual design process, where designers hand off static mockups based, so often, on a 12-column grid, is not fit for purpose. I know I’m far from the first person to think that way, but increasingly with the advancements in CSS layout in recent years, the design grid feels more like a hangover from print than ever. A solution to a problem that, on the web, we simply don’t have.

Source: Is it Time to Ditch the Design Grid?, an article by Michelle Barker.