Skip to content

Machine Translation settings reset when saving configuration for another language #3353

@PiR1

Description

@PiR1

Describe the bug
When configuring specific Machine Translation providers for individual languages, saving the settings for one language appears to reset or erase the custom configurations previously set for other languages.

I expected to be able to configure each language independently (e.g., set Tibetan to Azure, then Arabic to DeepL) without the first setting being lost when saving the second.

To Reproduce
Steps to reproduce the behavior (based on the attached video):

  1. Go to Project -> Languages -> Machine Translation.
  2. Click on the Settings (gear icon) for a specific language (e.g., Tibetan).
  3. Select a specific provider (e.g., Azure Cognitive), set it as primary/suggested, and click Save.
  4. Observe that the icon updates correctly for that language.
  5. Click on the Settings (gear icon) for a different language (e.g., Arabic).
  6. Select a different provider (e.g., DeepL or Google) and click Save.
  7. Observe that the settings for the previously configured language (Tibetan) are reset or lost (or return to default).

Expected behavior
Changing the Machine Translation settings for a specific language should be isolated. It should persist the configuration for that specific language without modifying, resetting, or erasing the custom configurations of other languages.

Screenshots
See this video recording demonstrating the workflow of setting up multiple languages consecutively.

Enregistrement.de.l.ecran.2025-12-17.a.14.12.15.mov

Versions and environment

  • Tolgee Platform version: Current one (maybe 3.143.0)
  • Environment: Tolgee Cloud
  • Browser: Firefox 147.0b4

Additional context
For example the PUT request for machine-translation-service-settings has the following data as input:

{
  "settings": [
    {
      "enabledServicesInfo": [
        {
          "promptId": 1,
          "serviceType": "PROMPT"
        }
      ],
      "primaryServiceInfo": {
        "promptId": 1,
        "serviceType": "PROMPT"
      },
      "targetLanguageId": null
    },
    {
      "enabledServicesInfo": [
        {
          "serviceType": "GOOGLE"
        }
      ],
      "primaryServiceInfo": {
        "serviceType": "GOOGLE"
      },
      "targetLanguageId": "language_1"
    },
    {
      "enabledServicesInfo": [
        {
          "serviceType": "GOOGLE"
        }
      ],
      "primaryServiceInfo": {
        "serviceType": "GOOGLE"
      },
      "targetLanguageId": "language_2"
    },
    {
      "enabledServicesInfo": [
        {
          "serviceType": "AZURE"
        }
      ],
      "primaryServiceInfo": {
        "serviceType": "AZURE"
      },
      "targetLanguageId": "language_3"
    },
    {
      "enabledServicesInfo": [],
      "targetLanguageId": "language_4"
    },
    {
      "enabledServicesInfo": [],
      "targetLanguageId": "language_5"
    },
    {
      "enabledServicesInfo": [
        {
          "serviceType": "GOOGLE"
        }
      ],
      "primaryServiceInfo": {
        "serviceType": "GOOGLE"
      },
      "targetLanguageId": "language_6"
    },
    {
      "enabledServicesInfo": [
        {
          "serviceType": "GOOGLE"
        }
      ],
      "primaryServiceInfo": {
        "serviceType": "GOOGLE"
      },
      "targetLanguageId": "language_7"
    }
  ]
}

Settings are reset for langage 4 and 5

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions