Debugging Opik E2E Tests
comet-ml/opik
Investigates a failed Opik end-to-end test from CI, TestOps or a local run, decides regression versus flake, and proposes a fix without editing tests.
Analyze a failing E2E test, determine root cause, and fix it using Playwright Test Agents and RHDH project conventions
$ npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install redhat-developer/rhdh e2e-diagnose-and-fix --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/redhat-developer/rhdh.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/e2e-diagnose-and-fix .claude/skills/e2e-diagnose-and-fix && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "e2e-diagnose-and-fix" agent skill from https://github.com/redhat-developer/rhdh/tree/main/.claude/skills/e2e-diagnose-and-fix into .claude/skills/e2e-diagnose-and-fix/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "e2e-diagnose-and-fix", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/redhat-developer/rhdh/tree/main/.claude/skills/e2e-diagnose-and-fixType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install redhat-developer/rhdh e2e-diagnose-and-fix --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/redhat-developer/rhdh.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.claude/skills/e2e-diagnose-and-fix .agents/skills/e2e-diagnose-and-fix && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "e2e-diagnose-and-fix" agent skill from https://github.com/redhat-developer/rhdh/tree/main/.claude/skills/e2e-diagnose-and-fix into .agents/skills/e2e-diagnose-and-fix/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "e2e-diagnose-and-fix", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install redhat-developer/rhdh e2e-diagnose-and-fix --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/redhat-developer/rhdh.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.claude/skills/e2e-diagnose-and-fix .cursor/skills/e2e-diagnose-and-fix && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "e2e-diagnose-and-fix" agent skill from https://github.com/redhat-developer/rhdh/tree/main/.claude/skills/e2e-diagnose-and-fix into .cursor/skills/e2e-diagnose-and-fix/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "e2e-diagnose-and-fix", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/redhat-developer/rhdh.git --path .claude/skills/e2e-diagnose-and-fix--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install redhat-developer/rhdh e2e-diagnose-and-fix --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/redhat-developer/rhdh.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.claude/skills/e2e-diagnose-and-fix .gemini/skills/e2e-diagnose-and-fix && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "e2e-diagnose-and-fix" agent skill from https://github.com/redhat-developer/rhdh/tree/main/.claude/skills/e2e-diagnose-and-fix into .gemini/skills/e2e-diagnose-and-fix/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "e2e-diagnose-and-fix", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install redhat-developer/rhdh e2e-diagnose-and-fixInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/redhat-developer/rhdh.git skills-src && mkdir -p .github/skills && cp -r skills-src/.claude/skills/e2e-diagnose-and-fix .github/skills/e2e-diagnose-and-fix && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "e2e-diagnose-and-fix" agent skill from https://github.com/redhat-developer/rhdh/tree/main/.claude/skills/e2e-diagnose-and-fix into .github/skills/e2e-diagnose-and-fix/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "e2e-diagnose-and-fix", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install redhat-developer/rhdh e2e-diagnose-and-fix --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/redhat-developer/rhdh.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.claude/skills/e2e-diagnose-and-fix .opencode/skills/e2e-diagnose-and-fix && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "e2e-diagnose-and-fix" agent skill from https://github.com/redhat-developer/rhdh/tree/main/.claude/skills/e2e-diagnose-and-fix into .opencode/skills/e2e-diagnose-and-fix/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "e2e-diagnose-and-fix", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
e2e-diagnose-and-fixAnalyze a failing E2E test, determine root cause, and fix it using Playwright Test Agents and RHDH project conventions
E2E Diagnose And Fix is an agent skill from redhat-developer/rhdh. Analyze a failing E2E test, determine root cause, and fix it using Playwright Test Agents and RHDH project conventions
Its SKILL.md is about 3.5k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in Testing & QA, covering End-to-end testing and Root cause analysis. It works with Playwright. The repository describes itself as: The repo formerly known as janus-idp/backstage-showcase. The licence is Apache-2.0.
6 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit e51f3cf. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
gitnpxghyarnFrom the folder's file list and the shell code blocks in SKILL.md.
Hosts in commands or code, which the agent is likely to contact:
redhat.atlassian.netAlso links to:
playwright.devFrom URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
K8S_CLUSTER_TOKENFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
E2E Diagnose And Fix loads about 3.5k tokens when it runs. Until then it costs about 35 tokens; SKILL.md has 1,627 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check noted patterns worth knowing about, such as sudo or a known installer.
The healer agent needs a `.env` file in `e2e-tests/` with all required environment variables (BASE_URL, K8S_CLUSTER_TOKEThe `.env` file is gitignored — never commit it. To regenerate (e.g. after token expiry), re-run the command above.Run command: set -a && source .env && set +a && npx playwright test <spec-file> --project=any-test --retries=0 --workersAutomated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from redhat-developer/rhdh at commit e51f3cf, republished under its Apache-2.0 licence (© redhat-developer). 1,627 words, ~3,517 tokens.
.claude/skills/e2e-diagnose-and-fix/SKILL.md (or your agent's skills folder).Analyze the root cause of a failing E2E test and implement a fix following RHDH project conventions.
Use this skill after reproducing a failure (via e2e-reproduce-failure) when you have confirmed the test fails and need to determine the root cause and implement a fix.
If the fix branch is based on a release branch (e.g., release-1.9), check whether the failing test was already fixed on main before proceeding with the healer:
git fetch upstream main
git log --oneline upstream/main -- <path-to-failing-spec-file> | head -10If there are recent commits touching the failing spec file or its page objects, inspect them:
git log --oneline upstream/main -p -- <path-to-failing-spec-file> | head -100If a fix exists on main, always cherry-pick it — this takes priority over running the healer:
git cherry-pick <commit-sha>If the cherry-pick has conflicts, resolve them manually using the main commit as the source of truth and adapting to the release branch's code. Do not abandon the cherry-pick in favor of the healer — the fix on main is the authoritative solution.
After a successful cherry-pick (with or without conflict resolution), proceed to e2e-verify-fix. Only proceed to the healer below if no relevant fix exists on main, or if the cherry-picked fix doesn't resolve the issue on the release branch.
The Playwright healer agent MUST be used for ALL test failures, regardless of failure category. Do not attempt manual diagnosis without first running the healer. The healer can run the test, debug it step-by-step, inspect the live UI, generate correct locators, and edit the code — often resolving the issue end-to-end without manual intervention.
Note: The Playwright healer agent is currently supported in OpenCode and Claude Code only. In Cursor or other tools without Playwright agent support, skip the healer initialization and proceed directly to the "Failure Pattern Recognition" section below. Use manual diagnosis with direct test execution (
yarn playwright test ...) and headed/debug mode (--headed,--debug) for live UI inspection.
If not already initialized in this session, initialize the healer agent in e2e-tests/:
cd e2e-tests
# For OpenCode
npx playwright init-agents --loop=opencode
# For Claude Code
npx playwright init-agents --loop=claudeSee https://playwright.dev/docs/test-agents for the full list of supported tools and options. The generated files are local tooling — do NOT commit them.
The healer agent needs a .env file in e2e-tests/ with all required environment variables (BASE_URL, K8S_CLUSTER_TOKEN, vault secrets, etc.). Generate it by passing the --env flag to local-test-setup.sh:
cd e2e-tests
source local-test-setup.sh <showcase|rbac> --envThe .env file is gitignored — never commit it. To regenerate (e.g. after token expiry), re-run the command above.
Invoke the healer agent via the Task tool with subagent_type: general:
Task: "You are the Playwright Test Healer agent. Run the failing test, debug it, inspect the UI, and fix the code.
Working directory: <path>/e2e-tests
Test: <spec-file> --project=any-test -g '<test-name>'
Run command: set -a && source .env && set +a && npx playwright test <spec-file> --project=any-test --retries=0 --workers=1 -g '<test-name>'"The healer will autonomously:
After the healer has run, supplement with manual investigation only for:
Symptoms: Error: locator.click: Error: strict mode violation or Timeout waiting for selector or element not found errors.
Cause: The UI has changed and selectors no longer match.
Fix approach:
@playwright-test-healer) — it will replay the test, inspect the current UI via page snapshots, generate updated locators, and edit the code automaticallySymptoms: Test passes sometimes, fails sometimes. Errors like Timeout 10000ms exceeded or assertions failing on stale data.
Cause: Test acts before the UI is ready, or waits are insufficient.
Fix approach:
page.waitForTimeout() with proper waits: expect(locator).toBeVisible(), page.waitForLoadState()expect().toPass() with retry intervals for inherently async checks:await expect(async () => {
const text = await page.locator('.count').textContent();
expect(Number(text)).toBeGreaterThan(0);
}).toPass({ intervals: [1000, 2000, 5000], timeout: 30_000 });Common.waitForLoad() utility before interacting with the page after navigationSymptoms: expect(received).toBe(expected) with clearly different values.
Cause: The expected value has changed due to a product change, data change, or environment difference.
Fix approach:
test.fixme() (see the "Decision: Product Bug vs Test Issue" section below)Symptoms: Test fails because expected entities, users, or resources don't exist.
Cause: Test data assumptions no longer hold (GitHub repos deleted, Keycloak users changed, catalog entities removed).
Fix approach:
e2e-tests/playwright/support/test-data/ or e2e-tests/playwright/data/beforeAll/beforeEach and cleans up in afterAll/afterEachAPIHelper for programmatic setup (GitHub API, Backstage catalog API)Symptoms: Test passes on OCP but fails on GKE/AKS/EKS, or vice versa.
Cause: Platform differences (Routes vs Ingress, different auth, different network policies).
Fix approach:
import { skipIfJobName, skipIfIsOpenShift } from '../utils/helper';
// Skip on GKE
skipIfJobName(constants.GKE_JOBS);
// Skip on non-OpenShift
skipIfIsOpenShift('false');process.env.IS_OPENSHIFT, process.env.CONTAINER_PLATFORMSymptoms: RHDH itself is broken (500 errors, missing plugins, wrong behavior).
Cause: ConfigMap or Helm values are incorrect for this test scenario.
Fix approach:
.ci/pipelines/resources/config_map/app-config-rhdh.yaml and app-config-rhdh-rbac.yaml.ci/pipelines/value_files/.ci/pipelines/resources/config_map/dynamic-plugins-config.yamlrhdh-operator and rhdh-chart repos for configuration reference (use Sourcebot, Context7, gh search code, or a local clone — whichever is available)The Playwright Test Agents are initialized via npx playwright init-agents --loop=opencode (see initialization section above). This creates an MCP server and agent definitions in e2e-tests/opencode.json.
The healer agent is the primary and mandatory tool for fixing failing tests. It has access to:
test_run: Run tests and identify failurestest_debug: Step through failing tests with the Playwright Inspectorbrowser_snapshot: Capture accessibility snapshots of the live UIbrowser_console_messages: Read browser console logsbrowser_network_requests: Monitor network requestsbrowser_generate_locator: Generate correct locators from the live UIedit/write: Edit test code directlyThe healer autonomously cycles through: run → debug → inspect → fix → re-run until the test passes.
Use @playwright-test-planner when you need to understand a complex user flow before fixing a test. It explores the app and maps out the interaction patterns.
Use @playwright-test-generator when a test needs major rework and you need to generate new test steps from a plan.
Every fix must follow Playwright best practices. Before writing or modifying test code, consult these resources in order:
Project rules (always available locally):
playwright-locators rule — locator priority, anti-patterns, assertions, Page Objects, DataGrid handlingci-e2e-testing rule — test structure, component annotations, project configuration, CI scriptsOfficial Playwright docs (fetch via Context7 if available, otherwise use web):
getByRole(), getByLabel(), getByPlaceholder() over CSS/XPath selectors. Never use MUI class names (.MuiButton-label, .MuiDataGrid-*).expect(locator).toBeVisible()) — never use manual waitForSelector() or waitForTimeout().*.spec.ts file must have a component annotation in test.beforeAll.Locator objects from page classes, not raw strings or elements.force: true: if a click requires force, the locator or timing is wrong — fix the root cause.waitForNetworkIdle(): use proper load-state waits or assertion-based waiting instead.When the issue is in RHDH deployment/config rather than test code, search the relevant repos using whichever tool is available. Try them in this order and use the first one that works:
gh search code: e.g. gh search code '<pattern>' --repo redhat-developer/rhdh-operatorredhat-developer/rhdh-operator)install-rhdh-catalog-source.sh)redhat-developer/rhdh-chart)test.fixme() is a last resort. You must be absolutely certain the failure is a product bug before marking a test this way. Follow this checklist:
test.fixme() — do not decide unilaterallyOnly after all of the above confirm a product bug:
RHDHBUGS project (or update the existing ticket) documenting the product regressiontest.fixme(), preceded by a // TODO: comment linking to the Jira ticket:// TODO: https://redhat.atlassian.net/browse/RHDHBUGS-XXXX
test.fixme('Button no longer visible after version upgrade');e2e-submit-and-review with the test.fixme() change© redhat-developer, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .claude/skills/e2e-diagnose-and-fix of redhat-developer/rhdh.
Open the folder on GitHubat commit e51f3cf
E2E Diagnose And Fix next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| E2E Diagnose And Fix this skillredhat-developer/rhdh | 172 | — | ~3.5k | Automated safety check: Notes | Apache-2.0 | |
| Debugging Opik E2E Testscomet-ml/opik | 22k | — | ~1.8k | Automated safety check: Pass | Apache-2.0 | |
| Debug E2E Testbitovi/ai-enablement-prompts | 121 | — | ~677 | Automated safety check: Pass | MIT | |
| Web Application Testinganthropics/skills | 180k | 51 repos | ~966 | Automated safety check: Pass | Apache-2.0 | |
| Write and Verify Playwright Testsappsmithorg/appsmith | 41k | — | ~2.9k | Automated safety check: Notes | Apache-2.0 | |
| playwright-cli Browser Automationgithub/gh-aw | 5.4k | 23 repos | ~2.8k | Automated safety check: Pass | MIT |
comet-ml/opik
Investigates a failed Opik end-to-end test from CI, TestOps or a local run, decides regression versus flake, and proposes a fix without editing tests.
bitovi/ai-enablement-prompts
Debug and fix failing Playwright E2E tests. An agent skill from bitovi/ai-enablement-prompts.
anthropics/skills
Tests local web applications with Python Playwright scripts, checking frontend behavior, capturing screenshots and reading browser console logs.
appsmithorg/appsmith
Writes a Playwright end-to-end test from a prompt, runs it against a live Appsmith deployment and retries with fixes up to three times until it passes.
github/gh-aw
Drives a real browser from the command line with playwright-cli to open pages, interact, mock requests, save state and work with Playwright tests.
langgenius/dify
Guides changes and reviews of the Cucumber and Playwright end-to-end suite under `e2e/`: feature files, step definitions, support code, tags, locators and assertions.
redhat-developer/rhdh
Create a PR for an E2E test fix, trigger Qodo agentic review, address review comments, and monitor CI results
redhat-developer/rhdh
Deploy RHDH to an OpenShift cluster using local-run.sh for E2E test execution, with autonomous error recovery for deployment failures
redhat-developer/rhdh
Parse a Prow CI job URL or Jira ticket to extract E2E test failure details including test name, spec file, release branch, platform, and error messages
redhat-developer/rhdh
Run a specific failing E2E test against a deployed RHDH instance to confirm the failure and determine if it is consistent or flaky
redhat-developer/rhdh
Verify an E2E test fix by running the test multiple times and checking code quality
redhat-developer/rhdh
Workflow to backport Backstage changes into RHDH by syncing a downstream maintenance branch and generating yarn patches.
Works with
Categories
Analyze a failing E2E test, determine root cause, and fix it using Playwright Test Agents and RHDH project conventions. E2E Diagnose And Fix is an agent skill from redhat-developer/rhdh.
E2E Diagnose And Fix fits situations like: tasks that involve End-to-end testing; tasks that involve Root cause analysis.
Run `npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a claude-code`. Or copy the skill folder (.claude/skills/e2e-diagnose-and-fix in redhat-developer/rhdh) into .claude/skills/e2e-diagnose-and-fix in your project. Claude Code loads it when a task matches its description.
Run `npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a codex`. Or copy the skill folder (.claude/skills/e2e-diagnose-and-fix in redhat-developer/rhdh) into .agents/skills/e2e-diagnose-and-fix in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add redhat-developer/rhdh --skill e2e-diagnose-and-fix -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/e2e-diagnose-and-fix, .gemini/skills/e2e-diagnose-and-fix, .github/skills/e2e-diagnose-and-fix and .opencode/skills/e2e-diagnose-and-fix in your project.
Going by SKILL.md and its folder, E2E Diagnose And Fix needs the command-line tools its instructions call (git, npx, gh and yarn) and credentials named K8S_CLUSTER_TOKEN. Our summary lists: Node.js; A credential in K8S_CLUSTER_TOKEN.
SKILL.md names 2 domains. In commands or code: redhat.atlassian.net; the agent is likely to contact it when it follows the instructions. As links in the text: playwright.dev. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.
E2E Diagnose And Fix is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 3.5k tokens (SKILL.md is roughly 14k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with E2E Diagnose And Fix: Debugging Opik E2E Tests (comet-ml/opik, 22k stars), Debug E2E Test (bitovi/ai-enablement-prompts, 121 stars), Web Application Testing (anthropics/skills, 180k stars) and Write and Verify Playwright Tests (appsmithorg/appsmith, 41k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
redhat-developer (a GitHub organization) maintains it in redhat-developer/rhdh, which has 172 GitHub stars. The repository holds 7 skills in this directory. The repository was last updated on October 9, 2026.
Source: redhat-developer/rhdh on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.