add too-many-errors check