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

Revert "Remove head 10 for PPL default query to unblock cypress test #8922

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

abbyhu2000
Copy link
Member

@abbyhu2000 abbyhu2000 commented Nov 25, 2024

Description

This reverts commit aa60870.

Issues Resolved

Screenshot

Testing the changes

Changelog

  • fix: revert remove head 10 commit

Check List

  • All tests pass
    • yarn test:jest
    • yarn test:jest_integration
  • New functionality includes testing.
  • New functionality has been documented.
  • Update CHANGELOG.md
  • Commits are signed per the DCO using --signoff

Copy link
Contributor

❌ Empty Changelog Section

The Changelog section in your PR description is empty. Please add a valid changelog entry or entries. If you did add a changelog entry, check to make sure that it was not accidentally included inside the comment block in the Changelog section.

Copy link

codecov bot commented Nov 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 60.88%. Comparing base (539675e) to head (3531a37).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #8922   +/-   ##
=======================================
  Coverage   60.88%   60.88%           
=======================================
  Files        3802     3802           
  Lines       91070    91070           
  Branches    14374    14374           
=======================================
+ Hits        55444    55446    +2     
+ Misses      32085    32083    -2     
  Partials     3541     3541           
Flag Coverage Δ
Linux_1 29.02% <ø> (ø)
Linux_2 56.39% <ø> (ø)
Linux_3 37.90% <ø> (ø)
Linux_4 29.00% <ø> (+<0.01%) ⬆️
Windows_1 29.03% <ø> (ø)
Windows_2 56.34% <ø> (ø)
Windows_3 37.90% <ø> (-0.01%) ⬇️
Windows_4 29.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sejli
Copy link
Member

sejli commented Nov 27, 2024

Seeing the following error in the logs:

[22:35:50.575] [error][plugins][queryEnhancements] Facet fetch: enhancements.pplQuery: Bad Request :: {"path":"/_plugins/_ppl","query":{},"body":"{\"query\":\"source = timestamp-*  | where `timestamp` >= '2018-09-19 13:31:44' and `timestamp` <= '2019-09-24 01:31:44' | head 10 | stats count() by span(timestamp, 1w)\"}","statusCode":400,"response":"{\n  \"error\": {\n    \"reason\": \"Invalid Query\",\n    \"details\": \"Cannot invoke \\\"java.lang.Comparable.compareTo(Object)\\\" because \\\"k1\\\" is null\",\n    \"type\": \"NullPointerException\"\n  },\n  \"status\": 400\n}"}

I'm not sure if this is what is causing the test to fail, but I double checked that this query should work by ingesting the data from here and trying out the request in dashboards-query-workbench. It seems to work fine there. I created the index pattern and tested in Discover but saw the following in my error logs when I tried source = timestamp-* | head 10 | stats count() by span(timestamp, 1w):

[error][plugins][queryEnhancements] Facet fetch: enhancements.pplQuery: Bad Request :: {"path":"/_plugins/_ppl","query":{},"body":"{\"query\":\"source = timestamp-*   | where `timestamp` >= '2018-09-09 20:31:44' and `timestamp` <= '2019-09-09 08:31:44' | head 10 | stats count() by span(timestamp, 1w) | stats count() by span(timestamp, 1w)\"}","statusCode":400,"response":"{\n  \"error\": {\n    \"reason\": \"Invalid Query\",\n    \"details\": \"invalid to get timestampValue from value of type UNDEFINED\",\n    \"type\": \"ExpressionEvaluationException\"\n  },\n  \"status\": 400\n}"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants