Preparations for 0.5 release. Fixed upgrade script to not bail on insert errors, and de-duplicate the db.