Closed
Description
I benchmarked a validation against a json input of roughly 700k characters, and it seems deepcopy of the checker is the costliest operation
get_validator
relies on _get_format_checker
def _get_format_checker(self):
fc = deepcopy(oas30_format_checker)
for name, formatter in self.custom_formatters.items():
fc.checks(name)(formatter.validate)
return fc
The deepcopy of oas30_format_checker
is where most of the time is spent. Can you help me understand why there is a need for deepcopy ?