[Bug 34959] New: Translator tool generate too many changes
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Bug ID: 34959 Summary: Translator tool generate too many changes Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: ASSIGNED Severity: major Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: jonathan.druart+koha@gmail.com Reporter: jonathan.druart+koha@gmail.com QA Contact: testopia@bugs.koha-community.org If you update the po files using `translate update es-ES`, commit your changes, then run the script again, you will notice that changes are still generated. It's coming from the commented lines showing the #:filepath:line_number info They should be ordered the same way for each run to prevent unnecessary changes. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Translator tool generate |Translator tool generates |too many changes |too many changes -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Michal Denar <black23@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |black23@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |julian.maurice@biblibre.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #1 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- Created attachment 156781 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=156781&action=edit Bug 34959: Remove unused sub Nothing special here, this sub is not used and we can remove it. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #2 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- Created attachment 156782 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=156782&action=edit Bug 34959: Sort PO files correctly The PO files are not sorted when we update them which leads to unnecessary changes that are commited: hard to see differences and make git index grow superfluously. Test plan: 0. Do not apply this patch 1. gulp po:update --lang es-ES 2. git commit -a -m"First PO update" 3. Run again the gulp update command 4. git diff => You have a lot of changes generated here, the po:update is not idempotent. 5. Apply this patch 6. Run the gulp update command 7 git commit -a -m"PO update after 34959" 8. Run the gulp update command 9. git diff => No changes are generated Note that this patch will all the entries by files, and per line numbers. It fixes a bug in some condition, where we add information/context about the string. For instance search for "For the first occurrence" in the file. Prior to this patch this was not correct, we didn't add info about the first occurrence (but whichever in the list). -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #3 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- This is in the context of the migration to weblate https://wiki.koha-community.org/wiki/Translation_server_migration_weblate And the suggestion to let weblate deals with the PO files in their own git repository. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #156781|0 |1 is obsolete| | --- Comment #4 from David Nind <david@davidnind.com> --- Created attachment 156806 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=156806&action=edit Bug 34959: Remove unused sub Nothing special here, this sub is not used and we can remove it. Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #156782|0 |1 is obsolete| | --- Comment #5 from David Nind <david@davidnind.com> --- Created attachment 156807 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=156807&action=edit Bug 34959: Sort PO files correctly The PO files are not sorted when we update them which leads to unnecessary changes that are commited: hard to see differences and make git index grow superfluously. Test plan: 0. Do not apply this patch 1. gulp po:update --lang es-ES 2. git commit -a -m"First PO update" 3. Run again the gulp update command 4. git diff => You have a lot of changes generated here, the po:update is not idempotent. 5. Apply this patch 6. Run the gulp update command 7 git commit -a -m"PO update after 34959" 8. Run the gulp update command 9. git diff => No changes are generated Note that this patch will all the entries by files, and per line numbers. It fixes a bug in some condition, where we add information/context about the string. For instance search for "For the first occurrence" in the file. Prior to this patch this was not correct, we didn't add info about the first occurrence (but whichever in the list). Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=34983 CC| |david@davidnind.com --- Comment #6 from David Nind <david@davidnind.com> --- I'm not sure whether this bug is related, but have added anyway: Bug 34983 - Retranslating causes changes in locale_data.json Feel free to remove if it is not. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #7 from Jonathan Druart <jonathan.druart+koha@gmail.com> ---
From gettext's changelog:
Version 0.23 - October 2023 * msgmerge: - The msgmerge option '--sorted-output' is now deprecated. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |35043 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35043 [Bug 35043] Handling of \t in PO files is confusing -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |kyle@bywatersolutions.com |y.org | CC| |kyle@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #156806|0 |1 is obsolete| | Attachment #156807|0 |1 is obsolete| | --- Comment #8 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 157082 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=157082&action=edit Bug 34959: Remove unused sub Nothing special here, this sub is not used and we can remove it. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #9 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 157083 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=157083&action=edit Bug 34959: Sort PO files correctly The PO files are not sorted when we update them which leads to unnecessary changes that are commited: hard to see differences and make git index grow superfluously. Test plan: 0. Do not apply this patch 1. gulp po:update --lang es-ES 2. git commit -a -m"First PO update" 3. Run again the gulp update command 4. git diff => You have a lot of changes generated here, the po:update is not idempotent. 5. Apply this patch 6. Run the gulp update command 7 git commit -a -m"PO update after 34959" 8. Run the gulp update command 9. git diff => No changes are generated Note that this patch will all the entries by files, and per line numbers. It fixes a bug in some condition, where we add information/context about the string. For instance search for "For the first occurrence" in the file. Prior to this patch this was not correct, we didn't add info about the first occurrence (but whichever in the list). Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |23.11.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #10 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Pushed to master for 23.11. Nice work everyone, thanks! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m --- Comment #11 from Fridolin Somers <fridolin.somers@biblibre.com> --- Testing on 23.05.x : 3. Run again the gulp update command 4. git diff With patch I still get a lot off differences there. This patches are not be very important for old branches right ? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #12 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- (In reply to Fridolin Somers from comment #11)
Testing on 23.05.x :
3. Run again the gulp update command 4. git diff
With patch I still get a lot off differences there.
This patches are not be very important for old branches right ?
It is needed for the move to Weblate, it must be backported to *all* stable branches for the November releases. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #13 from Fridolin Somers <fridolin.somers@biblibre.com> --- OK on it -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)|23.11.00 |23.11.00,23.05.05 released in| | Status|Pushed to master |Pushed to stable --- Comment #14 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 23.05.x for 23.05.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 --- Comment #15 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- (In reply to Fridolin Somers from comment #14)
Pushed to 23.05.x for 23.05.05
*November release* is next month! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |ASSIGNED Version(s)|23.11.00,23.05.05 |23.11.00 released in| | --- Comment #16 from Fridolin Somers <fridolin.somers@biblibre.com> --- (In reply to Jonathan Druart from comment #15)
(In reply to Fridolin Somers from comment #14)
Pushed to 23.05.x for 23.05.05
*November release* is next month!
Ah sorry I thought ASAP before November release ^ Reverted -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=35024 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Pedro Amorim <pedro.amorim@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |pedro.amorim@ptfs-europe.co | |m --- Comment #17 from Pedro Amorim <pedro.amorim@ptfs-europe.com> --- (In reply to Fridolin Somers from comment #16)
(In reply to Jonathan Druart from comment #15)
(In reply to Fridolin Somers from comment #14)
Pushed to 23.05.x for 23.05.05
*November release* is next month!
Ah sorry I thought ASAP before November release ^ Reverted
Hi Frido, I see this has been pushed, reverted, and pushed again. Can you please update the "Version(S) released in". Thank you! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)|23.11.00 |23.11.00,23.05.6,22.11.12,2 released in| |2.05.17,21.11.26 --- Comment #18 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- (In reply to Pedro Amorim from comment #17)
(In reply to Fridolin Somers from comment #16)
(In reply to Jonathan Druart from comment #15)
(In reply to Fridolin Somers from comment #14)
Pushed to 23.05.x for 23.05.05
*November release* is next month!
Ah sorry I thought ASAP before November release ^ Reverted
Hi Frido, I see this has been pushed, reverted, and pushed again. Can you please update the "Version(S) released in". Thank you!
Done, my bad. Sorry! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)|23.11.00,23.05.6,22.11.12,2 |23.11.00,23.05.06,22.11.12, released in|2.05.17,21.11.26 |22.05.17,21.11.26 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |pasi.kallinen@koha-suomi.fi --- Comment #19 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- *** Bug 24797 has been marked as a duplicate of this bug. *** -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34959 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org