openshift / console-plugin-template

Minimal template for writing OpenShift console plugins
Apache License 2.0
37 stars 47 forks source link

CONSOLE-3654: console-plugin-template repository should support localization #47

Closed Mylanos closed 11 months ago

Mylanos commented 1 year ago

Links to: https://issues.redhat.com/browse/CONSOLE-3654

Adds possibility to generate locales in the console-plugin-template repo.

openshift-ci-robot commented 1 year ago

@Mylanos: This pull request references CONSOLE-3654 which is a valid jira issue.

In response to [this](https://github.com/openshift/console-plugin-template/pull/47): >Links to: https://issues.redhat.com/browse/CONSOLE-3654 > >Adds possibility to generate locales in the console-plugin-template repo. > Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
Mylanos commented 1 year ago

/retest-required

jhadvig commented 1 year ago
  1) Console plugin template test
       "before all" hook for "Verify the example page title":
     CypressError: `cy.exec('cd ../../console-plugin-template && /tmp/helm upgrade -i console-plugin-template charts/openshift-console-plugin -n console-plugin-template --create-namespace --set plugin.image=registry.build01.ci.openshift.org/ci-op-q9b5jsxw/pipeline@sha256:619b1c4b96723afa7f5e21994f8c8c2abf7ca8450b508a07aee2a9aeac392061')` timed out after waiting `60000ms`.
https://on.cypress.io/exec
Because this error occurred during a `before all` hook we are skipping the remaining tests in the current suite: `Console plugin template test`
Although you have test retries enabled, we do not retry tests when `before all` or `after all` hooks fail

/retest

Mylanos commented 1 year ago

/retest

jhadvig commented 1 year ago

/retest

Mylanos commented 11 months ago

{Operator unavailable (null): operator is not reporting conditions Operator unavailable (null): operator is not reporting conditions}

{ openshift cluster install failed with cluster creation}

{ openshift cluster install failed overall}

Mylanos commented 11 months ago

/retest

Mylanos commented 11 months ago

/retest

openshift-ci[bot] commented 11 months ago

@Mylanos: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository. I understand the commands that are listed [here](https://go.k8s.io/bot-commands).
jhadvig commented 11 months ago

QE Approver: /assign @yanpzhan

Docs Approver: /assign @opayne1

PX Approver: /assign @RickJWagner

openshift-ci[bot] commented 11 months ago

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by: jhadvig, Mylanos

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - **[OWNERS](https://github.com/openshift/console-plugin-template/blob/main/OWNERS)** Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
RickJWagner commented 11 months ago

/label px-approved

opayne1 commented 11 months ago

/label docs-approved

yanpzhan commented 11 months ago

I run the plugin using a local development environment by: In one terminal window, run: yarn install yarn run start In another terminal window, run: oc login yarn run start-console Then access "localhost:9000/example?pseudolocalization=true&lng=en", could see contents are marked for i18n. Screenshot from 2023-08-14 17-46-49 @Mylanos If there others I need to check for the US?

Mylanos commented 11 months ago

I run the plugin using a local development environment by: In one terminal window, run: yarn install yarn run start In another terminal window, run: oc login yarn run start-console Then access "localhost:9000/example?pseudolocalization=true&lng=en", could see contents are marked for i18n. Screenshot from 2023-08-14 17-46-49 @Mylanos If there others I need to check for the US?

I'm sorry but I'm not sure if I understand correctly, could you please clarify the question?

yanpzhan commented 11 months ago

@Mylanos I mean except the check in above screenshot , if there are any other checkpoints I need to test for the feature from the pr code.

Mylanos commented 11 months ago

@Mylanos I mean except the check in above screenshot , if there are any other checkpoints I need to test for the feature from the pr code.

That's pretty much it, other than that the features that this PR brings is the locale/translations files and contents get automatically generated from source codes via yarn i18n, so you can check if all the strings inside the source code get translated after you remove the locale files. But that is closely tied with the check if all the strings on the example page are marked for i18n.

yanpzhan commented 11 months ago

@Mylanos Thanks. I tried to remove file: # rm locales/en/plugin__console-plugin-template.json # yarn i18n After yarn i18n, the file under locals is generated again. /label qe-approved

openshift-ci[bot] commented 11 months ago

@yanpzhan: The label(s) /label qe-approved. cannot be applied. These labels are supported: platform/aws, platform/azure, platform/baremetal, platform/google, platform/libvirt, platform/openstack, ga, tide/merge-method-merge, tide/merge-method-rebase, tide/merge-method-squash, px-approved, docs-approved, qe-approved, downstream-change-needed, rebase/manual, approved, backport-risk-assessed, bugzilla/valid-bug, cherry-pick-approved, jira/valid-bug, staff-eng-approved. Is this label configured under labels -> additional_labels or labels -> restricted_labels in plugin.yaml?

In response to [this](https://github.com/openshift/console-plugin-template/pull/47#issuecomment-1680295344): >@Mylanos Thanks. I tried to remove file: >` # rm locales/en/plugin__console-plugin-template.json` >`# yarn i18n` >After yarn i18n, the file under locals is generated again. >/label qe-approved. Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
yanpzhan commented 11 months ago

/label qe-approved