split out handlers from spec