assert that each arg is valid at the top of this function