transifex / transifex-old-core

Translation workflow & crowdsourcing for agile teams. Older, open-source codebase of Transifex.com
https://www.transifex.com/
GNU General Public License v2.0
5 stars 5 forks source link

Uploading .po file with errors doesn't report line of the error #217

Open mexon opened 11 years ago

mexon commented 11 years ago

The zh-cn translation of messages.po in friendica was fully working. But it had one translation which included two "%2"s. Something apparently changed on the backend and this became a fatal error, resulting in the entire messages.po file being rejected.

It was a huge pain to track down what the error was, because when I upload the messages.po file it just fails saying "there was a syntax error". This file has thousands of translations in. I had to systematically do a binary search to isolate the problem.

The error message should at the least report which line the error was on, and preferably some indication of what the problem was.

nsallembien commented 11 years ago

Hi Matthew,

Thanks for the bug report, and sorry you had to spend a lot of time tracking down the error in your PO file. We recently changed our error reporting and we will take a closer look at it to see if we can improve our error reporting.

It seems like we have actually written a support article describing this issue: http://support.transifex.com/customer/portal/articles/1009931-syntax-errors-in-po-files

Could you please let me know if this support article would have been helpful in finding where the error was?

Thanks Nico

mexon commented 11 years ago

No, this article would have been no help finding the error, because how am I supposed to find the article? At the very, very least, link to the article from the error message.

I'm pretty disappointed that you chose to close this as a bug. You really think this is an acceptable way to report a problem to the user?

nsallembien commented 11 years ago

Hi Matthew,

I agree with you that linking to the article from the error message would be better. This is what I was referring to when I said that we should look at our error messages a little closer. My bad for closing the issue, I didn't mean to.

However, this article came up as the second link when I searched for "Transifex PO file error" on Google, so it's not a stretch to think that you could potentially have found it. I was interested in whether the text in the article was useful or not, not whether it was easy to find or not.

Thanks again for your feedback, Nico

mexon commented 11 years ago

I do happen to have msgfmt installed on my machine, so yeah the article points in the right direction. But asking people to install a piece of unix software really isn't an acceptable solution for the majority of users.

Thanks for reopening the bug. To clarify, to me the bug is that the "syntax error" message doesn't contain as much information as msgfmt: i.e., the line number, and some indication as to what kind of syntax error was involved. Add a link to the article as a temporary workaround if you like, but that is not the Right Thing to do.

jens-maus commented 10 years ago

I also really appreciate that the ticket have been reopened and is under investigation. As, however, ten month have passed now without seeing any change in this regard I would like to state that we have recently also switched to the services of transifex and are quite satisfied with all the workings of transifex. The only highly missing feature and problem we are having is that we have a bunch of translators wanting to offline-edit the po file and reupload them and they suffer exactly from the problem described in this ticket.

So please consider adding more information to the syntax error message. This would really help our translators in debugging things!

glezos commented 10 years ago

Will take a closer look again. This is not super-easy to solve in a correct way. Thanks for the ping.

Question: Any reason why translators prefer to work offline?

jens-maus commented 10 years ago

Some of them keep on their old habits I am afraid. Thus, they prefer an offline editor and want to simply upload their changed po files. In addition some people sometimes use editors to quickly search&replace stuff based on regular expressions or simpler rules. Thus, there is definitly a use case for providing an easy to use interface to reupload a po file and receiving a syntax error with information like 'msgfmt -c' outputs so that they workflow is not interrupted.