Millenial Math

I imagine a future where math textbooks for high school kids contain word problems such as this.

If a picture is worth one thousand words. Then how many tweets would it take to make one snapchat. Show your work.

This could also double as a basic engineering interview question.


Don’t Get Cancer

Disclaimer: This post is about smoking. Smoking is bad. When I was 16-17 I was the coolest fucking kid in the world and started to smoke. Now I am 27 and addicted. One day I hope to write a post about that is no longer the case.

Walking between 8th street and 2nd street on any given day in San Francisco, regardless of if I am currently smoking or not I will be asked at least 2-3 times if I have an extra cigarette or if I would be willing to sell one for anywhere from $0.25 to $1.00. If I am actively smoking this goes from 2-3 times to about 5-6 times. So extrapolating those numbers I get asked up to 12 times a day to part ways with my cancer sticks. 20 come in a pack, and a pack is about $7 so if I wanted to subsidize the smoking habits of everyone in this city I would go broke pretty quickly.

I have implemented a quota system where I will give away a cigarette to the first person who asks during the day, and say no to everyone else. Some people get angry when you say no, but trying to explain the quota system to them when they are in the middle of a desperate plea to satisfy their craving does not usually work. Other people just move along without saying anything.

Today, I got the best response ever from a guy who just missed the quota (he was the third person to ask me this morning). When I said, “no sorry”, he said “Oh, alright. Well… don’t get cancer.”

It was so satisfyingly passive aggressive that I had to write it down. Other people would typically just say “well, fuck you then.” This guy took it to the next level. Thank you stranger, and I hope that you can catch me first thing in the morning next time.


I Miss Ubuntu 10.04 LTS

Ubuntu 16.04 LTS was released today and as usual I ran off to install it on a VM to see what all of the fuss was about. Under the hood everything is perfect. A modern stable kernel, up to date packages (including most importantly the latest version of PostgreSQL), and of course the feeling of satisfaction in knowing that when I install this on a server I won’t have to worry about upgrading for five more years.

However on the frontend side, it was a whole different story. It seems like with each new release Unity gets slower and slower. To be fair, I installed this on a 1 Core VM with 2 GB of RAM and no video memory. Even after disabeling as many effects as I could the desktop still felt clunky and unresponsive.

I remember installing Ubuntu 10.04 LTS for the first time. Back then it ran GNOME2, it started up in seconds even on modest hardware. I miss those days. In any case, I look forward to years of great performance on the server side. Kudos to the Ubuntu team for another rock solid LTS release.


My First Pip Package

I finally got around to packaging up pg2cf and I am excited to see it out in the wild on pypi. Python packaging is pretty straightforward and this makes distribution of this tool much easier for us internally.

I could not have done it without this awesome python packaging guide.

Using setuptools also makes a lot of other things easier. For instance running tests is as simple as python test and installing the package locally can be done with python install. The main benifit of course is that now pg2cf is an executable so you once it is installed you can just run it.

The only “gotcha” that I ran into was that setuptools does not support markdown. Which makes it kind of weird since Markdown is now the standard for README and other documentation on GitHub.

I worked around this by using pandoc, this way I am able to convert my to README.rst easily with pandoc -o README.rst and then use that for PyPI.


Personalized Emails

Nathan Kontony wrote about how Personalized Emails helped them turn their brand around for Highrise.

But still, most companies end up sending out glorified press releases to communicate with their customers. Their emails sound like something created by a robot created or a group of faceless executives who wanted to make sure all the stats about their software were mentioned.

I agree that sending out personalized emails is better than whatever the default template coming out of HubSpot is, but I have been getting way too many of these “personalized” emails lately from random companies that scrape GitHub and WHOIS telling me about how awesome $YOUR_PRODUCT is and sharing photos of their kids in the process.

As far as I am concerned a the difference between a personalized email and an automated one is that the personalized one lacks an unsubscribe button.


pip-save NPM Style Package Management for Python

One of my favorite things about npm is how simple it makes it to manage production, testing, and development dependencies with the npm install --save command. I was browsing through the latest packages on PyPI and I came across pip-save which does basically the same thing as npm –save as a wrapper around pip.

From the Project README:

Currently its a big pain while installing new dependencies using pip. After installing the dependency, you need to figure out the version number and then manually add it to your requirements file. pip-save allows you to install/uninstall any dependecy and automatically add/remove it to/from your requirements file using one command only.

I cannot count the number of times where I have read a doc for some package and it said that installation was as simple as pip install foo. Sure, installing the package is that easy, but keeping track of versions is a whole different story.

One approach is to dump every single package into your requirements.txt with pip freeze > requirements.txt but this is troublesome because it also includes dependencies which clutter up the requirements.txt file.

What I then end up doing is finding the package on either GitHub or PyPI, figuring out what the latest version is, putting the package with the version into my requirements.txt file and then running pip install -r requirements.txt.

pip-save does exactly what it says on the tin and solves this annoying workflow in one step. It installs whatever package you want, and adds it to your requirements.txt with the version that you installed. Simple, Rustic, Yes.


Donate to Open Source Apps

I just got a new Macbook Pro since running Atom and Chrome on a Macbook Air was apparently too much for it to handle as it would OOM periodically.

In any case, this provided me the opportunity to go through the dance of installing all of the software and utilities that I cannot live without.

Two immediately come to mind, and this time rather than just installing them and thinking “wow, I am so lucky these exist”, I installed them and chipped in a few bucks as a donation to both projects.

These projects are iTerm2, which is in my opinion the best terminal emulator ever made, and Spectacle, which allows you to tile windows in OS X. I use both of these tools all day long and I am grateful that they exist.

If you have the means, next time you install an open source tool that you cannot live without, I would encourage you to chip in a few bucks to say thanks.


Growing the CircleCI Community with Discourse

One of the things that I am most proud of so far in my tenure at CircleCI is our community site. It has been really exciting to watch this small community blossom over the last six months. We now have over 2000 users, and more people sign up each day. It is great to see all of the great ideas, knowledge sharing, hacks, and engagement from our users.

My secret plan all along was to create an “international testing error database” and it looks like that is slowly but surely coming true. Over 80% of our traffic comes from worldwide google searches, and I assume that most of them are googling errors from their testing framework.

The most amazing thing is that a lot of people that come to the site for help are not even CircleCI users. This is great because at the end of the day, in addition to be a place where our users can get help and learn, I really would love for it to be the place where anyone using any CI tool can come and discuss how to do better at testing, CI, and CD.

I blogged about how we actually listen to feature requests, and also about a new thing that we are trying this week where users get to vote on a feature and at the end of voting we guarantee that we will develop it. It’s a cool experiment, and I encourage everyone to go vote!

I could not be happier with Discourse. It has enabled us to build a real community, and I am excited to continue to watch it grow.