You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
$ in a pattern also matches before a final newline, so "5\n" passes "^[0-9]+$" #1012
JavaScript agrees with the expected column: /^[0-9]+$/u.test("5\n") is false. On main, EcmaPatternConverter::toPcre('^[0-9]+$') returns /^[0-9]+$/u, which matches "5\n" too.
🚀 @dbuytaert, thanks for your contribution! Every idea, bug report, and discussion helps make this project better. Your input is invaluable, and we appreciate the time you took to share it. A maintainer will review it soon—stay awesome! 💡✨
⭐ Enjoying contributing? Star the project! ⭐ Your contributions help this project grow, and we'd love your support in another way too! If you find this repo helpful, consider leaving a star 🌟 on GitHub.
Hi, I can take this one. The fix is the D modifier on the regex built in EcmaPatternConverter::toPcre(), since every pattern / patternProperties check goes through it. I'll add tests at the converter level and for pattern and patternProperties in Draft-07 and Draft 2019-09. I already have it working on a branch, so I can open the PR today unless someone else is on it.
Activity
github-actions commentedon Dec 4, 2026
🚀 @dbuytaert, thanks for your contribution! Every idea, bug report, and discussion helps make this project better. Your input is invaluable, and we appreciate the time you took to share it. A maintainer will review it soon—stay awesome! 💡✨
⭐ Enjoying contributing? Star the project! ⭐ Your contributions help this project grow, and we'd love your support in another way too! If you find this repo helpful, consider leaving a star 🌟 on GitHub.
harshbhx commentedon Dec 5, 2026
Hi, I can take this one. The fix is the
Dmodifier on the regex built inEcmaPatternConverter::toPcre(), since everypattern/patternPropertiescheck goes through it. I'll add tests at the converter level and forpatternandpatternPropertiesin Draft-07 and Draft 2019-09. I already have it working on a branch, so I can open the PR today unless someone else is on it.The branch is ready on my fork: https://github.com/harshbhx/json-schema/tree/fix/1012-pattern-dollar-newline
DannyvdSluijs commentedon Dec 5, 2026
@dbuytaert thanks for the report. @harshbhx off course you can pick it up. Feel free to open the PR.