-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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] extract untracked translations and prettier logging #35171
Conversation
💔 Build Failed |
💔 Build Failed |
Pinging @elastic/kibana-platform |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code-wise approach looks good to me, but I defer to Platform team to review and test it thoroughly. Two main issues:
-
I couldn't force
i18n_check
tool to actually complain about untracked translations (I tried to put i18n calls to packages/kbn-es andxpack/plugins/oss_telemetry
, but tool didn't complain). Did I do something wrong? -
Label extraction seems to be broken - script silently exists and doesn't generate anything
Co-Authored-By: Bamieh <ahmadbamieh@gmail.com>
💔 Build Failed |
💔 Build Failed |
Pinging @elastic/kibana-stack-services |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some small suggestions, otherwise the embeddable changes LGTM, thanks!!
...lugins/embeddable_api/public/panel/panel_header/panel_actions/add_panel/add_panel_action.tsx
Outdated
Show resolved
Hide resolved
...lugins/embeddable_api/public/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx
Outdated
Show resolved
Hide resolved
…er/panel_actions/add_panel/add_panel_flyout.tsx Co-Authored-By: Stacey Gammon <gammon@elastic.co>
…er/panel_actions/add_panel/add_panel_action.tsx Co-Authored-By: Stacey Gammon <gammon@elastic.co>
…o i18n/untracked_checks
💔 Build Failed |
💔 Build Failed |
💚 Build Succeeded |
💚 Build Succeeded |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM in the operations perspective
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, this caught issues in my upcoming PR 👍
…5171) * extract untracked translations and prettier logging * self code review * Update src/dev/run_i18n_check.ts Co-Authored-By: Bamieh <ahmadbamieh@gmail.com> * updating listR * run new i18n_check and fix errors * kbnEmbeddables -> embeddableApi * remove any type * Update src/legacy/core_plugins/embeddable_api/public/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx Co-Authored-By: Stacey Gammon <gammon@elastic.co> * Update src/legacy/core_plugins/embeddable_api/public/panel/panel_header/panel_actions/add_panel/add_panel_action.tsx Co-Authored-By: Stacey Gammon <gammon@elastic.co> * self code review fixes * fix extract and integrate scripts * ts-ignore js file
) (#39130) * [i18n] extract untracked translations and prettier logging (#35171) * extract untracked translations and prettier logging * self code review * Update src/dev/run_i18n_check.ts Co-Authored-By: Bamieh <ahmadbamieh@gmail.com> * updating listR * run new i18n_check and fix errors * kbnEmbeddables -> embeddableApi * remove any type * Update src/legacy/core_plugins/embeddable_api/public/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx Co-Authored-By: Stacey Gammon <gammon@elastic.co> * Update src/legacy/core_plugins/embeddable_api/public/panel/panel_header/panel_actions/add_panel/add_panel_action.tsx Co-Authored-By: Stacey Gammon <gammon@elastic.co> * self code review fixes * fix extract and integrate scripts * ts-ignore js file * run i18n_check
Running
node scripts/i18n_check.js
now searches for labels in untracked files and throws an error if it finds any.Running this script detected 2 plugins using
i18n
but not adding their namespace to the.i18nrc.json
file. This is problematic because we do not extract/translate those untracked packages.This PR also fixes those issues as well:
"embeddableApi": "src/legacy/core_plugins/embeddable_api"
."xpack.code": "x-pack/plugins/code"
Better Error logging: https://terminalizer.com/view/98ad16001206
Context: #27376
Dev Docs
Running
node scripts/i18n_check.js
now searches for labels in untracked files and throws an error if it finds any.The i18n check tool now has an enhanced reporting experience with better error logging: