Category Programming

Small rant about "blockchain" overuse

A lot of startups are using “blockchain” as a replacement hyped word for “distributed database”. Well, a blockchain is the most inefficient and slow “distributed database” ever created. Blockchain strength is not in being a database! Stop doing that! The blockchain power is in avoiding divergent transactions, and guarantee a not falsifiable and immutable history. That is, no node in the system can alter the past of the chain. That’s it.

How to add a logo in Rust documentation

One of the feature I like the most on Rust is automatic documentation. Documentation is a pillar in language ergonomic, and I love that Rust spend so much time into making documentation and documenting code a much pleasant experience. Rust autogenerated documentation (with cargo doc) looks good, every crate on crates.io get its documentation published on docs.rs, and, most important, every code example in the code is compiled and run as a “unit test” making sure that all the examples are up-to date!

The Most Promising Programming Languages for 2018

This is the time of the year in which I propose 5 emerging/new languages that you should keep an eye on the next year. I’ve done it last year, and the year before, and the year before that. This year, however, I am not in the mood of doing it. There are several reasons why. The first one is that this year there have not been a lot of movement on the new programming languages.

Preserving a Cryptography book from 1897

Some time ago I found on my grandma’s house an old Italian book on cryptography from 1897. Why a 120 years old book on cryptography was on my grandma house, is a mystery. I’d like to think that some grand-grand-parent was a late 19th century hacker. Anyway. The book title is “Crittografia ossia l’arte di cifrare e decifrare le corrispondenze segrete” of Count Luigi Gioppi of Turkheim. Well, I don’t know if this book is hard to find.

A Dwarf Fortress calendar in PureScript + Halogen

My last week project involves PureScript and Halogen and the Dwarf Fortress calendar. I wanted to give a first-hand experience with some pure functional language for web front-end and, after discarding Elm, I ended with PureScript. I will not go on a comparison between PureScript and the rest of the world. If you want a comparison among the other candidates, you can look at this very detailed article. (There is ClojureScript too, if Clojure will ever came back from the graveyard).

Crash course on basic ellipse geometry

Because I started a small series about astronomical algorithms and the magic of math in space, I think we need to cover an important prerequisite. In the series, I will talk a lot about ellipses (duh), I will move from the semi-axis majors, to the periapsis, to eccentricity, to ellipse’s center and ellipse’s foci. I am concerned that things can get more complicated than expected if the readers does not know many of the geometric properties of the ellipse.

WordPress abandoning React: a Facebook horror story

Today, during my daily web crawling, I found this article by Matt Mullenweg. I will not dwell in details, you can read the full story in the linked post. But I try to give you the core of the announcement: WordPress just decided to abandon React. This is a big news, with many implications and a few lessons to learn. Let’s go by steps. The Context You are probably asking yourselves: why?

Computing planetary orbits between two celestial objects

As you probably know, I am working (slowly) on an astronomically accurate calendar generator. All the orbital calculations involved are quite challenging, and I am discovering a lot. It is a lot of fun (except for the all the times I need to do some trigonometric magic to make some formula work). Anyway, during this process, I am reshaping and producing many many formulas. I am sure that in six months I will forget all the motivations behind them.

Minimized Cave Generation with Cellular Automata

Yesterday I wrote a cellular automaton based procedural caves generator algorithm that fits in a business card. The algorithm itself is not new. I already did it in C++, Rust, Javascript and many more languages. It is my personal approach to “Hello World”: when I want to try a new language, write a PCG algorithm in it.

Typescript Unit Test for Web Applications

You know, I quite enjoy TypeScript. It is not my favorite language ever, I am more a functional type of guy, but it is the best way to bring order into the JavaScript mess without too many hassles. Moreover, it is the language in which I prototyped my Astronomical Calendar Generator. Now that I’m working on extending it, I want to keep using TypeScript and stop falling in my usual decision paralysis.