Skip to content
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
replace placeholder with instance data
  • Loading branch information
anakhalil committed Dec 20, 2022
commit 886971d3ce9cf4463f1c57125ff81635ccb1040c
2 changes: 2 additions & 0 deletions schema_enforcer/schemas/jsonschema.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
import copy
import pkgutil
import json
import re

from jsonschema import Draft7Validator, draft7_format_checker # pylint: disable=import-self
from schema_enforcer.schemas.validator import BaseValidation
Expand Down Expand Up @@ -61,6 +62,7 @@ def validate(self, data, strict=False):

if 'errMessage' in err.schema:
message = err.schema['errMessage']
message = re.sub(r'[s]\w+', str(err.instance), message)
else:
message = err.message

Expand Down