nit: there's two obvious things that this could mean, IllegalArgumentException or IllegalStateException. Just inline it? We throw a lot of IOExceptions but IllegalArgumentException is less common