Recent Posts (all)

Unread for iOS got acquired by an awesome developer!

I always hoped app.net would have become a new Twitter.

Not only was it friendlier than Twitter towards developers and users, but I was delighted every time I had to interact with it: I was using Riposte. If you followed the previous link I can tell you that I share Manton’s opinion:

Riposte is arguably the best social networking client out there.

The developer behind Riposte, Jared Sinclair also developed another delightful app: Unread, a beautiful RSS reader for iPhone and iPad.

Unread, luckily, didn’t end up the way Riposte did. It was acquired by Supertop, but, due to the success of Supertop’s other app, Castro, it did not get the attention it deserved.

I was therefore delighted and scared when Supertop announced that they sold Unread to Golden Hill Software. Delighted because the new owner has more time to work on it, and scared as what change is always scary.

Being scared turned out not to be such a unjustified feeling: the 1.7 version broke my set up with Stringer, a self-hosted, anti-social RSS reader1.

Basically Stringer offers a Fever-compatible API. The new version of Unread tried to do some smart things with the API, that Stringer was not offering.

I immediately wrote to John, Golden Hill Software’s owner. He quickly replied that he would look into it.

A few days later a new version of Unread came out but, alas, no fix for my issue.

I was kinda disappointed. I had to wait for the next release.

But no. John wrote me saying he pushed a PR to Stringer fixing the issue.

What a great developer! If you’re on iOS, please give it a spin. As a bonus, the newest version merges the iPhone and iPad version, which is timely as I realized some months ago that Mr. Reader, my favorite iPad RSS reader, was not developed anymore.

So give it a go, and support a great developer!


  1. I don’t think anyone is surprised when I characterize myself as anti-social. [return]

No system holding your private information is failing

Yesterday somebody called my wife. She didn’t pick up. Today (Saturday), upon picking up, the voice on the other hand presented himself as a Vodafone emploee. He said one of Vodafone’s system suffered some data loss and they wanted to check some personal information.

We recently moved, so my wife assumed that it might have been related. On the other hand she hears from me the worse stories about phishing and scamming that she got suspicious. She thought: “Why aren’t they sending me an email or a letter?” and she asked to be called one hour later, when I could have picked up the phone. The caller pushed back, saying it would only take 20”. She pushed back again, so he agreed to call back.

I know no systems containing the sort of information you could give on the phone would fail without a backup lying around. Especially for a company the size of Vodafone.

But maybe my wife misunderstood something, it could have been related to a new contract, etc. She said that on the background many people were talking, like in a real call center.1

So I called Vodafone myself. The lady on the phone told me I was the third person that day notifying them about it. She told me no systems had failed.

“Good”, I thought. Let me handle the guy. An hour later I picked up the phone. “Zakaria from Vodafone” he told me.

At that point, I already had LinkedIn open. I wanted to ask him his family name to look him up there.

“What’s your family name Zakaria?”. “I’m just here to ask some details about… “.

“I said what’s your family name Zakaria”.

He hung up.

There was not much to do, but what followed shows that Vodafone really handled it classy via their Twitter account. At 16:12 I tweeted

@vodafoneNL someone is calling your clients, pretending to be you, and asking personal info. Time to send an SMS around?

At 16:45 they got back at me and then via PM they asked:

Very good that you send us this message Giovanni. If I understand correctly someone called you pretending to be someone from Vodafone Customer Service and asks you for personal information. Can you tell me exactly how this conversation went ? And can you give me what day and time it was? I also need your mobile number so I can figure this out with our security department :-).

After telling them what happened, they promptly replied:

Thanks for sending the information. That does sound like a very strange conversation. I’ll send it right away to our security department for research. Good that you indicate this to us. If you encounter anything suspicious again let us know, then we investigate this immediately.

I have no idea what they’re going to do with it, but I really do hope they stop Zakaria and his likes!


  1. Although when I was on the phone later the background noise from other people talking was much higher than professional call centers.

    [return]

Use tab to cycle through Visual Studio Code completion

Sometimes, instead of using NeoVim, I do like to use Visual Studio Code (with Vim keybindings).

Visual Studio Code is a great editor with amazing Intellisense and debugging capabilities (for Python as well). There is however one thing that I could not swallow: the tab behavior when a completion was suggested.

With (Neo)Vim shift+tab and tab respectively cycle up and down the completion list.

I wanted to have the same experience in Visual Studio Code. After some Googling a lot of trial and errors, this is what I came up with (it works pretty nicely! You can paste the text below in the file that is opened after you click on File -> Preferences -> Keyboard Shortcuts)

[
        {
        "key": "tab",
        "command": "selectNextQuickFix",
        "when": "editorFocus && quickFixWidgetVisible"
    },
        {
        "key": "shift+tab",
        "command": "selectPrevQuickFix",
        "when": "editorFocus && quickFixWidgetVisible"
    },
        {
        "key": "tab",
        "command": "selectNextSuggestion",
        "when": "editorTextFocus && suggestWidgetMultipleSuggestions && suggestWidgetVisible"
    },
        {
        "key": "shift+tab",
        "command": "selectPrevSuggestion",
        "when": "editorTextFocus && suggestWidgetMultipleSuggestions && suggestWidgetVisible"
    }
]

The commands should be pretty self-explanatory! To accept the suggestion, you can use enter (that’s the default together with tab).

Make jupyter notebook work in WSL

In case you are playing around with the Windows Subsystem for Linux and jupyter, you might have notice this error:

Invalid argument (bundled/zeromq/src/tcp_address.cpp:171)

The issue, which arises because Bash on Windows does not currently expose any network interfaces, has been fixed by Adam Seering in its WSL PPA.

The fix he proposed, though, only works on when you install jupyter using Ubuntu repositories. In case you want to have it working with pip, I found the following to be helpful:

pip uninstall pyzmq
sudo add-apt-repository ppa:aseering/wsl
sudo apt-get update
sudo apt-get install libzmq3 libzmq3-dev
export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu
pip install --no-use-wheel -v pyzmq
pip install jupyter

Hugola

Approximately a month ago I fell for the new Dell XPS 15. It had the right price/spec combination (I went for the high-end model with 512GB SSD) so I went for it. This had of course some drawbacks, the main one leaving a *NIX like system.

Of course I am not the first guy making the switch, so there are lots of helpful resources around (although I might write one for the data scientists using Python).

One thing struck me though: Jekyll has no official Windows version. There is on unofficial guide but I wasn’t too eager to follow that. So I started playing around with Pelican, as I know some Python and as this is the tool that I already use with the GoDataDriven blog and website.

Around the same time, I saw the announcement, on Hacker News, of Hugo 0.15, that introduces a Jekyll import tool. And, more importantly maybe, it offers a simple .exe binary that you can just drop anywhere and call with hugo (or hugo.exe).

So in between things (mostly in the train) I gave it a go and issued:

hugo import jekyll jekyll_blog_folder hugo_blog_folder

Magically, all of my posts were converted. The code highlighting and the front matter were adjusted accordingly to hugo syntax (although I had to adjust the url). What was left out was the theme.

So the longish part of the transition began: rewriting my old theme for Hugo. Albeit the process was not difficult, some extra docs could have helped. Moreover the way to two theming engines works is different. But in the end I’ve finished and now my blog (and website) too is running with the hugola them (from hugo + Lanzani, but it nicely resembles ugola, which is the Italian for uvula).

In the process I removed some cruft: I removed JQuery and therefore Bigfoot and rewrote the other only thing that was using JQuery: the activation of the blue above the current page in the side bar. The old code was the typical exaample of JQuery usage:

$( ".blog-active" ).addClass( "menu-item-divided pure-menu-selected" );
$( ".blog-active" ).removeClass( "blog-active" );

The above snippet searches for the blog-active element and add the classes needed for the highlighting. It turns out that you can do the same in pure (modern) javascript if you make blog-active or whatever other class you’re using, into an id. Then you’re off with the following:

window.onload = function() {
document.getElementById("blog-active").className = "menu-item-divided pure-menu-selected pure-menu-item";
};

While these changes do not make it easier to blog, they are a symptom that I should have a bit more time to do so. So hopefully I can begin crunching posts again!

A functional count in Python

Today I was sifting through the documentation for itertools.count

Return a count object whose .next() method returns consecutive values. Equivalent to:

def count(firstval=0, step=1):
    x = firstval
    while 1:
        yield x
        x += step

Since itertools is supposed to provide you with better tools to write functional Python code, I thought it was odd that they have an example with x += step, redefining the x variable with every new invocation (although, to their defense, they only say that it is equivalent to the provided definition.

I sat therefore down wanting to create a “functional” version of it. Here’s what I came up with (Python 3.4 required)

def _count(first, step):
    while 1:
        yield first
        yield from count(first + step, step)

Normal mode in Vim

I consider myself an advanced Vim user. But I always found annoying the multiple cursors support that Vim has (through vim-multiple-cursors) and below the Atom and Sublime standards.

For example, say I have this piece of SQL and I want to convert all the field names to lowercase:

1 CREATE TABLE test (
2 MYFIELD1 STRING,
3 MYFIELD2 STRING,
4 ...
5 MYFIELDN STRING
6 )

Doing it with macros it tedious, and with multiple cursor, at least in Vim, it can be annoying, especially if you have lots of tables create like that, spanning multiple lines.

Enter normal mode

Normal mode comes to the rescue here: you just need to know which commands you would execute on one line to get the desired result (in this case _g~w) and the range of lines where the commands should be executed (in this case 2,5). Then it’s just a matter of typing :2,5norm _g~w and, almost magically, the code will be transformed in what we wanted!

1 CREATE TABLE test (
2 myfield1 STRING,
3 myfield2 STRING,
4 ...
5 myfieldn STRING
6 )
This is one of the features that keeps me in Vim and not in one of the emulated Vim mode out there (like Atom Vim mode)

Bij Brons in Almere

When searching for a good restaurant, I found Bij Brons in Almere. As it was the highest rated restaurant in Almere, I decided to reserve a table for two on a (lovely) Friday evening.

On the phone I chose the “5 gangen menù” which is the most expensive option the restaurant offers (for a mere €43.50 per person I have to say). By peeking their website, I read somewhere that their mission statement (or strategy statement, depending on how you call it) is to offer great food for reasonable prices (take notes, Twitter!). This, together with their high rating, convinced me that there were no tricks hidden behind the price, nor any up selling.

Starting from our phone call, Ivonne (the lady that owns the place, together with her husband, John) impressed me by spelling out my name right (“Giovanni” is, for Dutch-speaking, not the easiest word to pronounce correctly). Later at the restaurant I understood the reason: she speaks fluent Italian although she’s as Dutch as it gets!

But the good things do not end up here. Upon arrival (the local was full, luckily we called in advance) we found a modern restaurant with classic touches that was intimate and warm. Ivonne asked immediately if there was anything we didn’t wanted on our menu, to which my wife promptly answered “Onions!”. Afterwards, as my wife was pregnant, Ivonne said that the salmon we were going to have was safe for the baby. She then offered to look up whether the paté was safe as well, but I said that I’d Google that. It turns out fresh paté properly conserved is also safe for the baby.

Let me say that I’ve never experienced such a level of care for the guests: we’re often asked these questions, but Ivonne did so because she cared, not because she had to.

Afterwards, the various courses began appearing. I asked suggestion for the wine. Ivonne chose wisely: first a red wine (I don’t remember the name), then a white Almaral Gewurz to accompany the salmon. Food and wine were nothing short of delicious.

As we approached the fourth course, I took the wine choice in my hands and ordered a red Valpolicella. When John (cook and owner) heard me, he made a big smile, as if I already knew, even if I didn’t, what was coming next.

The remaining courses were flawless. Contrary to what I thought by reading the menu, we received 5 courses + dessert. The dessert probably doesn’t count as it is served in a glass rather than on a plate.

It really was a magical evening at Bij Brons. You should check it out if you ever pass by Almere.

Thanks John and Ivonne.

My @NoSQLmatters Barcelona talk

It seems like, right now, I only write in this blog when a get a new child or when I speak at some public event. Not breaking the tradition is this post, with the link to the slides accompanying the talk.

As John Gruber aptly put it (although for another conference):

Great crowd, great venue, and an amazing array of fellow speakers. It was a real honor and a thrill to speak [there].

I completely share John’s take if I had to describe my experience at NoSQL matters Barcelona.

Without further ado, here’s the link to the slides.

Elia

It took more than 9 months (9 months and four days to be precise), but Elia Lanzani is now here. He’s a healthy boy. He weights 3.8 kg and he seems like he could be a sleeper (I certainly hope so!).

The real hero is of course my wife that almost didn’t blink while delivering. If before this I was writing little here, rest assured I’ll write even less now :)