commit 8093549e58e1c2de03e29aefa5bf5d1d71f31324
Author: He Jie Xu <email address hidden>
Date: Wed Feb 17 16:26:19 2016 +0800
Generate better validation error message when using name regexes
There are some regexes used in the json-schema for complex string validation.
When the validation failed, json-schema lib didn't generate a useful error
info for the user, it shows the regex to the user. But regex is really
unreadable for normal user. This patch override the default FormatChecker to
support passed in custom error message. This required using custom format
checker instead of using 'pattern'.
Reviewed: https:/ /review. openstack. org/281143 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=8093549e58e 1c2de03e29aefa5 bf5d1d71f31324
Committed: https:/
Submitter: Jenkins
Branch: master
commit 8093549e58e1c2d e03e29aefa5bf5d 1d71f31324
Author: He Jie Xu <email address hidden>
Date: Wed Feb 17 16:26:19 2016 +0800
Generate better validation error message when using name regexes
There are some regexes used in the json-schema for complex string validation.
When the validation failed, json-schema lib didn't generate a useful error
info for the user, it shows the regex to the user. But regex is really
unreadable for normal user. This patch override the default FormatChecker to
support passed in custom error message. This required using custom format
checker instead of using 'pattern'.
Change-Id: Ie6d789e38f64e0 4a3a76618639c34 d36591d6187
Partial-Bug: #1541691