Hi Paul,
Thanks. It is worth though someone else doing a sanity check on my proposed corrections! It is frustrating though that http://www.w3.org/TR/2004/REC-xmlschema-2-20041028 (as per https://datatracker.ietf.org/doc/html/rfc7950#section-9.4.5) does not define how to do match things case insensitively (that I can find) which would make this pattern much more readable for all of the regular and irregular branches. Regards Jon From: Mr. Jaehoon Paul Jeong [mailto: [email protected]] Sent: 01 June 2022 14:13 To: [email protected] Cc: [email protected]; [email protected]; [email protected]; Patrick Lingga; Mr. Jaehoon Paul Jeong Subject: Re: [I2nsf] draft-ietf-i2nsf-nsf-monitoring-data-model Hi Jon, Thanks for these two corrections about the YANG language pattern match below. We authors will reflect your comments on the following two I2NSF drafts under RFC Ed Queue, and submit the revisions: https://datatracker.ietf.org/doc/html/draft-ietf-i2nsf-nsf-monitoring-data-model-19 https://datatracker.ietf.org/doc/html/draft-ietf-i2nsf-nsf-facing-interface-dm-28 Thanks. Best Regards, Paul On Wed, Jun 1, 2022 at 9:49 PM <[email protected]> wrote: Hi there, I appreciate that this may be a bit late in the day, but I have found a couple of issues with the YANG language pattern match when doing a check against draft-ietf-dots-telemetry-25.txt, currently in AUTH48. What I have reported against that draft is:- During testing of the horrendous pattern provided for pattern matching against description-lang, I have found an alternate branch error which needs correcting. OLD: leaf description-lang { type string { pattern '(([A-Za-z]{2,3}(-[A-Za-z]{3}(-[A-Za-z]{3})' + '{0,2})?|[A-Za-z]{4}|[A-Za-z]{5,8})(-[A-Za-z]{4})?' NEW: leaf description-lang { type string { pattern '((([A-Za-z]{2,3}(-[A-Za-z]{3}(-[A-Za-z]{3})' + '{0,2})?)|[A-Za-z]{4}|[A-Za-z]{5,8})(-[A-Za-z]{4})?' I.e, additional () around A-Za-z]{2,3}(-[A-Za-z]{3}(-[A-Za-z]{3})' + '{0,2})? Reasoning - RFC5646 2.1 language = 2*3ALPHA ; shortest ISO 639 code ["-" extlang] ; sometimes followed by ; extended language subtags / 4ALPHA ; or reserved for future use / 5*8ALPHA ; or registered language subtag The additional () contain the 2*3ALPHA ["-" extlang] as a branch alternative to 4*ALPHA or 5*ALPHA. There also is an unneeded character range, namely OLD: + '|([0-9][A-Za-z0-9]{3})))*(-[0-9A-WY-Za-wy-z]' NEW: + '|([0-9][A-Za-z0-9]{3})))*(-[0-9A-WYZa-wyz]' As y is alphabetically adjacent to z ([0-9A-WYZa-wyz] is the singleton definition). Regards Jon _______________________________________________ I2nsf mailing list [email protected] https://www.ietf.org/mailman/listinfo/i2nsf
_______________________________________________ I2nsf mailing list [email protected] https://www.ietf.org/mailman/listinfo/i2nsf
