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

[BUG][Data Explorer] Large string error on data explorer #5068

Closed
abbyhu2000 opened this issue Sep 19, 2023 · 1 comment
Closed

[BUG][Data Explorer] Large string error on data explorer #5068

abbyhu2000 opened this issue Sep 19, 2023 · 1 comment
Assignees
Labels
bug Something isn't working data explorer Issues related to the Data Explorer project de-angular de-angularize work v2.11.0

Comments

@abbyhu2000
Copy link
Member

Describe the bug
One of the functional test for discover is to test the ability of rendering data entry with a large size string. When i load the large string dataset to data explorer, the hit number is not being displayed.

Current:
Screenshot 2023-09-19 at 2 18 08 PM

Expected:
Screenshot 2023-09-19 at 2 18 24 PM

To Reproduce
This is the functional test: test/functional/apps/discover/_large_string.js

@abbyhu2000 abbyhu2000 added bug Something isn't working untriaged data explorer Issues related to the Data Explorer project de-angular de-angularize work labels Sep 19, 2023
@ananzh ananzh self-assigned this Sep 20, 2023
@ananzh ananzh added v2.11.0 and removed untriaged labels Sep 20, 2023
ananzh added a commit to ananzh/OpenSearch-Dashboards that referenced this issue Sep 21, 2023
Issue Resolve
opensearch-project#5068

Signed-off-by: ananzh <ananzh@amazon.com>
@ananzh
Copy link
Member

ananzh commented Sep 21, 2023

This error is due to chartData is undefined (no histogram chart and interval) for not time based data. So if (!hits || !chartData || !bucketInterval) return null; in src/plugins/discover/public/application/view_components/canvas/discover_chart_container.tsx will return null even we have data.

This issue is actually captured and fixed in #4821
but this line if (!hits || !chartData || !bucketInterval) return null; is reversed in PR #5029 😆

If we don't like

return (
    hits && (
      <DiscoverChart
        bucketInterval={bucketInterval}
        chartData={chartData}
        config={uiSettings}
        data={data}
        hits={hits}
        resetQuery={() => {
          window.location.href = `#/view/${savedSearch?.id}`;
          window.location.reload();
        }}
        services={services}
        showResetButton={!!savedSearch && !!savedSearch.id}
        isTimeBased={isTimeBased}
      />
    )
  );

we could simplify if (!hits || !chartData || !bucketInterval) return null; to if (!hits) return null; which could also fix the problem.

ananzh added a commit to ananzh/OpenSearch-Dashboards that referenced this issue Sep 21, 2023
Issue Resolve
opensearch-project#5068

Signed-off-by: ananzh <ananzh@amazon.com>
ananzh added a commit to ananzh/OpenSearch-Dashboards that referenced this issue Sep 21, 2023
Issue Resolve
opensearch-project#5068

Signed-off-by: ananzh <ananzh@amazon.com>
@ananzh ananzh closed this as completed in a10f1c7 Sep 22, 2023
opensearch-trigger-bot bot pushed a commit that referenced this issue Sep 22, 2023
Issue Resolve
#5068

Signed-off-by: ananzh <ananzh@amazon.com>
(cherry picked from commit a10f1c7)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

# Conflicts:
#	CHANGELOG.md
abbyhu2000 pushed a commit that referenced this issue Sep 26, 2023
Issue Resolve
#5068

Signed-off-by: ananzh <ananzh@amazon.com>
(cherry picked from commit a10f1c7)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

# Conflicts:
#	CHANGELOG.md

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Josh Romero <rmerqg@amazon.com>
Co-authored-by: Kawika Avilla <kavilla414@gmail.com>
kavilla pushed a commit to opensearch-project/opensearch-dashboards-functional-test that referenced this issue Oct 13, 2023
Migrate the old selenium tests for discover to cypress tests for data explorer.
PR [for #5003](opensearch-project/OpenSearch-Dashboards#5072) needs to be merged first.

Below are a list of bugs found when writing the tests, the tests for the below feature are skipped and commented with the issue link:

- opensearch-project/OpenSearch-Dashboards#5071
- opensearch-project/OpenSearch-Dashboards#5068
- opensearch-project/OpenSearch-Dashboards#5058
- opensearch-project/OpenSearch-Dashboards#5057
- opensearch-project/OpenSearch-Dashboards#5056

### Issues Resolved
resolves opensearch-project/OpenSearch-Dashboards#4781

---------

Signed-off-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com>
opensearch-trigger-bot bot pushed a commit to opensearch-project/opensearch-dashboards-functional-test that referenced this issue Oct 13, 2023
Migrate the old selenium tests for discover to cypress tests for data explorer.
PR [for #5003](opensearch-project/OpenSearch-Dashboards#5072) needs to be merged first.

Below are a list of bugs found when writing the tests, the tests for the below feature are skipped and commented with the issue link:

- opensearch-project/OpenSearch-Dashboards#5071
- opensearch-project/OpenSearch-Dashboards#5068
- opensearch-project/OpenSearch-Dashboards#5058
- opensearch-project/OpenSearch-Dashboards#5057
- opensearch-project/OpenSearch-Dashboards#5056

### Issues Resolved
resolves opensearch-project/OpenSearch-Dashboards#4781

---------

Signed-off-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com>
(cherry picked from commit 7cf0a03)
opensearch-trigger-bot bot pushed a commit to opensearch-project/opensearch-dashboards-functional-test that referenced this issue Oct 13, 2023
Migrate the old selenium tests for discover to cypress tests for data explorer.
PR [for #5003](opensearch-project/OpenSearch-Dashboards#5072) needs to be merged first.

Below are a list of bugs found when writing the tests, the tests for the below feature are skipped and commented with the issue link:

- opensearch-project/OpenSearch-Dashboards#5071
- opensearch-project/OpenSearch-Dashboards#5068
- opensearch-project/OpenSearch-Dashboards#5058
- opensearch-project/OpenSearch-Dashboards#5057
- opensearch-project/OpenSearch-Dashboards#5056

### Issues Resolved
resolves opensearch-project/OpenSearch-Dashboards#4781

---------

Signed-off-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com>
(cherry picked from commit 7cf0a03)
kavilla pushed a commit to opensearch-project/opensearch-dashboards-functional-test that referenced this issue Oct 13, 2023
Migrate the old selenium tests for discover to cypress tests for data explorer.
PR [for #5003](opensearch-project/OpenSearch-Dashboards#5072) needs to be merged first.

Below are a list of bugs found when writing the tests, the tests for the below feature are skipped and commented with the issue link:

- opensearch-project/OpenSearch-Dashboards#5071
- opensearch-project/OpenSearch-Dashboards#5068
- opensearch-project/OpenSearch-Dashboards#5058
- opensearch-project/OpenSearch-Dashboards#5057
- opensearch-project/OpenSearch-Dashboards#5056

### Issues Resolved
resolves opensearch-project/OpenSearch-Dashboards#4781

---------

Signed-off-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com>
(cherry picked from commit 7cf0a03)

Co-authored-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com>
kavilla pushed a commit to opensearch-project/opensearch-dashboards-functional-test that referenced this issue Oct 13, 2023
Migrate the old selenium tests for discover to cypress tests for data explorer.
PR [for #5003](opensearch-project/OpenSearch-Dashboards#5072) needs to be merged first.

Below are a list of bugs found when writing the tests, the tests for the below feature are skipped and commented with the issue link:

- opensearch-project/OpenSearch-Dashboards#5071
- opensearch-project/OpenSearch-Dashboards#5068
- opensearch-project/OpenSearch-Dashboards#5058
- opensearch-project/OpenSearch-Dashboards#5057
- opensearch-project/OpenSearch-Dashboards#5056

### Issues Resolved
resolves opensearch-project/OpenSearch-Dashboards#4781

---------

Signed-off-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com>
(cherry picked from commit 7cf0a03)

Co-authored-by: Qingyang(Abby) Hu <abigailhu2000@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working data explorer Issues related to the Data Explorer project de-angular de-angularize work v2.11.0
Projects
None yet
Development

No branches or pull requests

2 participants