dotGo: things I learned teaching Go

Last month I had the honor of speaking at and I decided to talk about what I've learned by teaching Go.

The experience of learning a programming language is obviously quite different to learning natural languages, but in my opinion the biggest difference is on the attitude of the student. In this talk I discuss why we should keep a "I'm still learning" attitude longer while learning programming languages.

On the second part of the talk I discuss some of the topics that I've found to be hard to learn in Go, notably interfaces.

I hope you enjoy this talk as much as I enjoyed preparing and delivering it.
This is my most personal Go talk so far, which makes feel slightly vulnerable but seems like a risk worth taking.

The slides are available on speakerdeck.

Comment here or on twitter

Go meetups: building an app from scratch with Go AngularJS

Yesterday I gave a talk at the GoSV meetup in San Mateo talking about how to build a simple web
application in Go and AngularJS running on App Engine and obtaining data from the meetup API.

I recorded my screen and voice and I think the result is pretty interesting, so there it goes!

The code is available on and the slides here.

Go: Object Oriented and Concurrent (just not the usual way)

I was invited to talk about Go at OpenLate, an event organized by OpenDNS in San Francisco.

For the occasion I prepared a new talk which is the result of combining the concepts presented in my previous talks Go for Javaneros and Go for Pythonistas. On those talks I presented Go from the point of view of a developer from those languages and I realized that Go is often a sweet spot between both!

Where Python provides the flexibility of duck typing but with the corresponding runtime errors, and Java provides its interfaces Go provides structural subtyping, which results on the flexibility of duck typing with the compile-time checking of Java interfaces.

I also present concurrency as a sweet spot between the mutexes and locks used in Java and the async model present in other languages like Python, Ruby, or NodeJS.

I hope you will enjoy it!

The slides are available on

Twelve Go Best Practices

Last year I gave a talk at OSCON about Go best practices. The talk was pretty successful and when I shared the slides many asked for a recording which I didn't have.

This year I went back to OSCON and gave a different talk, this time about the Go playground (slides).
And since I was already in Portland, I decided to organize an event with the help of the Portland Go meetup.

During that event I reused the Go Best Practices talk and this time we recorded it!

Go pour Javaneros

Pendant la dernière édition de DevOxx France j'ai présenté "Go pour Javaneros", une introduction à Go du point de vue d'un Javanero, Javaïste, Java developer, etc.

Je commence par une introduction au système de types de Go, des types de base jusqu'aux interfaces et leur mécanisme de satisfaction.

Pour conclure je présente les concepts de base de concurrence en Go avec quelques examples d'utilisation.

Les slides pour le talk sont disponibles en Anglais sur

GitHub and Go: forking, pull requests, and go-getting

an octopher!
During the Go bootcamp that took place in Los Angeles some days ago ( someone asked me a very interesting question.

Question: how do you handle pull requests from different GitHub repositories?

The question seemed pretty simple to answer: you fork the project, then you do "go get" of the fork.
That answer is simple, but incorrect! If you know why ... well, then just go to the answer below.

It is incorrect, because if you fork a repository that has import statements referring to itself, they will be broken in the fork.

Before it gets more complicated let's make this a bit more concrete. You want to send a pull request to fix my awesome project cooltool in

First step is to fork the repository, which creates Easy!

Then you download the source code of the fork using "go get", this will put all the code from the repository in $GOPATH/src/

$ go get

Interestingly enough that also downloads Why?

Well, let's see the contents of

Do you see that? The import path refers to!

You could change it to refer to, but then you would run into conflicts when you send the pull request.

Answer: forks and remotes

There's a very simple solution to this problem consisting in three simple steps.

First fork the repository, as before this will create a

Then let's get the original code using go get. Yes, the original instead of the fork.

$ go get
$ git remote add fork

This added your fork as a remote, which means that once you've modified some files and committed the changes you can now run:

$ git push fork


GitHub is a great place to have your code and ,once you know how, sending pull requests for Go repositories is trivial!

ChromeGoDoc: a simple chrome extension for godoc

As part of my effort on getting acknowledged with new (to me) Google technologies today I decided to write a little Chrome extension.

The next video shows how it works, it's dead simple.

Wanna give it a try? Install it here.
And as always, the code is available on