Skip to content

Conversation

@imobachgs
Copy link
Contributor

@imobachgs imobachgs commented Jul 16, 2025

Problem

When displaying a product license, Agama allows to select the language to display the license. In general, it offers the same list of languages Agama is translated to. This has a few problems:

  • In some cases, the license is no translated to that language. The Agama falls back to English without informing the user.
  • It is just another language selector, which is kind of confusing.

Solution

Now the license is directly shown in the same language that Agama is using. No additional language selector. If the translation is missing:

  • It tries to find an alternative language (e.g., "Spanish" for "Catalan".
  • If there is no alternative, it falls back to English.

Alternative language

To search for an alternative language, Agama choses the first language in the same "territory". For instance, if you pick "Catalan" ("ca-ES"), Agama uses the langtable data to search for the first language in the same territory, which in this case it is "Spanish" (es).

Testing

  • Added a new unit test
  • Tested manually

Screenshots

The license is translated. No warning and no selector. license-found-license
The license is not translated to Catalan, but to Spanish. Warn the user. license-missing-translation
Fall back to English. Warn the user. license-fallback-english

Known problems

  • It takes a moment to refresh the page when you change the language. It may confuse QA but it is a known problem, not related to this PR.

@imobachgs imobachgs force-pushed the licenses-translations branch from 01849ac to 6029fae Compare July 16, 2025 14:45
@imobachgs imobachgs marked this pull request as ready for review July 16, 2025 14:45
Copy link
Contributor

@dgdavid dgdavid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TL;DR: LGTM 👍


As @shundhammer wrote in the bug report,

That additional combo box with the license translations was always quite weird; yet another language selection.

It was there because of reasons, but it felt indeed always weird. Now that stuff changed around the interface language selection and users can do it from the almost always available language selector at the top, this is hands-down a great step forward... for such a particular dialog.

Thanks!

Copy link
Contributor

@dgdavid dgdavid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Arg! We forgot the tests 🙄

@coveralls
Copy link

coveralls commented Jul 16, 2025

Coverage Status

coverage: 64.051% (+0.01%) from 64.04%
when pulling cf3040e on licenses-translations
into e8f1c2c on master.

@imobachgs imobachgs merged commit 5249cbc into master Jul 17, 2025
14 checks passed
@imobachgs imobachgs deleted the licenses-translations branch July 17, 2025 10:01
@imobachgs imobachgs mentioned this pull request Jul 21, 2025
imobachgs added a commit that referenced this pull request Jul 21, 2025
bmwiedemann pushed a commit to bmwiedemann/openSUSE that referenced this pull request Jul 22, 2025
https://build.opensuse.org/request/show/1294907
by user IGonzalezSosa + anag_factory
- Version 17

- Fix extensions layout to reduce excessive gaps on large
  screens (gh#agama-project/agama#2590).

- Fixed crash when registering an extension without registration
  key (bsc#1246690)

- Replaced all usage of generatePath with generateEncodedPath to
  ensure proper URL encoding of route parameters and prevent issues
  with special characters (bsc#1246551).

- Add button to allow re-probing storage devices.
  (gh#agama-project/agama#2565)

- Display a message when the license is not available in the
  selected language (bsc#1238364, gh#agama-project/agama#2571).

- Allow to use a whole disk or MD RAID without a partition table
  (gh#agama-project/agama#2559).

- Allow specifying the registration server (jsc#AGM-156).

- Improve UX around non-persistent connections (bsc#1245
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants