Add validations against ISO enumerations? #83
-
Where we specify certain ISO formats, do we want to preload an enum type with all matching values (or, if possible, reference a remote schema so we don't have to update the list) so that we can make sure valid values are provided? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
@JSv4 I assume you are referring to things like ISO-3166 country codes, for example? In my opinion, I think we should avoid these kinds of validations. These kinds of things inevitable create maintenance headaches that are not our core interest. If I were writing an open-source validation library for the schema, I would certainly allow my users to provide additional validation logic, so that they could choose to add checks like these. That is, to me, the right "layer" of concern to address this issue. |
Beta Was this translation helpful? Give feedback.
@JSv4 I assume you are referring to things like ISO-3166 country codes, for example? In my opinion, I think we should avoid these kinds of validations. These kinds of things inevitable create maintenance headaches that are not our core interest.
If I were writing an open-source validation library for the schema, I would certainly allow my users to provide additional validation logic, so that they could choose to add checks like these. That is, to me, the right "layer" of concern to address this issue.