Go generics have a new "type sets" way of doing type constraints
Any form of generics needs some way to constrain what types can beused with your generic functions (or generic types with methods),so that you can do useful things with them. The Go team's initialversion of their generics proposal famously had a complicated methodfor this called "contracts", which looked like function bodies withsome expressions in them. I (and other people) thought that thiswas rather too clever . After a lot offeedback, the Go team's revised second and third proposal
It's probably not the hardware, a sysadmin lesson
We just deployed a new OpenBSD 6.9 machine the other day, and afterit was deployed we discovered that it seemed to have serious problemswith keeping time properly. The OpenBSD NTP daemon would periodicallydeclare that the clock was unsynchronized, when it was adjustingthe clock it was frequently adjusting it by what seemed to be verylarge amounts (by NTP standards), reporting numbers like '-0.244090s',and most seriously every so often the time would wind up completelyoff
Why we care about being able to (efficiently) reproduce machines
One of the broad meta-goals of system administration over the past fewdecades has been working to be able to reliably reproduce machines,ideally efficiently. It wasn't always this way (why is outside the scopeof this entry), but conditions have changed enough so that this became aconcern for increasingly many people. As a result, it's a somewhat quietdriver of any number of things in modern (Unix) system administration.
There are a number of reasons why you would want to reproduce a
What the 'proto' field is about in Linux 'ip route' output (and input)
Today I was looking at the output of ' ip route list ' on one ofour Ubuntu 18.04 machines and noticed that a few of them lookeddifferent from the others:
10.99.0.0/16 via y.y.y.y dev eno1
172.16.0.0/16 via q.q.q.q dev eno1
172.99.99.0/26 via z
Microsoft's Bingbot crawler is relentless for changing pages (it seems)
I look at the web logs for Wandering Thoughts every sooften. There are many variations from day to day but regardlessof what other things change, one thing is as predictable as the sunrising in the morning; every day some MSN Search IP address willbe the top single source of traffic, as Bingbot crawls through here.This isn't at all new, as I wrote about Bingbot being out ofcontrol back in 2018, but it's somewherebetween impressive and depressing just how long
One major obstacle to unifying the two types of package managers
One common reaction on lobste.rs to my entry on how there are two types of package managers was to hope that the two types are unifiedsomehow, or that people can work toward unifying them. Unfortunately,my view is that this currently has a major technical obstacle thatwe don't have good solutions for, which is the handling of multipleversions of dependencies.
A major difference between what I called program managers (such asDebian's apt) and module managers (such as Python's Pip)
At least from an outside perspective, Ubuntu is Canonical's thing
In some ways, Ubuntu and Debian look pretty similar to each other.They use more or less the same set of packages (because Ubuntu ismostly based on Debian packages) and they operate relativelysimilarly, to the extent that we could probably replace our use of Ubuntu with Debian without noticingmuch change. But there is a big difference. Debian is a communitywith a particular long-standing philosophy and set of practices,while Ubuntu is Canonical's thing, not a community.
It's true that Ubuntu
Use virtual environments to install third-party Python programs from PyPI
I've historically not been a fan of Python's virtual environments . While they're easyto set up these days, they're relatively heavyweight things (takingup tens of megabytes), they contain embedded references to thePython version they were built with , and itfelt like vast overkill for simply installing a program (such as the Python LSP server and the third partypackages it required from PyPI . So I'vehistorically used Pip's "user" install mode (' pip install -
Some notes on upgrading programs with Python's pip
My primary use of Python's pip package manager is to install programslike the Python LSP server ; I may install theseinto either a contained environment (a virtual environment or aPyPy one ) or as a user package with ' pipinstall --user '. In either case, the day will come when there's anew version of the Python LSP server (or whatever) and I want toupdate to it. As I noted down back in my pip cheatsheet , the basic command I want here
There are (at least) two types of package managers
These days, it seems that everything has a package manager (orpackage management system). Linux distributions and other Unixeshave long had them (Debian apt, Fedora DNF, FreeBSD ports, etc),as do languages; Rust has Cargo, NPM is for node.js, and Perl hasthe famous CPAN . However, over dealingwith a number of them I have come to feel that there are at leasttwo rather different sorts of things being lumped together underthe name "package managers". I don