Skip to content

Fix Failing test: Service map embeddable#267540

Merged
sbelastic merged 12 commits into
elastic:mainfrom
sbelastic:265639-fix-service-map-embeddable-test
May 6, 2026
Merged

Fix Failing test: Service map embeddable#267540
sbelastic merged 12 commits into
elastic:mainfrom
sbelastic:265639-fix-service-map-embeddable-test

Conversation

@sbelastic
Copy link
Copy Markdown
Contributor

@sbelastic sbelastic commented May 4, 2026

Closes #265639

Summary

  • Fix Service map embeddable
  • Changed things in apex QA files to give us the option to use custom timeouts, a number of the crashes was because the current hardcoded timeouts aren't enough to pass in the CI (examples: Comment 1, Comment 2, Comment 3)

Ran against ECH environment

image

How to run

Server

node scripts/scout.js start-server --arch stateful --domain classic

Client

npx playwright test --project local --ui --config x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts

On ECH

npx playwright test --project=ech --ui --config x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts

Checklist

@sbelastic sbelastic self-assigned this May 4, 2026
@sbelastic sbelastic added release_note:skip Skip the PR/issue when compiling release notes backport:skip This PR does not require backporting workstream:apm presentation labels May 4, 2026
@macroscopeapp
Copy link
Copy Markdown
Contributor

macroscopeapp Bot commented May 4, 2026

Catch flakiness early (recommended): run the flaky test runner against this PR before merging.

This PR unskips a previously-failing test suite (service_map_embeddable.spec.ts, ref #265639) and adds new timeout overrides and async interactions, so 30× runs help validate stability.

Trigger a run with the Flaky Test Runner UI or post this comment on the PR:

/flaky scoutConfig:x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts:30

Share feedback in the #appex-qa channel.

Posted via Macroscope — Flaky Test Runner nudge

@kibanamachine
Copy link
Copy Markdown
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#12093

[✅] x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts (--arch stateful --domain classic): 50/50 tests passed.
[✅] x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts (--arch serverless --domain observability_complete): 50/50 tests passed.

see run history

@sbelastic sbelastic marked this pull request as ready for review May 5, 2026 07:50
@sbelastic sbelastic requested review from a team as code owners May 5, 2026 07:50
@botelastic botelastic Bot added the Team:obs-presentation Focus: APM UI, Infra UI, Hosts UI, Universal Profiling, Obs Overview and left Navigation label May 5, 2026
@infra-vault-gh-plugin-prod
Copy link
Copy Markdown

Pinging @elastic/obs-presentation-team (Team:obs-presentation)

@macroscopeapp
Copy link
Copy Markdown
Contributor

macroscopeapp Bot commented May 5, 2026

Approvability

Verdict: Needs human review

Unresolved review comments raise substantive concerns: one questions whether the fix addresses the actual root cause and requests verification on ECH deployment, another identifies a TypeScript type bug where useFill is missing from the selectSingleOption options type. Additionally, the author does not own any of the modified files.

No code changes detected at 310dea3. Prior analysis still applies.

You can customize Macroscope's approvability policy. Learn more.

await this.page.gotoApp('dashboards', { hash: '/create' });
await expect(this.addTopNavButton).toBeVisible({ timeout: 20_000 });
await expect(this.addTopNavButton).toBeVisible({ timeout: options?.timeout ?? 20_000 });
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I believe this is not the main issue with the test:

Image

Could be that in Cloud typing Service name causes warning and affects the next steps?

I believe running flaky-test-runner against Kibana local servers doesn't really help to verify the fix. Please run the test against ECH deployment to confirm the issue is fixed.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Could be that in Cloud typing Service name causes warning and affects the next steps?

Yes, this would break things.

A quick overview of the changes is:

  • Increase timeout from 20 seconds to 45 seconds because, running locally against an ECH environment over 30 times, one of them it got to the 20 second timeout
  • Added an explicit closing of a popup that caused some flakiness
  • [Newest change] Added an option to fill the search input instead of pressing each key (reduced the flakiness A LOT)

Not directly related to the test, more code related, but added the option for other parts of the same files to have a custom timeout or to use fill instead of type for future tests.

Note: Added photo of ECH test passing (did a commit afterwards because the date input is not the same locally vs ECH, everything else is the same and should pass)

Copy link
Copy Markdown
Contributor

@dmlemeshko dmlemeshko left a comment

Choose a reason for hiding this comment

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

Keeping approve back before ECH run confirmation since we might increase timeout without good reason (45 sec even for ECH is too much)

@sbelastic
Copy link
Copy Markdown
Contributor Author

/oblt-deploy

@kibanamachine
Copy link
Copy Markdown
Contributor

Flaky Test Runner Stats

🟠 Some tests failed. - kibana-flaky-test-suite-runner#12103

[❌] x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts (--arch stateful --domain classic): 0/50 tests passed.
[❌] x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts (--arch serverless --domain observability_complete): 0/50 tests passed.

see run history

@kibanamachine
Copy link
Copy Markdown
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#12105

[✅] x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts (--arch stateful --domain classic): 50/50 tests passed.
[✅] x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts (--arch serverless --domain observability_complete): 50/50 tests passed.

see run history

@sbelastic sbelastic requested a review from dmlemeshko May 5, 2026 13:32
Copy link
Copy Markdown
Member

@jennypavlova jennypavlova left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for fixing the test!

@sbelastic sbelastic enabled auto-merge (squash) May 6, 2026 13:00
@kibanamachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/scout 226 227 +1
@kbn/scout-oblt 255 256 +1
@kbn/scout-search 226 227 +1
@kbn/scout-security 246 247 +1
total +4
Unknown metric groups

API count

id before after diff
@kbn/scout 698 699 +1
@kbn/scout-oblt 706 707 +1
@kbn/scout-search 666 667 +1
@kbn/scout-security 686 687 +1
total +4

History

cc @sbelastic

@sbelastic sbelastic merged commit 2dbea04 into elastic:main May 6, 2026
30 checks passed
ersin-erdal pushed a commit to ersin-erdal/kibana that referenced this pull request May 6, 2026
Closes elastic#265639

## Summary

- Fix Service map embeddable
- Changed things in apex QA files to give us the option to use custom
timeouts, a number of the crashes was because the current hardcoded
timeouts aren't enough to pass in the CI (examples: [Comment
1](elastic#265639 (comment)),
[Comment
2](elastic#265639 (comment)),
[Comment
3](elastic#265639 (comment)))


### Ran against ECH environment

<img width="1918" height="1134" alt="image"
src="https://github.com/user-attachments/assets/de731bbf-2825-420f-bd29-6bb0baae5887"
/>


### How to run

#### Server

`node scripts/scout.js start-server --arch stateful --domain classic`

#### Client

`npx playwright test --project local --ui --config
x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts`


#### On ECH

`npx playwright test --project=ech --ui --config
x-pack/solutions/observability/plugins/apm/test/scout/ui/parallel.playwright.config.ts`

### Checklist

- [x] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed [(last successful
run)](elastic#267540 (comment))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:obs-presentation Focus: APM UI, Infra UI, Hosts UI, Universal Profiling, Obs Overview and left Navigation v9.5.0 workstream:apm presentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Failing test: Service map embeddable - adds Service map panel with service name, environment and KQL filter

4 participants