-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make the e-mail regexp more robust #33
Comments
@jiripetrzelka are you able to propose a better regexp? I would like to point out that improving the regexp won't have any impact on the data being produced in the responses but that doesn't mean that we don't see value in making this regexp better. |
It's unfortunately not that easy to check this regular expression. How should we proceed with validating it? Can I ask you to create a pull request with the proposed change? There is some work that needs to be done to put this regular expression in the XSD and I'm afraid to break it, as I'm not really able to check it afterwards. To sum up, I'm afraid that we might introduce more problems than it is worth. It would be great if there was already a well established type in XSD that we might just use. |
I couldn't find any tool that would convert the above mentioned regexp into a XSD-compliant format. I have only found some more simplistic examples, for example:
I guess any of them is slightly better than the regexp we currently use. |
Doesn't the second solution imply that solutions 1 and 3 are not good enough? I'm still not able to choose between solutions you proposed. If we don't find a solution that has been already validated by experts then we need to wait for some expert to join this discussion and propose or validate a solution. |
Any suggestions from other developers? |
Would it be possible to update the regular expression for e-mails so that only one e-mail and only a valid e-mail would pass the validation test?
Currently, we are getting tens, if not hundreds of invalid entries, especially in the Ounits API but also in IIAs and LAs., such as:
I guess many providers run their output through a validator before outputing the result to the outside world so I think that this would be a step towards ensuring a better quality of data exchanged.
Currently, since we validate the contents of the e-mail field against a standard e-mail validator, we are forced to either ignore the specific element altogether or consider the entire record (LA, IIA) invalid and therefore it does not reach end users.
ewp-specs-architecture/common-types.xsd
Lines 132 to 146 in af60d15
The text was updated successfully, but these errors were encountered: