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
i18n in kanidm #2105
Comments
after doing some cursory browsing through the ecosystem for i18n systems that meet the following criteria:
i have singled out the following crates/projects:
|
Thanks for raising this @pontaoski, it's good to know that there's genuine interest! We should decide on a framework for this before starting #1984 so that we can do the i18n while rewriting the messages. |
Well we may not need to delay #1984 on this, it just means we don't use thiserror/anyhow opting for messages to be added later. Server wise the log messages would be hard to i18n. I think for the moment is is focused on the ui elements. Regarding the options here, poreader appears to be quite old, possibly abandoned. Fluent however, appears to be sponsored by mozilla and is much larger and healthier as an ecosystem, so it may be better to investigate this as an option. |
In terms of "rust projects" Fluent is easily the healthiest, but in terms of "i18n formats" it's on shakier ground, as it's a very new format without the vast tooling support offered by older formats like Gettext. A cursory attempt of loading ftl files from Firefox into Crowdin and Weblate doesn't look very promising. Mozilla's own Pontoon seems to support it, but that would require hosting an instance specifically for kanidm since AFAIK nobody is sponsoring a free instance for FLOSS tools in general. There's nothing wrong with a plaintext-only workflow, but it would substantially increase the barrier to entry for translators without a firm grasp of git, especially with a format not exactly well-supported by desktop translation editing tools, and with a format that seems very keen on the DSL aspects of it. |
On the topic of suggestions, tr may be of interest. I've used it for localising paru in the past. Latest commit was July this year so it seems to tick the It works similarly to the two suggestions above, in that
|
That depends on gettext-rs which just calls into the non-rust gettext AFAIK |
That's fine, so long as there is a rust-binding that is well maintained. We aren't going to throw in something like Go or C here, but if there is gettext-rs that works, then we can use that as a possible option. |
Oh, I was under the impression you didn’t want to introduce a non-Rust dependency. In that case, gettext-rs would be my top suggestion for being literally just Gettext. |
... oh right, this has a web UI which prolly wants a solution that can handle specifiying language through any method other than environment variables :) in that case, Fluent time? |
Yeah, that might be best if it supports web. We need to look deeper into it. |
Thank you for your effort here @pontaoski . Let me do the deutsch for you once you got something available to be translated. I can handle whatever format, I guess (would be cool if a text editor is sufficient). I've recently used python's babel in my project. |
I think to start with we focus on the webui and get experience there before we go into the cli or other parts of the codebase. Is it possible to have the translations loaded from different files that we can fetch at runtime? Or do they need to be "built in" at compile time? |
also as an aside, I think the default language fallback should be en-AU (not en-US). I think that's reasonable today since the current translation is already en-AU. |
these sound like comments for the implementation pull request |
With the recent release of 1.2.0 , are there any new developments on this issue? Maybe something like Gitea. create a project in Crowdin and use bot to auto-sync the translations ? |
No progress since, we want to rework our webui for now to better prepare for this. |
And Crowdin looks pretty expensive for any non-trivial use 😨 |
@yaleman This is not a problem for kanidm, she is an open source project (: |
60k words adds up quickly when it's target-language * words... but I guess if it's easy to move from them to someone else that might work. I'd be worried if we built a big dependency on a cloud service that ends up trying to charge someone money. |
I'd rather not outsource the work anyway since it's unreliable if it will continue in future. We need something in house we can manage. |
Hi, I noticed a lack of i18n in kanidm and @Firstyear pointed me to open an issue here for conversation
My usual toolchain for introducing i18n to projects that haven't had them yet (like for instance https://github.com/Pryaxis/TShock/ or https://github.com/BlueMoonVineyard/BreweryNG) is gettext (or other .po-consuming system) + crowdin (propietary) or weblate (foss) for translation management
I'n not the most familiar with the situation of things in Rust, so i'll be doing some investigation on that; firstyear mentioned no non-rust dependencies
The text was updated successfully, but these errors were encountered: