Changed validation errors to use defaultdict