Checking for Python Package Updates at PyPI

I frequently find myself wondering if a bug in a Python package has been fixed and whether there is an upgrade for that package that might fix the bug. So I find that I end up running pip freeze and then having to compare the package versions to those on PyPI manually. Well, anytime you say “run X manually”, you’re being a chump.

I just saw down and wrote a script to get the list of currently installed packages in the current environment (so it works with virtualenv). Then it checks to see what the latest version of the package is on PyPI and prints out the status. If you work with Python and packages, this is awesomesauce.

I added the script to my dotfiles on github. (read more)

Homebrew Package Update Notifications via Growl

Over the weekend, I finally upgraded my system to Mac OS Lion. I also took the opportunity to do a completely fresh install of my system, doing a final TimeMachine backup before erasing the hard drive and then installing Lion off a USB thumb drive.

I have long used MacPorts as my open source package manager, but I’ve had issues recently with certain ports not being updated or being out of date. So I was really interested in Homebrew.  The fact that it is all on github, open and actively developed really appealed to me. After getting it up and running, I wanted to port my package update notifier to use Homebrew. Doing so was really quite easy. Here’s what I came up with, which is also in my dotfiles on github. (read more)

World Backup Day: How I Backup

Today was World Backup Day, and, in the footsteps of Ars, decided I’d detail my current backup strategy. I first started backing up regularly after an incident back in college. One day the hard drive in my laptop began making the telltale sounds of imminent failure. Then the computer stopped booting. And I hadn’t backed up the drive in several weeks, which would have caused me to lose a bunch of data. I ordered a new drive, and just before I was about to install it, I was luckily able to boot my laptop and then copy the data off of it, losing nothing. Since then, I’ve been an big advocate of backups.

My primary computer is a Macbook Pro. Since it is also the computer that all my photos and important data is on, I don’t want to lose any of it. Every day I make sure to plug in my 1 TB external hard drive that Time Machine mirrors the contents of drive to. So at all times, I’ve got a backup of my drive and a history of the files. I also have another external drive that I keep at my parent’s house in their safe that is filled with Time Machine backups. So if my house blows up, I have something to fall back on. The problem with that disk though is that it is several months out of date. And that sucks because my data changes all the time.

But thats not all for my laptop. I also make use of CrashPlan. At home, I also have a Linux box with a 4 hard drives in a RAID 5 setup, so if one drive dies, I don’t lose any data, I can just replace the drive. So I have CrashPlan backup my laptop to my Linux box onto it’s RAID storage, and this can happen anywhere my laptop has Internet access. Currently, CrashPlan is configured to run every night.

My email is hosted in the cloud, but I still run hourly backups onto the RAID storage in my linux box using mbsync. I also run backups of my Google Docs every day using gdatacopier (again, saving to my Linux box).

(read more)

MacPort Package Update Notifications via Growl

I wrote a quick little script this morning to notify myself of updates to MacPorts via the Mac OS X notification app Growl.  The script is a bash script that is designed to run as root from a cronjob (as the port sync command requires root permissions). You can find the script committed in my dotfiles repository on github.  For convenience, I pasted the script below, though the copy on github will always be the most up-to-date copy.
(read more)

Python virtualenvwrapper and Logging

I ran into this issue, and couldn’t find a resolution anywhere online. Well, I figured it out, and thought that I’d put it online for others to find.

The issue was that I got exception tracebacks when sourcing the /usr/local/bin/virtualenvwrapper.sh script upon bash initialization. However, the exception happens while Python is running it’s atexit handlers. So the stack was only 3 levels deep. I’m running virtualenv and virtualenvwrapper on my Ubuntu 9.04 server.
(read more)

Blackout Days

What does one do when one has a cabin in Truckee and a season pass to a ski resort that is blacked out?  Well, in my case, I still want to be active in the snow. Over the past week, I decided to go snowshoeing up near Donner Lake. Family and friends parked near Donner Summit and then followed part of the Pacific Crest Trail south towards Sugar Bowl until we were able to overlook Donner Lake on a beautiful day.

Forging a Trail

Icicles

Then, a few days later, on New Years Eve day, I went nordic skiing for my first time ever.  We started at the State Park at the east end of Donner Lake and followed a trail several miles out, for about a four hour trip. By the end, I was definitely ready to be done with the skis, and probably won’t go that long again until I’m a bit more experienced on skis (downhill and nordic). It definitely didn’t sour my first experience though and I plan on going at least several more times this winter.

Nordic Skiing

Puffy Snow

Looking Back on 2010

As 2010 winds down in the next few days, I decided to write up a summary of my past year in what, some would term, a Christmas letter. Well, it’s after Christmas, so this is officially a Review of 2010 letter. I emailed out a link to quite a number of people that I’ve got email addresses for. So if you aren’t on that list, you can find the body of work and associated pictures at my 2010 in Retrospect page.

You can keep up with me next year here on my site and through my photos at Flickr or at my gallery. I’d love to hear how your 2010 went, so write back. Hope your 2010 was a good one and all the best next year.

My First 30k

A few months back, around the beginning of September, my sister, a friend and I all decided that we wanted to do a longer trail run. We actually decided this while on a run through some redwoods together. Since we enjoyed trail runs, we decided that the best way to do a longer distance run would be to sign up together and commit to finishing instead of focusing on being competitive in the race.

A terrain view of the course route

When we got home, we looked up to find a 30-35 kilometer Pacific Coast Trail Run that was several months out, giving us plenty of time to train. We settled on the Rodeo Beach 30k, on December 18th. It was on the shorter side (30km instead of 35km), it was plenty far out, giving us a lot more time to train, and it was in the Marin Headlands, a beautiful area that we could train at. I signed up almost immediately, as I knew the act of signing up would get me to commit mentally.  My sister signed up and so did my friend (at least I thought she did). I also got a couple people at my gym to sign up too. Things were shaping up nicely.

The start of the race led up a couple hills. It was also quite overcast.

I didn’t train as much as I wanted to while on my Balinese vacation, and upon returning, I tried to stick to a more rigid training schedule where I ran more frequently. Well, I didn’t stick to that schedule as well as I should have. As of the day of the race, the farthest distance I had run in the many months prior was about 7.5 miles, not even half of the final distance of 18.64.  I wasn’t terribly nervous, I knew I could still finish the race, but I figured I’d be doing a lot more walking that I’m used to, especially up the hills. And there are a lot of hills on this race, giving the 30km race a formidable 3740 feet of elevation gain along the course. However, it turns out my sister and friend also hadn’t been training for the race either.

(read more)

Post-Thanksgiving Bishop Climbing Trip

After Thanksgiving at my parent’s house, I took off with some friends to Bishop for 3 days of bouldering and some sport climbing. We arrived just after some storms had passed through the area, leaving a light dusting of snow in some places.

Eastern Sierras Under Shadow

Then, right in the middle of the trip, we got a couple inches of snow in the evening, electing to remain at our site camping in it.

(read more)

Facebook Exporter for Aperture

I’ve wanted to recently upload some of my pictures to Facebook. However, there are several things I really dislike about Aperture’s built-in Facebook syncing.

First, order is not preserved. I want pictures ordered in a predicable way. Often, by date. I have yet to figure out how Aperture chooses to export, it seems to be quite random and is infuriating.

Second, tagging friends on Facebook from the built-in Aperture Faces is spotty, at best.  Sometimes it works, and other times I get lots of pictures with people’s names tagged, but those names are not linked to the proper Facebook friends, despite being tagged with the exact same name. Again infuriating!

Third, making any change in Aperture (adding a tag, etc), causes the photo to be re-uploaded to Facebook, creating an updated photo album feed story. I don’t want this behavior. I want to export my photos to Facebook and then choose when it should be updated again.  I’ll let you guess my emotion.

After finding no other solutions, I wrote my own Facebook exporter

So, what other options are there out there? Well, this guy Sean Farley created a plugin. However, it is broken on my computer. Supposedly, it does work for some people on Aperture 3, but I cannot get it to even show up in the Export menu and I get no Console messages. I’ve even emailed Sean twice trying to contact him and help figure out why it is broken. No response.

Finally, I’ve given up with these options. I’m not a prolific Facebook photo uploader, but there are times when I want to put up pictures on Facebook instead of Flickr. And I couldn’t do it without exporting the photos from Aperture to my disk, and then using Facebook’s photo upload.

So over the past couple weeks, I spent some time creating my own export plugin for Aperture. I don’t want to completely support this project (beyond having it work for me), and so I decided to release it on github for the benefit of the community. My goal is that someone else will find the code and project useful. There are currently several limitations (documented on github) and I’m sure there are bugs, but I’ve got the project to a stable enough point where I can upload photos to Facebook and am happy with where I’ve gotten it. Check out the github page for more information on getting the plugin and using it.