-
-
Notifications
You must be signed in to change notification settings - Fork 28
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
Duplicated entries when merging po file with update pot #68
Comments
Original comment by Luigi Toscano (Bitbucket: tosky, GitHub: tosky): Upon further investigation, the problem seems to be linked to the obsolete entries in the current po. If I remove them, the generated file is correct and the content matches the result of gettext msgmerge. Still, it shouldn't fail. |
Original comment by Luigi Toscano (Bitbucket: tosky, GitHub: tosky): I think the problem is in the merge method, here: |
Original comment by fyrestone NA (Bitbucket: fyrestone, GitHub: fyrestone): Maybe it is better to make context and msgid together as the merge key.
Also, gettext.py in Python standard library make context and msgid together as the gettext() key. |
Original comment by David Jean Louis (Bitbucket: izi, GitHub: izi): This should be fixed by https://bitbucket.org/izi/polib/commits/d0fcec9991c231015244e7e8cd6cac4f9bfbb0d0. |
Originally reported by: Luigi Toscano (Bitbucket: tosky, GitHub: tosky)
When merging a fairly complex po with the updated po template, the generated file contains various duplicated entries and it is invalid according msgfmt.
I tried with the current translation of digikam.po (both Italian and Ukrainian, quite complete) with the current pot, with a simple program which is almost like test_merge. The result is:
$ LANG=C msgfmt -o /dev/null --statistics digikam_it_new.po
digikam_it_guineapig.po:23014: duplicate message definition...
digikam_it_guineapig.po:11517: ...this is the location of the first definition
[...]
I tried to investigate in the source code and in the merge method, but I didn't identify so far the place where the duplicated entries are added.
The text was updated successfully, but these errors were encountered: