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

Incorrect id for a message #1089

Open
sambapete opened this issue Mar 18, 2023 · 5 comments
Open

Incorrect id for a message #1089

sambapete opened this issue Mar 18, 2023 · 5 comments
Assignees

Comments

@sambapete
Copy link
Contributor

sambapete commented Mar 18, 2023

Because one of our users complained of a wrong translation, I found something that may be confusing.

In
src/alerts/course-start-alert/CourseStartAlert.jsx
shouldn't
id="learning.outline.alert.end.long" really be
id="learning.outline.alert.start.long" ?

@rediris
Copy link

rediris commented Aug 22, 2023

@sambapete can you be more specific about which translation was incorrect?

Note: There is no learning.outline.alert.start.long, but there is a learning.outline.alert.start.short.

@sambapete
Copy link
Contributor Author

sambapete commented Aug 22, 2023

That's the problem. In the code, in src/alerts/course-start-alert/CourseStartAlert.jsx, learning.outline.alert.end.long should really be learning.outline.alert.start.long

Line 71 should be learning.outline.alert.start.long instead of learning.outline.alert.end.long. Look at the code, it does not make sense that it would be end.long.

@rediris
Copy link

rediris commented Aug 24, 2023

Hi @sambapete I was trying to point out that none of the translation json files reference that variable name. For example, see https://github.com/openedx/frontend-app-learning/blob/master/src/i18n/messages/de.json#L9-L10
Check some of the other translation files too. There is a learning.outline.alert.start.short but there is no learning.outline.alert.start.long, so you might consider updating your PR to reflect that. #1167

@sambapete
Copy link
Contributor Author

Exactly. That's because the id used on line 71 is "wrong". As I said it should be learning.outline.alert.start.long and it does not exist. And if you modify the code, the harvest of strings for Transifex will pick up the new id and add it to the translation files. We're basically saying the same thing.

@rediris
Copy link

rediris commented Aug 24, 2023

@sambapete Ah, gotcha. Thanks for clarifying!

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

No branches or pull requests

2 participants