In the afternoon I finally finished Eve of Snows, Sundering of the Gods book 1, by L. James Rice. It took me quite some time to finish this book, I don't know why; it's not that bad. I consider it an ok read. I am not sure if I am going to read the sequel, though.
Yesterday, when we visited my brother Marco and his wife Ingrid to celebrate her 50th birthday Adam got a nice present; a fishing rod my brother's son no longer used. Because the weather was not that great we decided to try it out the next day; today.
We used mealworms, Tenebrio molitor, as bait. We had only once a fish nibbling on the bait, but no luck catching a fish. Adam got bored after a while, even before me. My father loved to fish, so we talked quite a bit about him. Since he passed away 18 years ago, sadly he couldn't be there. He would've loved this.
In the early afternoon I noticed a cast-off exoskeleton next to the burrow of the Ephebopus cyanognathus I keep; the little tarantula had molted. In the evening I took some photos of the molt.
In the above photo each square is 5mm by 5mm. I rehoused this small tarantula to a semi-arboreal set up the 3rd of May. It has been eaten at least twice since then and seems to be doing great.
This week's post is about using enumerated types (enums) in Python. You will learn:
- How to use enums to manage data that takes on a finite set of states.
- How to impose a custom ordering on data.
- How to represent a combination of states using
Source: Using enumerated types in Python, an article by John Lekberg.
The fact that Raku has no explicit references combined with the possibility to omit parentheses can sometimes mislead a developer. In this blog post, I will give a few examples of where I had some issues with trying to make it work.
Source: Some tips for working with hashes in Raku, an article by Andrew Shitov.
I congratulate the Linux Mint team for clearly taking a stand against snaps today by removing it from their repository, it was something many of us were voicing already since last several months. Snap is being shoved down upon Ubuntu users' throats by making it the default which isn't a very sensible thing to do.
You’ve likely heard everyone at the office or online proclaim that “K8s has eaten everyone’s lunch!” or that “everything should be in a docker container!”.
While there are advantages to the above methodologies; it’s very easy to have cargo-culted their adoption; especially for Kubernetes (K8s). I find the biggest problem however that there is a fundamental lacking of what is a container.
Source: Containers from first principles, an article by Farid Zakaria.
The Unix philosophy lays emphasis on building software that is simple and extensible. Each piece of software must do one thing and do it well. And that software should be able to work with other programs through a common interface – a text stream. This is one of the core philosophies of Unix which makes it so powerful and intuitive to use.
Source: The beauty of Unix pipelines, an article by Prithu Goswami.
With Go being a relatively modern programming language, first released in 2009, it is not unsurprising that it has great support for Unicode strings. What is surprising is just how far this support goes.
Source: Unicode Support in Go, an article by Marcus Noble.
In the evening I decided to take photos of the Aphonopelma seemanni I keep and its terrarium. I bought this tarantula together with a Brachypelma smithi the 7th of March 2020 during a visit to Avonturia De Vogelkelder.
Back then I made a starter burrow under a piece of cork tube cut in half. It moved in and has dug the starter burrow much larger since then. Recently it has been closing the opening with substrate and also webbed closed the opening. Most likely because it is going to molt soon.
It still likes to "hang out" as you can see in the above photo, with its legs pressed against the webbing.
The terrarium is a 19 litre (5 US gallon) plastic container with holes drilled in the lid. For substrate I used 12cm (4.7 inch) of a mix of coco peat and sand.
In the above photo you can see the cork tube, fake plastic plants, some twigs and a piece of wood, some real moss, and a plastic bottle cap to provide the large spider with a source of water.
See also Aphonopelma seemanni terrarium for a photo of the terrarium taken the 22nd of April.
There’s another technique that works for a subset of context-free languages. In my opinion, it is very elegant, and it is at least not painfully slow. The result is available on Hackage: the
rerelibrary. The idea is to treat regular expressions as a proper programming language, and add a constructions which proper languages should have: variables and recursion.
Source: Fix-ing regular expressions, an article by Oleg Grenrus.
Duck typing is the idea that instead of checking the type of something in Python, we tend to check what behavior it supports (often by attempting to use the behavior and catching an exception if it doesn't work).
Source: Duck Typing.
PostgreSQL 9.5 introduced a feature called block range indexes (aka BRIN) that is incredibly helpful in efficiently searching over large time series data and has the benefit of taking up significantly less space on disk than a standard B-tree index. A block range index entry points to a page (the atomic unit of how PostgreSQL stores data) and stores two values: the page's minimum value and the maximum value of the item to be indexed.
In fact, when used appropriately, a BRIN index will not only outperform a B-tree but will also save over 99% of space on disk!
Source: PostgreSQL BRIN Indexes: Big Data Performance With Minimal Storage, an article by Jonathan S. Katz.
In this post we’ll go over asynchronous APIs in general and some of their issues, what the async/await model of concurrency gives us, some of the primitives that Apple provides, and how
Taskercan work for your existing code, new code, and future code when swift actually gets async/await.
Source: Task-based async/await in swift, an article by Æli Akhtarzada.
In a previous blog post with LogRocket, I covered the RGB and HSL color models and how to manipulate their various color properties. One aspect that I did not have the chance to cover was some of the upcoming models coming to CSS. This post will overview all of the color models, new and old, that will be a part of the CSS Color Module Level 4, their properties, and when they might be useful.
Source: Colors in CSS: The present and future, an article by Adam Giese.
I don't believe I'm the only one to mention the documentation is lacking a little finish. What I personally find is that there's just a lot Nix allows you to do, and no two people do things the same way. On top of this, the official Nix manual may try to teach you a whole bunch of things you won't be using in practice.
This post is an attempt to help smooth the road a bit. What I will try to do is go through Nix terminology bottom-up, and hopefully explain concepts that way. But this will be very much from my perspective, and will contain some opinion as well.
Source: A Nix terminology primer by a newcomer, an article by Stéphan Kochen.
Even if you write clear and readable code, even if you cover your code with tests, even if you are very experienced developer, weird bugs will inevitably appear and you will need to debug them in some way. Lots of people resort to just using bunch of
Source: Ultimate Guide to Python Debugging, an article by Martin Heinz.
Awk crunches massive data; a High Performance Computing (HPC) script calls hundreds of Awk concurrently. Fast and scalable in-memory solution on a fat machine.
Totally confused by all the tools for managing dependencies? Pip, venv, Docker, conda, virtualenvwrapper, pipenv, … Which one should you use? Why do we even have all these different tools? Can they work together?
No wonder. The world of Python dependency management is a mess, but once you understand the tools and why they exist, it’s going to be easier to choose the one you want and deal with the others in environments where you can’t choose your favorite ones.
Source: Overview of python dependency management tools, an article by Mario Kostelac.
Have you ever tried to click photos with your camera in the laptop, of course, you did, but here is a twist, we will click the photo in a Docker container, many of you may be wondering how you can do that? Well, let me get started with this interesting thing.
Source: Taking images in Docker container, an article by Seema Saharan.
mDNS is a protocol that resolves hostname to IP addresses within a small network that lacks the name server. By default, mDNS exclusively resolves hostnames ending with
.local. But there will be a problem with the hosts that implement
.localdoesn't support mDNS protocol and can be found via a conventional unicast DNS sever. In those cases, necessary network configuration should be changed.
Source: mDNS, avahi and docker non-root containers, an article by Gnanesh Kunal.