Commit Graph
95 Commits
Author SHA1 Message Date
Neha P eee507d403 test(general): reach Running Queries as the meta org before asserting the SQL tooltip (#15411) 2026-10-15 12:16:36 +00:00
Bhargav a32db1cd6d fix(web): keep the table cut-off tooltip anchored while it fades out (#15308) 2026-10-14 17:05:11 +08:00
Shrinath Rao 988ab817e6 test: heal 3 Logs regression specs broken by #15234 (#15326) 2026-10-14 04:27:00 +00:00
Hengfei Yang 180daa0aa6 feat(alerts): allow saving an alert with no destination (#15267) 2026-10-13 17:40:49 +08:00
Neha P 0481175c3a fix(logs): keep VRL-derived fields out of the quick-mode SELECT (#15246) 2026-10-09 13:33:53 +00:00
Vamsi Karthik R d7a46e2cc2 test: fix the stale Traces and RUM Bug-Fix Regression specs behind #15177 (#15221) 2026-10-09 03:37:00 +00:00
07e159549d fix(alerts): ask which query mode to save and fix stale edit data (#15090)
Co-authored-by: Neha P <neha@openobserve.ai>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-10-08 17:51:57 +00:00
Vamsi Karthik R 92a62c2d6c test(rum): end-to-end coverage for Product Analytics and its schema-state fixes (#15131) 2026-10-07 10:05:59 +00:00
ktx-akshay 2819871e09 test: E2E regression coverage for variables sharing a name prefix (#14479) (#15165) 2026-10-07 09:58:19 +00:00
Vamsi Karthik R 5eff5b2a30 test(traces): regression coverage for the search window and error state fixes in #15130 (#15136) 2026-10-07 04:35:37 +00:00
Omkar Kesarkhane 7d70a13e02 fix(rum): search a session's traces by server arrival time when it has no replay (#15106) 2026-10-05 16:55:23 +00:00
Neha P 11e569ff1c fix(functions): stop offering a body fix-up for failures it cannot fix (#15069) 2026-10-05 09:54:47 +00:00
Neha P 5cd1d86469 fix(functions): repair an import fix-up that could not write, with E2E + API coverage (#15043) 2026-10-02 07:41:47 +00:00
Neha P ee32552c6f test(regression): cover 11 closed logs, streams, pipeline and enrichment bugs (#14978) 2026-09-30 09:30:33 +00:00
5fcf871ccd test(autoe2e): generated E2E tests for #14796 (alert-destination-usage) (#14850)
Co-authored-by: Shrinath-O2 <214651540+Shrinath-O2@users.noreply.github.com>
Co-authored-by: Vamsi Karthik R <vkarthik@openobserve.ai>
2026-09-29 13:01:00 +00:00
Vamsi Karthik R 1b50f7ca0a test: regression coverage for retested bug fixes (#14376, #14317, #14648, #11283, #14636, #14640, #14917) (#14927) 2026-09-28 19:46:23 +00:00
Neha P db61c88aa6 test(regression): cover 10 closed logs, pipeline and enrichment bugs (#14932) 2026-09-28 13:33:31 +00:00
Vamsi Karthik R 33c0239410 test: cover the bug fixes confirmed by retest, and drop the #13243 workarounds (#14842) 2026-09-27 19:35:38 +00:00
Neha P 0cbdb03dc2 test: regression coverage for 29 closed Needs-Automation issues (#14883) 2026-09-25 12:42:57 +00:00
Neha P fab9cabace test: regression coverage for 4 closed Needs-Automation issues (#14873) 2026-09-24 16:12:38 +00:00
Neha P 8276fef44f test: regression coverage for 5 closed Needs-Automation issues (#14847) 2026-09-24 09:56:48 +00:00
Bhargav 1dc8a255c4 test: LLM provider type & API key handling regression (o2-enterprise#2598) (#14435) 2026-09-23 08:27:13 +00:00
ktx-akshay b4c7df2342 test: cover dashboard panel cache retention on browser refresh (#14699) 2026-09-22 10:28:38 +00:00
Bhargav c8184b3101 fix(tests): give each realtime pipeline its own source stream (#14731) 2026-09-22 09:08:04 +00:00
Neha P 80d9d6ff91 test: regression coverage for 4 closed Needs-Automation bugs, and repair the alert wizard's stream select (#14689) 2026-09-21 12:17:22 +00:00
ktx-akshay 8f7d795416 test: add regression for importing a dashboard with panel layout.i = 0 (#14442) 2026-09-21 06:31:40 +00:00
Shrinath Rao b2e058a202 test: regression coverage for 4 Needs-Automation issues (1 API + 3 Logs UI regression) (#14538) 2026-09-21 06:14:44 +00:00
Neha P 8dcaf5e8e8 test: cover report folders (#11219) and the incident status filter (#12611) (#14646) 2026-09-20 08:33:59 +00:00
Neha P b607d0a623 fix(alerts): repair three clone-dialog bugs, and cover the clone surface (#14621) 2026-09-18 14:44:18 +00:00
Neha P 5452617373 test: regression coverage for 9 closed Needs-Automation bugs, and harden the stream-select and query-editor page objects (#14550) 2026-09-16 17:35:56 +00:00
Bhargav 69cf2422ed test: composite alerts regression coverage (o2-enterprise#2598) (#14433) 2026-09-16 09:50:37 +00:00
Neha P 0104b53ffe test: regression coverage for 10 closed Needs-Automation bugs, and rebalance the Logs shard (#14494) 2026-09-16 08:07:59 +00:00
90a40867ed fix(metrics): give a settled-empty Explorer card one bounded recheck (#14465)
Co-authored-by: Neha P <neha@openobserve.ai>
Co-authored-by: ktx-vaidehi <vaidehi.akhani@kiara.tech>
2026-09-14 10:20:36 +00:00
Neha P af07d66c52 test: run the Search History regression from the ENT matrix only (#14436) 2026-09-11 07:03:58 +00:00
Omkar Kesarkhane 94047dc0b7 fix: render streaming aggregation results as they arrive (#14303) (#14324) 2026-09-09 13:27:26 +00:00
Neha P 6b6572f8e8 fix(logs): retain the query re-applied from Search History (#14286) 2026-09-09 06:42:55 +00:00
Neha P 8ef549c3e3 test: cover builder saved views applied on the build tab (#14245) 2026-09-07 17:34:18 +00:00
Neha PandShrinath Rao 758793481e test(logs): cover multi-stream match_all pagination (#14108)
Co-authored-by: Shrinath Rao <shnath@openobserve.ai>
2026-09-02 13:19:26 +00:00
Shrinath Rao 2834186b8a test(e2e/alpha1): unique per-run alert destination/template so Add Alert button enables (#13783)
## Why

After #13776 merged, the alpha1 **RegressionSet** shard still failed —
but on a **new, different** cause than #13776 fixed. All 4
`alerts-regression` tests died at the very first step
(`clickAddAlertButton`) because the button was **disabled**:

```
<button disabled aria-disabled="true"
        title="No destinations available"
        data-test="alert-list-add-alert-btn">
19 × locator resolved to disabled  → toBeEnabled() timed out after 15s
```

## Root cause (reproduced live on the RegressionSet org, auto_org_2)

[`AlertList.vue`](web/src/components/alerts/AlertList.vue#L51) disables
the Add Alert button while `destinations.length === 0`:
```vue
:disabled="!destinations.length || !templates.length"
:title="!destinations.length ? t('alerts.noDestinations') : ''"
```

On the **shared** cloud org the **fixed** names `e2e_promql_dest` /
`e2e_promql_template` were stuck ghost records — a concurrent run's
cleanup couldn't fully delete them (UI delete timed out /
`destinations_templates_fk` 500). So the beforeAll create returned `400
"already exists"`, yet the destinations list loaded **empty**, keeping
the button disabled through the 15s `toBeEnabled` wait. Not a product
regression — the org simply had no *loadable* destination.

This is the same **shared-org fixed-name collision** class fixed for
streams in #13776.

## Fix

- `e2e_promql_dest` / `e2e_promql_template` → `..._<RUN_TOKEN>` (unique
per run), so the beforeAll always creates a real, loadable destination.
Keeps the `e2e_promql_` prefix so `cleanup.spec.js` still reclaims them.
- Gate the beforeAll on the destination actually appearing in the
`/alerts/destinations` list API before tests run, so the button is
reliably enabled (`destinations.length > 0`) instead of racing the
fetch.

## Verification (alpha, RegressionSet org auto_org_2 — reproduced 100%
before)

- Before: `Add Alert` disabled → `toBeEnabled` 15s timeout → 4/4 fail.
- After: `Destination confirmed in list API | e2e_promql_dest_<token>` →
button enabled → **alerts-regression 5/5 pass** (#9967, #10899, #10872,
#10110, #10472); alerts saved for both `>=` and `<=`.

## Scope
OSS-only test file. Picked up by the ENT alpha1 workflow the same way as
#13776 (checks out opensource `main`, or dispatch with
`o2_opensource_repo=test/alerts-regression-destinations-gate`).
2026-08-12 11:57:01 +00:00
Shrinath Rao 6650950a50 test(e2e/alpha1): fix share-link redirect origin and cloud metrics ingest auth (#13776)
## Why

The scheduled **Alpha1 (Cloud)** e2e run failed on three jobs
([o2-enterprise run
31547517666](https://github.com/openobserve/o2-enterprise/actions/runs/31547517666)):
**Logs-Features** (7), **Functions** (11), **RegressionSet** (4).
Root-caused each against a freshly-deployed alpha; two are genuine test
heals, one was pure environment skew.

## Root causes & fixes

### 1. Logs-Features — shareLink + monaco-query-prefill (7 tests) ✅
fixed
On cloud the app builds the share link from its **public** base URL
(`*.external.zinclabs.dev`), while the tests authenticate against the
ingress host (`*.internal.zinclabs.dev`). `page.goto(sharedUrl)`
navigated **cross-origin**, dropped the auth cookies, and bounced to Dex
— so every post-redirect state assertion read back `null`.

**Fix:** re-point the short URL's origin to `ZO_BASE_URL` in
`clickShareLinkAndGetUrl()` (right next to the existing HTTP→HTTPS
"maintain auth context" step). `/short/<id>` resolves identically on the
backend regardless of ingress host, so only the origin changes and the
session stays valid. Same-origin envs (localhost / matching deployed
host) are untouched.

### 2. RegressionSet — alerts Bug #9967 PromQL (1 test) ✅ fixed
`ingestMetricsData()` authenticated with `ZO_ROOT_USER_EMAIL:PASSWORD`,
but **cloud ingestion needs `email:passcode`**. The ingest silently
401'd → the `e2e_test_cpu_usage` metrics stream was never created → the
PromQL alert flow timed out selecting it.

**Fix:** build auth via `getAuthHeaders()` (passcode on cloud, root
creds on self-hosted), refresh the passcode from the live browser
session first, and poll until the stream is indexed so the wizard's
stream-select doesn't race WAL lag.

### 3. Functions — radio → segmented toggle (11 tests) — no change
needed
The page object was already migrated to the segmented toggle in #13766;
these failures were the **alpha frontend lagging the merged test code**.
Green after the redeploy with zero code change.

## Verification (against alpha, `auto_org_1`)
- `shareLink.spec.js` + `monaco-query-prefill.spec.js` → **11/11
passed**
- `alerts-regression.spec.js` (full) → **5/5 passed** (#9967, #10110,
#10899, #10872, #10472)
- `Functions/js-transform-type.spec.js` → **7/7**,
`row-expansion.spec.js` → green

## Scope
OSS-only (test files). The ENT `playwright_alpha1.yml` checks out
opensource at `main`, so merging makes the next scheduled run pick this
up. It can also be pre-verified by dispatching that workflow with
`o2_opensource_repo=test/alpha1-e2e-heals-0812`.
2026-08-12 06:35:48 +00:00
Shrinath Rao cb78ef36fd test(sentinel): complete POM compliance — Dashboards + Correlation (follow-up to #13727) (#13735)
## Summary

Completes the Sentinel **Page Object Model** compliance sweep of the
Playwright suite (follow-up to #13727, which covered the non-Dashboards
shards). Every raw `page.locator(...)` / `page.getBy*(...)` selector —
in **actions and assertions** — is relocated out of the spec files into
the relevant page object; specs now call page-object methods/getters
only.

**Result: 0 raw fixture-`page` selectors across the entire
`playwright-tests` suite** (single-line *and* multi-line, verified with
a dotall/multiline scanner). Together with #13727, the whole suite is
POM-clean.

## What's in this PR

**Dashboards shards — ~1,460 selectors** relocated into their page
objects (`dashboard-panel-configs/actions/edit/time`, `dashboard-chart`,
`dashboard-variables-scoped`, `dashboard-filter`, `dashboard-drilldown`,
`crossLinkPage`, `visualise`, `dashboard-share-export`,
`dashboard-create`, `dashboard-settings`, `dashboard-variables`):

| Shard | selectors |
|-------|----------:|
| Dashboard-Config-Settings (11 specs) | ~255 |
| Dashboards-Variables (12 specs, 4 batches) | ~693 |
| Dashboards-Tables (7 specs) | ~127 |
| Dashboards-Charts (9 specs) | ~81 |
| Dashboards-Core + Visualize (10 specs) | ~144 |
| Dashboards-Settings + Panel-DateTime (8 specs) | ~107 |
| Dashboard-Regression (1 spec) | ~52 |

**Correlation UI specs** (3 new `Correlation/*.ui.spec.js` that arrived
via main's merge, after the original audit) — converted into a new
`correlationDrawerPage` + an extended `correlationSettingsPage`, with
`PageManager` wired into specs that previously used none.

**Audit stragglers** the original **single-line** audit grep
undercounted — multi-line `page\n.locator(...)` chains in
`logstable.spec.js` (→ `logsPage.getTableHeaderByField()`) and
`dashboard-streaming.spec.js` (2 add-panel selectors).

**AI-review fixes** (DeepSeek, on this PR) — removed 2 dead-code
duplicate getters + 1 redundant method alias (merge artifacts from the
sequential batch commits).

One Node-context `console.log` (`dashboard-general-setting`'s
`beforeEach`) → `testLogger.info`.

## Approach

Nearly every Dashboards spec shares the same page objects, so the work
was done in **sequential batches** (one committed, verified unit at a
time) to keep page-object edits conflict-free. 13 commits, mapping 1:1
to those batches.

## Not changed (by design)

- **`waitForTimeout`** left as-is — logged in the audit, not rewritten
(per direction).
- **Browser-context code inside `page.evaluate()` /
`waitForFunction()`** (`document.querySelector`, `window.*`) left as-is
— it runs in the page's JS engine, not Node, so `testLogger` (a Node
module) can't be called there. *No `console.*` remained in dashboards
specs*; the Node-context ones were converted to `testLogger`.
- **`newPage.locator(...)`** on separate popup `Page` instances left
as-is (not the fixture `page`).

## Verification

- **0 raw fixture-`page` selectors** across all specs — single- and
multi-line, comments stripped.
- All changed `.js` files pass `node --check`.
- **CI-gated** for browser execution (no local runs), consistent with
#13727. The enterprise E2E crosscheck already passed against this PR.

## Stats

82 files changed (+3,355 / −2,211) — 61 specs, 21 page objects.
Selectors **moved into page objects, not deleted**.
2026-08-11 06:09:06 +00:00
Shrinath Rao 82d14e8458 test(sentinel): POM compliance across Playwright suite (non-Dashboards) (#13727)
## What & why

Sentinel (Council of Agents) audit-driven **Page Object Model
compliance** across the Playwright suite. Many specs (a lot added
recently, some AI-generated) had raw `page.locator(...)` /
`page.getBy*(...)` selectors directly in spec files — including inside
`expect(...)` — which the Sentinel flags as CRITICAL. This PR relocates
those selectors into their page objects and calls page-object
methods/getters instead.

A full audit of **all 256 specs** was generated first (stored locally
under `tests/ui-testing/MD_Files/sentinel-audit-2026-08-10/`, which is
gitignored). Original totals: **1,609** raw selectors, **190** inside
assertions, plus console/testLogger items.

## Scope of THIS PR (non-Dashboards)

Every non-Dashboards spec is now **100% raw-selector clean** (verified:
0 occurrences). Shards covered:

- **GeneralTests, Logs (Core/Builder-Advanced/Features/Regression),
Traces (+Reg), Streams (+Reg), Metrics (+Reg), Pipelines, Reports
(+Reg), Anomaly, Login/auth, auth-warm, and the unmatched Alerts
specs.**
- `console.*` → `testLogger` where it was Node-context (kept `console.*`
**inside `page.evaluate()`** — that's browser context; `testLogger`
doesn't exist there).
- `testLogger` import/use added where missing.
- **`waitForTimeout` intentionally left as-is** (logged in the audit,
not rewritten — per direction).

## Deferred to a follow-up PR

The **heavy Dashboards shards** (Variables 693, Config-Settings 255,
Tables 127, Charts 81, Core 79, Visualize 65, Settings 52,
Panel-DateTime 55, Dashboard-Regression 52 raw selectors) are **not** in
this PR — they're the bulk of the work and will be a separate, focused
pass. (dashboard-streaming console cleanup is included here.)

## Verification

Fixes were applied and executed **shard by shard** against a local env,
gated green before commit where the env allowed:

| Group | Local result |
|-------|--------------|
| GeneralTests (edited specs) | 52 passed / 11 skipped / 0 failed |
| Logs (shareLink, logsQuickPick, indexquery) | 21 passed |
| Traces / Streams / Metrics | 49 passed / 2 skipped / 0 failed |
| Pipelines | 56 passed / 17 skipped / 0 failed |
| logs-bugs :548, dashboard-streaming | verified not regressed
(isolation) |

**Alerts create-wizard specs** (Alerts shard, Alerts-Regression,
unmatched Alerts) could not be gated locally — the alert-creation
wizard's stream popover times out on this env **on unmodified code too**
(reproduced on original, test `:363`), so those refactors are 1:1
selector→method mappings, syntax-clean (`node --check`), and rely on CI
to gate.

Every changed `.js` passes `node --check`. `waitForTimeout` unchanged;
no behavior changes intended.

## Stats
51 files changed. Selectors moved into page objects, not deleted.
2026-08-10 15:30:21 +00:00
Shrinath Rao 7ab93c04d5 test(reports): heal reports-regression timezone spec (edit-prefill race + toast selector) (#13724)
## What

Heals the Reports regression spec `reports-regression-bugs.spec.js` →
*"Report save should not shift timestamp by timezone offset"*
(@bug-11231), which was failing deterministically (all 4 retries) in
both the OSS and ENT **Playwright Regression** runs:

- OSS:
https://github.com/openobserve/openobserve/actions/runs/31364820545
- ENT:
https://github.com/openobserve/o2-enterprise/actions/runs/31364817885

This is **test-only** — the product is unaffected (the historical #11231
fix and normal report save both work; a save actually succeeds in the
failing run).

## Root cause (two independent defects)

1. **Wrong success-toast selector (deterministic line-118 failure).**
The save assertion used `page.getByRole('alert')`. `OToast` renders the
**success** variant with `role="status"` — only **error/warning** toasts
get `role="alert"`
([`OToast.vue`](https://github.com/openobserve/openobserve/blob/main/web/src/lib/feedback/Toast/OToast.vue)
`rootRole`). So the assertion could never match a successful save and
timed out. → now asserts on the success toast
`[data-test-variant="success"]`, consistent with the rest of the file.

2. **Edit-prefill race (line-84 failure, the one captured in the
trace).** On the edit flow, step-1 `Continue` could fire before the
async edit prefill (`form.reset()` after the report GET) populated
folder/dashboard/tabs. `goToStep()` then failed validation and silently
stayed on step 1, so the schedule toggle never rendered and the test
timed out looking for it. → `createReportContinueButtonStep1()` now
retries the click until the schedule step is actually reached,
**keeping** the original post-advance settle so downstream step-2
interactions (schedule-later toggle, step-2 Continue) don't race.

Also dedups the spec's inline date/time entry through the existing
`createReportDateTime()` helper (logic unchanged).

## Verification (local, `localhost:5080`)

| Suite | Result |
|---|---|
| `reports-regression-bugs.spec.js` (target) | ✅ stable across repeated
runs (1 + 3× repeat-each) |
| `reportsScheduleLater.spec.js` | ✅ 6/6 |
| `reportsScheduleNow.spec.js` + `reportCsvMediaType.spec.js` | ✅ 13/13
|

The two changed page-object methods are shared with the sibling Reports
specs above; all pass, confirming no regression.

## Scope

The spec lives in OSS `tests/` and is tree-merged into the ENT
regression run, so this single OSS change fixes both pipelines. No ENT
repo change required; the ENT regression will be re-triggered against
this branch.
2026-08-10 11:27:25 +00:00
Prabhat Sharma 087e1498ab feat(slos): add SLO burn-rate alerts (#13704)
design at /slo

## What

Adds **SLO burn-rate alerts** — an alert family that fires off an SLO's
error budget rather than a raw query — and finishes the SLO surface
around it: navigation entry, detail-page fixes, and the flag removal now
that SLOs have shipped.

## Changes

**SLO burn-rate alerts (backend)**
- New burn-rate evaluation (`config/src/meta/slo/burn.rs`,
`condition.rs`) with multi-window burn conditions, and
`core/src/slo/evaluate.rs` extended to evaluate them on the SLO job.
- Alerts carry an `slo_id`; `infra/src/table/alerts` gains the column,
filtering, and query support so an SLO's alerts can be listed and
deleted with it.
- Alert levels (`meta/alerts/level.rs`) and tags extended for the SLO
family; scheduler handlers route SLO alerts through the same
notification path.

**SLO alert UI**
- `SloAlertForm` + `AlertDetailSlo`: create, edit and view burn-rate
alerts from the SLO detail page and the alert list.
- Payload/routing helpers (`utils/alerts/sloAlertPayload.ts`,
`sloAlertRouting.ts`, `alertPayload.ts`) with unit tests.
- `AlertDestinationsField` extracted as the complete Destination form
field — side label, tooltip, combined destinations/workflows picker,
inline error, refresh, and create-in-new-tab. It replaces two verbatim
copies in the generic alert form and is reused by the SLO form and
synthetics `CheckAlerts` (which sets `supportsWorkflows: false`, since a
check has no workflow routing). Fixes the SLO form's previously unwired
refresh and Add Destination buttons.

**SLO detail page fixes**
- Burndown and burn-rate charts drew as bare axes when coverage was
sparse: `showSymbol: false` means an isolated measured bucket between
gaps has no segment and paints nothing. Symbols are now sized per point,
and a sparse-coverage note states how many buckets actually recorded
events.
- Nothing scrolled below ~700px of viewport height — `OPageLayout`'s
fixed flex body plus `OTabPanels` `scroll="none"` clipped the panels.
Panels now grow and scroll; the stat strip and tab bar stay pinned.
Verified at 1024x500, 1280x620, 1512x945.

**Other**
- `ZO_SLO_ENABLED` removed — SLOs have shipped, so the flag and its
status/route gating are gone.
- SLOs surfaced in the main nav.
- Dashboard chart panel header gets its own tint via new
`--color-panel-bar-bg` / `--color-panel-bar-border` tokens, and the bar
is extracted into `PanelBar.vue` (it existed as five hand-copied class
strings that had already drifted).
- `tsconfig.vitest.tsbuildinfo` untracked; third-party vendor name
removed from comments and test names.

## Testing

- New Rust tests across `meta/slo/burn.rs`, `condition.rs`,
`core/src/alerts/alert.rs` and `infra/src/table/alerts`.
- New frontend suites: `sloAlertPayload.spec.ts`,
`sloAlertRouting.spec.ts`, `alertPayload.spec.ts`,
`AlertDetailSlo.spec.ts`, `SloDetailAlerts.spec.ts`,
`SloListDelete.spec.ts`, `SloTimeSlicePreview.spec.ts`.
- `cargo clippy --all-targets` and `web` `lint:ci` clean.
2026-08-10 10:07:38 +00:00
Shrinath Rao 98e03bca15 test(e2e/alpha1): stabilize the alpha1 cloud suite — auth self-heal, infra, and per-test heals (#13626)
## Stabilize the Alpha1 (cloud) e2e suite + regression carryover

Root-caused and fixed the failures surfacing on the Alpha1 cloud runs —
investigated live via Playwright MCP against alpha and, where possible,
a local build. Grouped by theme. Every fix is non-masking (still fails
if the underlying is genuinely broken). Pairs with ENT #2351
(`max-parallel` + Logs-SelectStar `quick_mode`).

### Runtime / infra resilience (whole-suite)
- **Auth self-heal on 401 / session expiry** — the shared cloud session
+ per-org passcode are minted once and reused all run; on
load/contention they expire mid-run (`User not authenticated`, `HTTP 401
Unauthorized`). `cloud-auth.authedRequest` refreshes the passcode and
retries on 401 (escalating to a full Dex re-login if the session is
dead); `navigateToBase` re-authenticates and resumes instead of
throwing. Also routed the alert **template-creation** API through it
(401 there cascaded into "Failed to navigate to templates"). Gated on
`isCloudEnvironment()` — no self-hosted change.
- **`--disable-dev-shm-usage`** on the alpha1 Chromium launch — the EKS
pods used the default 64MB `/dev/shm`; under 5 workers on long/heavy
shards Chromium exhausted it and the pod OOM-killed → "runner lost
communication" (frozen step + 404 logs). Route shared memory to /tmp;
eliminates the infra deaths.
- **Service graph queries a wide window** (`period=6h`) — the tab
defaulted to Past 15 Minutes and rendered "No service graph data" before
the daemon-processed topology fell inside the window.

### Pipelines
- `queryStream(stream, expectedMinCount)` **polls until the record count
lands** (pipeline output arrives async) — was single-shot ("Expected 5,
got 3").
- `openPipelineForEdit` **searches + polls-with-reload** for the edit
button (list not refreshed after save → 45s click timeout).
- `exploreStreamAndNavigateToPipeline` **reloads the streams list**
while polling for Explore, and **falls back to a direct logs URL** when
a freshly-ingested source stream never surfaces in the list
(stream-stats lag).

### Alerts
- Alert-destination URL → **public `example.com` webhook** (self-host
URL hit the cloud **SSRF guard** → form never closed).
- **Force-click the virtualized folder item** (#9484) — the row
re-rendered mid-click → 45s "not stable".
- **Export button readiness** — it's rendered only on selection; wait
for visible+enabled (re-selecting if needed) before clicking.
- **`deleteAlertByRow` cleanup readiness** — the just-created alert's
more-options kebab needs longer than 5s under load.

### RegressionSet
- **Use the shard's org** (`getOrgIdentifier()`), not hardcoded
`org_identifier=default`, in `logs-bugs` — on cloud the data lives in
`auto_org_N`, so the logs page never rendered.
- **Unique stream names** for `logs-9754` / `logs-bugs:1419` — fixed
names collided with concurrent shared-org runs ("stream is being
deleted").

### Traces / correlation
- **Migrated `logs-bugs:995` (bug-11469)** to the redesigned correlation
UI — the old `log-correlation-btn` / `correlation-dashboard-close` are
gone; repointed to the inline `correlated-traces-tab`, assertion
(`expectNoContextMenuVisible`) unchanged and **verified live on alpha**
(no fake-pass).

### Workflows (ENT-only) + misc
- **Healed the workflows destination flow** and forced-type
Connection-step assertion; alert/report list-readiness hardening.
- **Enrichment tables list** readiness (30s + re-nav retry) — "slow
under load".

### Notes
- Validated live via MCP (alpha) and a local build where the feature
exists.
- Alpha1 config already runs `retries: 2`; the remaining first-attempt
flakes are shared-env load, addressed on the ENT side via
`max-parallel`.
2026-08-06 00:57:05 +00:00
Shrinath Rao de95f7f2d8 fix: restore Table default log-detail view (#13368) + heal alert-name inline-edit read (#13585)
## What & why

Two **Playwright Regression** nightly failures, reproduced identically
on both OSS ([run
30785096054](https://github.com/openobserve/openobserve/actions/runs/30785096054))
and ENT ([run
30785071382](https://github.com/openobserve/o2-enterprise/actions/runs/30785071382))
— same two shared-`tests/` specs, all 3 retries failed each. Both are
OSS-owned specs (ENT overlays only its own `tests/*` and builds OSS
`web/`), so this single OSS PR fixes both nightlies.

### 1. Logs — real product regression (`logs-regression.spec.js:1158`)
`Log detail sidebar opens with Table tab by default (#13368)` → `Error:
Table tab should be selected by default`.

**Root cause:**
[#13368](https://github.com/openobserve/openobserve/pull/13368) (Jul 23)
deliberately made the log-detail sidebar open on the **Table** tab.
[#13451](https://github.com/openobserve/openobserve/pull/13451) (Jul 30,
*"table migration to same components"*) silently flipped
`detailTableInitialTab` back to `"json"` in `SearchResult.vue` (both the
`ref` init and the per-open reset). The unchanged test correctly caught
the reverted behavior.

**Fix:** restore `"table"` as the default log-detail tab. Product fix —
no test change.

### 2. Alerts — stale test vs redesigned component
(`alerts-stream-switching.spec.js:443`)
`Bug #11577: Alert preview chart y-axis displays numeric values` →
`TimeoutError: locator.inputValue: Timeout 45000ms exceeded`.

**Root cause:** the alert name became an **`OInlineEdit`** title
(`OFormInlineEdit`, from the
[#13547](https://github.com/openobserve/openobserve/pull/13547) Alerts
revamp). In display mode the value lives in the `…-value` span; the
`…-input` only exists **while editing**. The test read `.inputValue()`
on the non-existent input → 45s timeout.

**Fix:** read the committed display value via a new `getAlertName()`
page-object helper (with an edit-mode `inputValue()` fallback).

## Verification
- **Alerts #11577** — ✅ passed locally against a local O2 build (`1
passed`); `getAlertName()` reads the name and the full
save/verify/delete flow works.
- **Logs #13368** — restores the exact `detailTableInitialTab = "table"`
value #13368 set and the unchanged test already validated as green.
Confirmed by this run's Logs-Regression job + the dispatched ENT e2e
gate.

## Scope
- `web/src/plugins/logs/SearchResult.vue` — 2 lines (product)
-
`tests/ui-testing/playwright-tests/RegressionSet/Alerts/alerts-stream-switching.spec.js`
— read display value
- `tests/ui-testing/pages/alertsPages/alertsPage.js` — `alertNameValue`
locator + `getAlertName()` helper
2026-08-03 07:19:28 +00:00
Shrinath RaoandClaude Opus 4.8 1daa36b0f8 fix(logs): preserve restored SQL query on shared-link open + align log-detail default-tab test (13368) (#13414)
> **This PR contains two independent logs changes:**
> **(A)** a product fix for the shared-link SQL-query restore race, and
> **(B)** the log-detail default-tab test alignment (original scope of
this PR).

---

# (A) fix(logs): preserve restored SQL query on shared-link open
(fullSQLMode watcher race)

## The bug
Opening a **shared link** to an SQL search **sometimes lands on an empty
query editor** ("SQL query is missing or invalid") instead of the shared
search. Intermittent, worse under load — it's the recurring
Logs-Features alpha flake (`monaco-query-prefill` P0 "query editor never
contained SELECT").

**Not the short-URL mechanism** — the short URL correctly carries
`sql_mode=true` + the base64 query. The loss happens in the browser
during restore.

## Root cause — a watcher race
`restoreUrlQueryParams()` raises `shouldIgnoreWatcher`, flips
`meta.sqlMode = true`, then writes the decoded query into the editor.
Flipping `sqlMode` fires the **`fullSQLMode`** watcher in `Index.vue`,
whose two branches were **asymmetric**:

- **switch OFF** branch → already checks `shouldIgnoreWatcher` ✅
- **switch ON** branch → **did not** ❌ — it called `setQuery()`,
rebuilding a *default* `SELECT … FROM stream` over the value the restore
was mid-writing.

Under load the watcher wins the race; the editor briefly empties, SQL
mode auto-detects back **off**, and the editor is cleared entirely.

## The fix
Make the "switch ON" branch honour `shouldIgnoreWatcher` too — symmetric
with "switch OFF". During any programmatic restore the watcher **stands
down** and the restored query is the last word. (`shouldIgnoreWatcher`
is raised only by programmatic-state paths whose purpose is to suppress
watcher side-effects, so honouring it here is consistent.)

## Verification (A)
- ✅ **New unit test**: with `shouldIgnoreWatcher` set, flipping
`sqlMode` ON does **not** call `setQuery`/`updateUrlQueryParams`, and
the restored `SELECT` query is preserved.
- ✅ Existing `fullSQLMode` watcher test still passes; full
`Index.spec.ts` green (**69 passed**).
- ✅ Reproduced the failure on **alpha under CI-load** beforehand
(share-link P0 flaky, "query editor never contained SELECT").
- ⚠️ The race is only observable against a **deployed** frontend (the
alpha e2e suite runs against alpha's frontend, not a local build), so
the final "flake gone on alpha under load" check requires this deployed
to alpha, then re-running the Logs-Features share-link tests.

Files: `web/src/plugins/logs/Index.vue`,
`web/src/plugins/logs/Index.spec.ts`.

---

# (B) test(logs): align log-detail default-tab test with Table default
(13368)

## What
Updates the log-detail sidebar default-tab regression test (originally
Bug #9724) to match the **intentionally shipped** behavior from [PR
#13368](https://github.com/openobserve/openobserve/pull/13368) — *"logs
sidebar table will be default view and draggable tabs"*.

## Why
#13368 changed the log-detail sidebar default from the **JSON** tab to
the **Table** tab (`SearchResult.vue` — `detailTableInitialTab.value =
"table"`). The Bug #9724 test still asserted JSON-as-default, so it
fails on `main`: the JSON tab's `data-state` stays `inactive` for the
full timeout across all retries, on both OSS and ENT Logs-Regression.
Not a flake and not a product bug — the test expectation was simply out
of date after a deliberate default-view change.

## Changes
- Rename test → **"Log detail sidebar opens with Table tab by default
(#13368)"**.
- Add `verifyTableTabSelectedByDefault()` page-object helper
(auto-retrying `toHaveAttribute('data-state','active')`); remove the
now-invalid `verifyJsonTabSelectedByDefault()`.
- Reorder switch steps: assert Table default (+ wrap toggle, which
renders only on the Table tab), switch to JSON and back to Table, reopen
and confirm Table default persists.

## Note on #13407
Supersedes the earlier heal
[#13407](https://github.com/openobserve/openobserve/pull/13407), which
misdiagnosed the failure as a `data-state` timing flake. A
locally-hosted stale pre-#13368 build had masked the change.

Files: `tests/ui-testing/pages/logsPages/logsPage.js`,
`tests/ui-testing/playwright-tests/RegressionSet/Logs/logs-regression.spec.js`.

```
npx playwright test playwright-tests/RegressionSet/Logs/logs-regression.spec.js \
  -g "Table tab by default" --project=chromium
```

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 13:35:24 +00:00
Shrinath RaoandClaude Opus 4.8 871b9b69b7 test(traces): heal bug #11531 spec for flame-graph-default trace detail (#13392)
## What

Heals the **Traces-Regression** failure on `main` (scheduled run
[29935986660](https://github.com/openobserve/openobserve/actions/runs/29935986660/job/88982390601)).

The Bug #11531 test in `traces-bugs.spec.js` (`traces spans tab should
not reference non-existent method field`) clicks a trace result and
immediately asserts the span tree via `expectTraceDetailsVisible()`,
which waits for `[data-test="trace-details-tree"]`.

## Why it started failing

PR 13347 (`fix: traces page default flame graph and drag-drop option
added`) changed the trace detail view to **open on the flame graph by
default** (`DEFAULT_TRACE_TAB = "flame-graph"`) instead of the
waterfall. The span tree lives inside `v-if="activeTab ===
'waterfall'"`, so it no longer renders on open — the assertion timed out
(15s) and the job exited 1.

This is **not a product bug** — it's an intentional product change.
13347 added a `openTraceDetailsTab()` helper and updated the other
traces specs, but this Bug #11531 test was missed.

## Fix

Select the waterfall tab explicitly before reading the tree, matching
the pattern 13347 already applied elsewhere:

```js
// Since 13347 the trace detail opens on the flame graph by default.
await pm.tracesPage.openTraceDetailsTab('waterfall');
await pm.tracesPage.expectTraceDetailsVisible();
```

Test-only change; no product code touched.

## Verification (local, hosted O2 @ localhost:5080, `default` traces
stream w/ data)

| State | Result |
|-------|--------|
| Before fix (unpatched) | ❌ `expectTraceDetailsVisible` times out at
`tracesPage.js:310` |
| After fix (patched) | ✅ `1 passed (22.3s)` — "Trace details visible"
logged |

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-23 04:36:33 +00:00
f15e27e5fd refactor: design token migration + CI guards (#13173)
# Design System Unification — one visual language, enforced end-to-end

Establishes **one source of truth for every visual decision**, wires the
whole app to it, and **locks it in with CI** so it can't drift back.

### Foundations
- **Design-token system ("one knob per decision").** Every colour, text
size, spacing, corner radius, and shadow is a named token defined in
exactly one place — change the token, every screen updates. Collapsed
hundreds of near-duplicate definitions and removed "fake" duplicates
that pretended to be different but weren't.
- **Shared component library (O2).** Buttons, tables, dialogs, drawers,
form fields, badges, etc. already know the correct colours, spacing, and
dark-mode behaviour; new screens compose them instead of hand-styling.
Added new primitives on this branch (`OContent`, `KpiCard`) and
standardized existing ones.
- **One page structure everywhere** (`PageLayout` / `AppPageHeader` /
`AppPage` / `OContent`) — titles, breadcrumbs, spacing, and content
edges line up identically across every screen.
- **One table implementation** — all tabular data uses the same table
(sorting, density, sticky headers, empty states).
- **Styling consolidated onto Tailwind; old systems removed** —
hand-written CSS driven to the practical minimum, the legacy **Quasar**
framework fully removed, surviving stylesheets required to justify
themselves.
- **Two-tier corner radius** — a tight **4px** for controls and a soft
**12px** for surfaces (dialogs, cards, the app shell), plus a
full-circle option — replacing five radius names that all secretly meant
the same thing.

### Detailed improvements across screens
**Page structure & alignment** — unified page shell rolled across ~40+
screens (IAM, Settings, Alerts, Dashboards, Functions, Pipelines, RUM,
Metrics, Synthetics, Billing, editors, lists); one header height; one
page-edge grid driving headers, tables, rails, and tabs; unified
side-rail widths; inset rail selection/hover pills; every tab strip on
the grid line; tightened title/subtitle spacing.

**Tables (cross-screen)** — action columns consistently centered (incl.
Organizations); unified row-number column with no "#" truncation;
non-standard tables restyled to match; loading skeletons made
geometrically identical to the loaded table; symmetric edge inset; IAM
first-column grid alignment fixed.

**Traces** — flame graph + span-detail correlation panel fixes;
correlated logs/metrics placeholder fit; sticky headers; removed a
double scrollbar + a 1px sliver; aligned table fonts/badges; polished
the service detail drawer; stream-selector + correlation alignment;
aligned loading spinners; floating overlay arrows for the
disabled-services strip.

**Logs** — field-list controls aligned (focus ring no longer clipped);
detail-drawer spacing + metrics-tab overflow fixed; Run Query toolbar
tidied; listing sizing + stray border fixed.

**Metrics** — search added to the "Type" facet rail and aligned with the
other rails; proper empty states for the explorer and facet rail.

**Dashboards** — removed inconsistent card shadows; tightened
borders/resizers/field-list spacing; aligned View Dashboard chrome to
the grid; chart colours via the token helper.

**Home** — redesigned the Usage tab; added reusable KPI stat cards so
summary strips stop drifting.

**Dark mode** — new theme-switch animation; fixed a 1px content shift on
toggle and a white flash on load; fixed AI-chat text and assorted
light/dark mismatches; completed the token-driven dark migration.

**Empty states, controls & small polish** — restored 3 broken
empty-state animations; adopted the standard empty state; added the
sliding indicator to the toggle control; fixed the Quality-page inset +
drawer badge; refreshed Search History / Schedulers; fixed the
alert-history drawer scrollbar + timeline hover; removed a stray
menu-bar border.

### Dead code & cruft removal
- **Deleted the entire legacy `utilities.css`** global stylesheet (well
over a thousand lines) — evacuated in waves, roughly half of it dead
once traced.
- **Removed Quasar entirely**, including dead `.q-*` styles and ~25
phantom `--q-*` variables that were silently breaking bits of the UI.
- Stripped hundreds of **dead CSS classes and tokens that compiled to
nothing** — e.g. 46 uses of a colour class with no backing token, a
no-op shadow class on 51 elements, dead layout/utility classes, a
leftover `card-container` block, a dead table-actions token, and a
mis-registered gradient that rendered nothing.
- Cut **unused keyframe animations (19 → 3)** and removed **unused
components** + a stray build artifact.
- Net effect: a much smaller, leaner styling surface — less to maintain,
fewer dead ends to copy.

## Safety & verification
Large but low-risk: this is overwhelmingly a **styling and structure**
change, not product behaviour or data. Guarded by the
design-token/consistency/type checks above plus the existing test suite,
and reviewed screen-by-screen.

---------

Co-authored-by: Kirtan Thakkar <kirtan@kiara.tech>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: ktx-mihir <mihir.patel@kiara.tech>
2026-07-20 18:06:21 +00:00
ktx-mihirandktx-vaidehi 54fdbad0d8 fix: reports module form migration with zod (#12949)
- form migration with zod schema for reports module

---------

Co-authored-by: ktx-vaidehi <vaidehi.akhani@kiara.tech>
2026-07-15 10:46:54 +00:00