DSpace 7 localization issue

173 views
Skip to first unread message

Andrew K

unread,
Nov 7, 2023, 9:18:21 AM11/7/23
to DSpace Technical Support
Hello!

I noticed that the localization files lag behind. And this is perfectly normal.
The documentation says: "When new keys are introduced, TODO messages are automatically added to the catalogs of other languages
But that does not happen, new keys are missing, at least for uk.json5. Is there a way to correct that?

And the next problem is that missing keys in the .json5 file are displayed as key names. It would be much much better if the English names were shown instead.
Is that possible?

Best regards,
Andrew

P.S.: 

DSpace Technical Support

unread,
Nov 15, 2023, 5:56:22 PM11/15/23
to DSpace Technical Support
Hi Andrew,

We're aware that these i18n files can get "out of sync" easily and are working on ways to improve that.  See this ticket: https://github.com/DSpace/dspace-angular/issues/2340

There's no exact solution yet, but many developers agree it's a frustration.  So, if you have more ideas to share, feel free to add to that ticket.

Regarding the display of missing keys, the current behavior is the same as it was in DSpace 6.x (where the key was displayed if missing).  I'm not aware of a way to change that to be English by default, but you are welcome to create a ticket regarding that and I can ask other developers to look into it.  I agree that it might be better to show English instead of a (cryptic) i18n key.

Tim

Andrew K

unread,
Nov 16, 2023, 12:01:49 PM11/16/23
to DSpace Technical Support
Hi Tim!

Thank you!

I just run yarn run sync-i18n and magically received fully updated localization file synced to the authoritative English file. 
Moreover, all translated keys I had added before were kept!
So I highly recommend this tool. It completely solves the problem of missing keys.

Best regards,
Andrew



четвер, 16 листопада 2023 р. о 00:56:22 UTC+2 DSpace Technical Support пише:

Emilia Lobo

unread,
May 22, 2024, 11:09:07 AM5/22/24
to DSpace Technical Support
Hello!

I couldn't fix this on the server (debian).
I ran both commands in .../dspace-angular:

yarn run sync-i18n

yarn merge-i18n -s src/themes/mytheme/assets/i18n

And I keep seeing keys instead of translations.

On the development team I can see them without problem.

Is there a missing step to take into account?

Thank you.-

Reply all
Reply to author
Forward
0 new messages