in ng-repeat i had been using (id, pin) as if visible_sensors, etc were all dictionaries mapping pin id to pin object. but these are lists, so what i thought was the ID was actually just the list index. luckily in every case where pin ID needed to be used for setting attributes i was using pin.id, which was correct, but yeah this was a bug. so now ng-repeat just says for pin in visible_sensors, etc