-
-
Notifications
You must be signed in to change notification settings - Fork 135
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
Handling of defective .po files #282
Comments
Currently translated at 100.0% (92 of 92 strings) Translation: Open Preprint Systems/locale Translate-URL: http://translate.pkp.sfu.ca/projects/ops/locale/en_US/
Yeah, it makes sense to me. PR is appreciated, thanks! |
Great, I'll take a look at the code and |
FYI, I've checked the |
…mplete plurals, missing key headers, duplicated/malformed headers)
… file, added method getWarnings() and introduced new function (loadStringExtended) to avoid breaking the Gettext\Loader\Loader contract
…orLine (switch if the error message should show the byte/line where the error happened) to the StrictPoLoader
…-po-loader #282 Add strict po loader
If I try to load a
.po
file with the following content:It works, but the defective line is ignored. It would be great if the package could log a warning or fail with an exception (this could be probably configurable with a "strict mode", disabled by default to keep the compatibility).
I'll take a look in the code, perhaps I can contribute with another PR if you think the idea is ok.
The text was updated successfully, but these errors were encountered: