You might expect that implementing a VMM more or less requires use
of a systems language such as C or Rust. Interestingly, this turns
out not to be the case. In actuality, the KVM
API turns
out to be simple enough to use that it is entirely feasible to write
a VMM for Linux in Python.
I want to introduce the new (soft) keyword struct (the name was
chosen by my wife, Andrea, as more understandable than data once
you explain struct is short for structure and how it's used in
other programming languages). You would be able to follow the
keyword with the name of the struct class. The parentheses after the
name would contain the positional-or-keyword and/or keyword-only
parameters the constructor would accept. Each parameter name would
directly map to an attribute name for which the parameter would be
saved to. Because of this mapping of parameter name to attribute
name, no positional-only parameters are allowed (the only
deviation from function declearation syntax).
This PEP specifies an improved syntax for specifying type parameters
within a generic class, function, or type alias. It also introduces
a new statement for declaring type aliases.
At the beginning of the evening I finished Lords of
Uncreation,
The Final Architecture Book 3 by Adrian Tchaikovsky. An action packed
page turner and a good conclusion to the Final Architecture trilogy.
After moving his family back to his hometown to be with his friends
and their kids, Lenny finds out that between old bullies, new
bullies, schizo bus drivers, drunk cops on skis, and four hundred
costumed party crashers sometimes crazy follows you.
In the evening Esme and I watched Grown Ups
2. I liked the movie less than
the previous one so I give it a 6 out of 10.
THE HUNT IS ON AND THE POLICE ARE RUNNING OUT OF TIME. Two young
women are missing, their only connection a party they both attended,
hosted by a notorious real-estate magnate. When one of the women is
found murdered, the police discover an unusual signature left by the
killer, giving them reason to suspect he will strike again.
THEY'RE FACING A KILLER UNLIKE ANY OTHER. And exposing him calls for
a detective like no other. But the legendary Harry Hole is
gone—fired from the force, drinking himself to oblivion in Los
Angeles. It seems that nothing can entice him back to Oslo. Until
the woman who saved Harry's life is put in grave danger, and he has
no choice but to return to the city that haunts him and track down
the murderer.
CATCHING HIM WILL PUSH HARRY TO THE LIMIT. He'll need to bring
together a misfit team of former operatives to accomplish what he
can't do alone: stop an unstoppable killer. But as the evidence
mounts, it becomes clear that there is more to this case than meets
the eye...
In the evening I started in Killing
Moon,
a Harry Hole Novel (13) by Jo Nesbø.
NixOS is a Linux distribution configured using
Nix. It is
declarative, meaning that the entire system state can be defined in
a single .nix file; and reproducible, meaning you can have
multiple computers set up identically.
Once you ship your software, most of your end users will be better
served by replacing the stack trace with some actionable error
message in case of a crash.
Choosing good test cases for our Go programs can be a bit
hit-and-miss. Sometimes we get lucky and find an input that causes
incorrect behaviour, or even a crash, but in general, picking inputs
at random isn’t a good way to find bugs.
Or is it? What if we leaned into that idea a little and used a lot
of different inputs? Say, a million, or even a billion. With that
many inputs, our chances of finding the one weird value that
triggers a problem start to look pretty good.
The Rust team is happy to announce a new version of Rust,
1.70.0. Rust is a programming language empowering everyone to build
reliable and efficient software.
I was watching this amazing lightning
talk by Karla
Burnett and wanted to understand how
traceroute works in UNIX. Traceroute is a tool that shows the
route of a network packet from your computer to another computer on
the internet. It also tells you how long it takes for the packet to
reach each stop along the way.
Hey everyone, we are Ryan Lahfa
and Martin Weinelt, the release
managers for this stable release and we are very proud to announce
the public availability of NixOS 23.05 “Stoat”.
A lot of basic, important information about transformer language
models can be computed quite simply. Unfortunately, the equations
for this are not widely known in the NLP community. The purpose of
this document is to collect these equations along with related
knowledge about where they come from and why they matter.
Source: Transformer Math
101, an article by
Quentin Anthony, Stella Biderman, and Hailey Schoelkopf.
With more than 9 billion gigabytes of information traveling the
internet every day, researchers are constantly looking for new ways
to compress data into smaller packages. Cutting-edge techniques
focus on lossy approaches, which achieve compression by
intentionally “losing” information from a transmission. Google, for
instance, recently unveiled a lossy strategy where the sending
computer drops details from an image and the receiving computer uses
artificial intelligence to guess the missing parts. Even Netflix
uses a lossy approach, downgrading video quality whenever the
company detects that a user is watching on a low-resolution device.
Very little research, by contrast, is currently being pursued on
lossless strategies, where transmissions are made smaller, but no
substance is sacrificed. The reason? Lossless approaches are already
remarkably efficient. They power everything from the PNG image
standard to the ubiquitous software utility PKZip. And it’s all
because of a graduate student who was simply looking for a way out
of a tough final exam.
That gives me an idea: I can't change the hostname from a container
because of limited capabilities. But I could totally launch a new
process in the same namespace, and this new process would have no
capability limits—so it could change the hostname. And that change
would be shared with the container! Let's try it!
What I’ve since realized is that JavaScript reuses its full-power
Objects for many non-OO purposes, most of which are much
simpler. I’ve used JS objects for roughly 4 things:
You may have heard there are new, modern standards in Python
packaging (pyproject.toml!) that have been adopted over the last
few years. There are now several popular and shiny modern tools for
managing your packaging projects. (Poetry! Hatch! PDM!) However, the
documentation is scattered and much of it is specific to these
competing tools. What are the recommended best practices when
creating a Python package? What is the minimal amount that you
need to do in order to follow the best practices?
The tragic and controversial story of Cameron Todd Willingham, who
was sentenced to death in Texas for killing his three children even
after scientific evidence and expert testimony bolstered his claims
of innocence.
In the evening I watched Trial by
Fire. I liked the movie and
give it a 7 out of 10.
Overall, there was agreement that the original motivations for a
large, “batteries-included” standard library no longer held up to
scrutiny. “In the good old days,” Ned Deily reminisced, “We said
‘batteries-included’ because we didn’t have a good story for
third-party installation.” But in 2023, installing third-party
packages from PyPI is much easier.
This blog post is about benchmarking Caddy against Nginx and their
respective performance metrics as reverse proxies. Be forewarned: I
was very thorough and there are tons of graphs and tables in here. I
didn’t want to make any mistakes! Nobody is allowed to make mistakes
on the Internet.
In this blog post, I will guide you through the steps of adding
security headers using Cloudflare, making the process much simpler
and hassle-free, without even touching a single line of code on your
web server.
What I've come to realize, though, is that anyone can write code
that seems complicated. The hard thing is solving complex problems
with simple code. If you can develop that skill, nobody will ever
doubt your abilities.
Media queries are a CSS language feature which allow an author to
conditionally apply CSS rules according to characteristics of the
device or window in which an application is being viewed. Most
commonly, these might be according to the viewport width allowing
CSS authors to create components and layouts that are responsive
to the size of the window or device that they are being viewed
in. But this may also extend to whether a user prefers light or dark
mode, or even a user's accessibility preferences, plus many more
properties.
Over the years, I've observed modern password hashing algorithms
significantly reduce the effectiveness of brute-force password
guessing. However, password stuffing attacks—where attackers use
previously leaked credentials to gain unauthorized access—continue
to be a persistent threat. On the other hand, the advent of
multi-factor authentication (MFA) has shifted the focus to
protecting user accounts through additional layers of verification,
making passwords less critical to security.