Skip to content
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: Mark Strings for Translations #1894

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Samk13
Copy link
Member

@Samk13 Samk13 commented Dec 4, 2024

❤️ Thank you for your contribution!

Description

Mark missing strings for translations

Checklist

Ticks in all boxes and 🟢 on all GitHub actions status checks are required to merge:

Frontend

Reminder

By using GitHub, you have already agreed to the GitHub’s Terms of Service including that:

  1. You license your contribution under the same terms as the current repository’s license.
  2. You agree that you have the right to license your contribution under the current repository’s license.

@Samk13 Samk13 added the i18n translation label Dec 4, 2024
@Samk13 Samk13 force-pushed the fix-translations branch 4 times, most recently from 165b1b4 to 88ae05f Compare December 5, 2024 00:23
@Samk13 Samk13 requested a review from utnapischtim January 30, 2025 13:18
@Samk13 Samk13 force-pushed the fix-translations branch 4 times, most recently from 2fef4f0 to 8928a1a Compare February 18, 2025 12:44
@Samk13 Samk13 force-pushed the fix-translations branch 2 times, most recently from 9cd7025 to 0061ba3 Compare February 18, 2025 12:54
* As of the Invenio docs, f strings are not supported, see:
https://inveniordm.docs.cern.ch/develop/howtos/i18n/#python
issue: python-babel/babel#594
* Remove f string usage in:
  - invenio_rdm_records/requests/access/requests.py
  - invenio_rdm_records/services/pids/errors.py
* Update string formatting for compatibility with i18n
the following strings were updated:
resources/serializers/utils.py
services/pids/errors.py
@@ -55,7 +57,7 @@ def metadata(self):
{
"person_or_org": {
"type": "personal",
"family_name": "Unknown",
"family_name": _("Unknown"),
Copy link
Contributor

Choose a reason for hiding this comment

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

is that Unknown really a to translatable string? it seems like an item of a controlled vocabulary.

Copy link
Member Author

Choose a reason for hiding this comment

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

Controlled vocabularies should not be translated since they serve as language-agnostic identifiers. However, in this case, the code seems to be setting a fallback value specifically for display purposes, meaning it is intended for end users. or?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
i18n translation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants