You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Translate missing strings in en.json with nl.json as the reference.
Context
We have a large project using Laravel 11, Vue 2 and Vue I18n 8.x with ± 5000 lines per language file. Currently we have nl.json and en.json in /lang, where nl is the primary language.
Before attempting the translation I removed all lines from en.json ending in ": null,, readying the file to receive translations (see #16).
php artisan translations:check en --source=nl --translate-missing --sort
Expected outcome
Missing translation strings are added with a translation provided by OpenAI.
Actual outcome
Checking translations...
No missing translations found.
No errors, but the missing keys or translations were also not there.
To verify, I then ran the same command without --translate-missing and it did add the missing translations with null as the value.
I then tried using free_google, which resulted in the keys of the source translation to end up as the value in en.json. It did go through the service, as one of the typos in the keys was fixed. This could however maybe be its own issue.
Please let me know if you need me to provide additional information.
Thoughts
My suspicion is that this might have to do with it being one large translation file containing roughly 5000 lines. This is the way Laravel recommends you to structure your translation files for large projects.
If the amount of data being too large is indeed the cause, maybe the translation process could be split up to prevent this from happening. But this is pure speculation from my end.
The text was updated successfully, but these errors were encountered:
I'll try with a smaller setup to see if u can reproduce it there. If not, I'm afraid the issue has to do with the size of the project, which is hard to replicate faithfully. The repo is not public.
It will be at least a week before I can get to doing this.
Goal
Translate missing strings in
en.json
withnl.json
as the reference.Context
We have a large project using Laravel 11, Vue 2 and Vue I18n 8.x with ± 5000 lines per language file. Currently we have
nl.json
anden.json
in/lang
, wherenl
is the primary language.Before attempting the translation I removed all lines from
en.json
ending in": null,
, readying the file to receive translations (see #16).Method
Expected outcome
Missing translation strings are added with a translation provided by OpenAI.
Actual outcome
No errors, but the missing keys or translations were also not there.
To verify, I then ran the same command without
--translate-missing
and it did add the missing translations withnull
as the value.I then tried using
free_google
, which resulted in the keys of the source translation to end up as the value inen.json
. It did go through the service, as one of the typos in the keys was fixed. This could however maybe be its own issue.Please let me know if you need me to provide additional information.
Thoughts
My suspicion is that this might have to do with it being one large translation file containing roughly 5000 lines. This is the way Laravel recommends you to structure your translation files for large projects.
If the amount of data being too large is indeed the cause, maybe the translation process could be split up to prevent this from happening. But this is pure speculation from my end.
The text was updated successfully, but these errors were encountered: