# The problem with a custom translation file

**URL:** <https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370>\
**Category:** Kibana\
**Created:** [April 29, 2020, 12:47pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370 "2020-04-29T12:47:41Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 29, 2020, 12:47pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/1 "2020-04-29T12:47:41Z")

</div>

Sources Kibana 7.6.2  
Kibana 7.6.2

Hi there! I started localization for RU. I did everything according to the instructions.  
On the develop server: generated the en translation file, imported it.  
On the working server:

1. Changed kibana.yml \>\> i18n.locale: "ru-RU"
2. in the root .i18nrc. json declared the existence of the file \> \> "translations": ["x-pack/plugins/translation/translations/ru-RU.json"]
3. Added the file to \>\> x-pack/plugins/translations/translations/ru-RU.json
4. I taught ikebana Started with the current settings

---

<div class="post-metadata">

**Author:** ![Mikhail\_Shustov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mikhail_shustov/32/49186_2.png) [@Mikhail\_Shustov](https://discuss.elastic.co/u/Mikhail_Shustov)\
**Post date:** [April 30, 2020, 9:37am UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/2 "2020-04-30T09:37:11Z")

</div>

@Vlad_Piratov Can you see any errors? or the file is just **completely** ignored? Could you make sure that `ru-RU.json` doesn't contain any metadata for translators? it should look like `"key": "value"`, not `"key: { "text":..., "comment": ... }`

> "translations": ["x-pack/plugins/translation/translations/ru-RU.json"]

should be "translations": ["x-pack/plugins/translations/translations/ru-RU.json"]

---

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 30, 2020, 9:40am UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/3 "2020-04-30T09:40:18Z")

</div>

The file is ignored. And there are no mistakes

---

<div class="post-metadata">

**Author:** ![Mikhail\_Shustov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mikhail_shustov/32/49186_2.png) [@Mikhail\_Shustov](https://discuss.elastic.co/u/Mikhail_Shustov)\
**Post date:** [April 30, 2020, 10:08am UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/4 "2020-04-30T10:08:00Z")

</div>

Could you check:

- an html page contains the correct lang attribute  
 ![2020-04-30_11-53-34](https://us1.discourse-cdn.com/elastic/original/3X/b/d/bdedef64f24e02fa909467ed236585b51e8f13e4.png)
- Kibana loads the correct translation files  
 ![2020-04-30_11-51-59](https://us1.discourse-cdn.com/elastic/original/3X/0/7/0787821784eeffea3f894ff0cb810613835b0a53.png)

---

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 30, 2020, 11:16am UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/5 "2020-04-30T11:16:25Z")

</div>

![image](https://us1.discourse-cdn.com/elastic/original/3X/2/a/2ac7d0785f0e131f69671dcd949157b26fe618a1.png)

When I change the ru-RU file.json on zh-CH.json, then everything works

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/f/d/fde2e35f024dd669c2ae59f6741f9cd8c2dd1dc1.png)

---

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 30, 2020, 11:41am UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/6 "2020-04-30T11:41:01Z")

</div>

What are your thoughts? 🙂

---

<div class="post-metadata">

**Author:** ![Mikhail\_Shustov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mikhail_shustov/32/49186_2.png) [@Mikhail\_Shustov](https://discuss.elastic.co/u/Mikhail_Shustov)\
**Post date:** [April 30, 2020, 11:45am UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/7 "2020-04-30T11:45:03Z")

</div>

trying to reproduce locally. In the meantime - I don't see `ru-RU.json` is present in the `translations/` folder. Are you sure Kibana loads it ?

---

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 30, 2020, 12:00pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/8 "2020-04-30T12:00:36Z")

</div>

I wrote the path in .i18nrc. json & x-pack/.i18nrc.json  
The screenshot showed:

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/e/1/e1ffbcd69414a334c24ea4c63b93c482ff08c539.png)

---

<div class="post-metadata">

**Author:** ![Mikhail\_Shustov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mikhail_shustov/32/49186_2.png) [@Mikhail\_Shustov](https://discuss.elastic.co/u/Mikhail_Shustov)\
**Post date:** [April 30, 2020, 12:27pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/9 "2020-04-30T12:27:45Z")

</div>

Ok. It looks like the problem that Kibana doesn't declare `ru-RU` locale [here](https://github.com/elastic/kibana/blob/v7.6.2/packages/kbn-i18n/src/core/locales.js) as suggested in [Локализация Кибаны](https://discuss.elastic.co/t/topic/228160/5)  
You can use any other known locale `de-DE`, for example, but it is going to include language rules (such as a plural form, ie) of this language. You could send a PR extending language set in Kibana with the Russian language. Or extend the set and [build Kibana locally](https://github.com/elastic/kibana/blob/7b57caf62beb33d06959ac6368a956a9e5f492aa/CONTRIBUTING.md#testing-and-building).

---

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 30, 2020, 12:46pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/10 "2020-04-30T12:46:48Z")

</div>

When I started the 'yarn run' project from the sources, everything was displayed correctly...

---

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 30, 2020, 12:47pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/11 "2020-04-30T12:47:19Z")

</div>

But I will try to do as you write and may actually have to compile the project from 0...

---

<div class="post-metadata">

**Author:** ![Vlad\_Piratov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vlad_piratov/32/66523_2.png) [@Vlad\_Piratov](https://discuss.elastic.co/u/Vlad_Piratov)\
**Post date:** [April 30, 2020, 12:49pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/12 "2020-04-30T12:49:31Z")

</div>

Thx u very big 🙂

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [May 28, 2020, 12:49pm UTC](https://discuss.elastic.co/t/the-problem-with-a-custom-translation-file/230370/13 "2020-05-28T12:49:44Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
