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] verify select icu-message options are in english #74963

Merged
merged 12 commits into from
Aug 13, 2020

Conversation

Bamieh
Copy link
Member

@Bamieh Bamieh commented Aug 13, 2020

If the translated messages have a select icu-syntax message and its options are not in english i18n will throw an error at runtime, causing a browser crash.

This PR fixes this by ensuring that the messages coming from our translators adhere to this rule.

Added tests to the verifyICUMessage function and the introduced rule.

Context: #72984

@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-localization (Team:Localization)

Copy link
Contributor

@TinaHeiligers TinaHeiligers left a comment

Choose a reason for hiding this comment

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

nit for a typo but LGTM

src/dev/i18n/utils/verify_icu_message.test.ts Outdated Show resolved Hide resolved
@Bamieh Bamieh requested a review from a team as a code owner August 13, 2020 16:33
@spalger
Copy link
Contributor

spalger commented Aug 13, 2020

Would you like to try excluding operations from review of the src/dev/i18n directory? https://gist.github.com/spalger/e70e6b4f8e8015d593f97481a9240a98

@Bamieh
Copy link
Member Author

Bamieh commented Aug 13, 2020

@spalger yes! done

@spalger
Copy link
Contributor

spalger commented Aug 13, 2020

Hmm, doesn't look like it works if it's in the PR... Trying putting it in master... 250a0b1

@spalger
Copy link
Contributor

spalger commented Aug 13, 2020

@elasticmachine merge upstream

@spalger
Copy link
Contributor

spalger commented Aug 13, 2020

It worked!

@spalger spalger removed the request for review from a team August 13, 2020 18:43
@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Build metrics

✅ unchanged

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@Bamieh Bamieh merged commit ee9a8d2 into elastic:master Aug 13, 2020
@Bamieh Bamieh deleted the i18n/add_tests_verify_select_syntax branch August 13, 2020 20:44
Bamieh added a commit to Bamieh/kibana that referenced this pull request Aug 13, 2020
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Bamieh added a commit that referenced this pull request Aug 13, 2020
#74997)

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Bamieh added a commit that referenced this pull request Aug 13, 2020
#74998)

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
gmmorris added a commit to gmmorris/kibana that referenced this pull request Aug 14, 2020
* master: (23 commits)
  Adding API test for custom link transaction example (elastic#74238)
  [Uptime] Singular alert (elastic#74659)
  Revert "attempt excluding a codeowners directory" (elastic#75023)
  [Metrics UI] Remove TSVB dependency from Metrics Explorer APIs (elastic#74804)
  Remove degraded state from ES status service (elastic#75007)
  [Reporting/Functional] unskip pagination test (elastic#74973)
  [Resolver] Stale query string values are removed when resolver's component instance ID changes. (elastic#74979)
  Add public url to Workplace Search plugin (elastic#74991)
  [Reporting] Update more Server Types for TaskManager (elastic#74915)
  [I18n] verify select icu-message options are in english (elastic#74963)
  Make data.search.aggs available on the server. (elastic#74472)
  [Security Solution][Resolver] Graph Control Tests and Update Simulator Selectors (elastic#74680)
  attempt excluding a codeowners directory
  [ML] DF Analytics: allow failed job to be stopped by force via the UI (elastic#74710)
  Add kibana-core-ui-designers team (elastic#74970)
  [Metrics UI] Fix inventory footer misalignment (elastic#74707)
  Remove legacy optimizer (elastic#73154)
  Update design-specific GH code-owners (elastic#74877)
  skip test Reporting paginates content elastic#74922
  [Metrics UI] Add Jest tests for alert previews (elastic#74890)
  ...
@lukeelmers lukeelmers added the Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc label Oct 1, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-core (Team:Core)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Project:i18n release_note:skip Skip the PR/issue when compiling release notes Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc v7.9.1 v7.10.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants