tamash-playwright 0.11.0-beta.8 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env.example +1 -1
- package/CHANGELOG.md +3 -3
- package/README.md +1 -1
- package/RELEASE-TESTING.md +4 -4
- package/package.json +1 -1
- package/skills/tamash-playwright/references/onboarding.md +3 -3
package/.env.example
CHANGED
|
@@ -60,7 +60,7 @@ OLLAMA_API_KEY=
|
|
|
60
60
|
# In other CI systems: set GITHUB_TOKEN (or COPILOT_GITHUB_TOKEN) to a PAT with "Copilot Requests".
|
|
61
61
|
# COPILOT_SUBSCRIPTION_MODEL=mai-code-1-flash-picker
|
|
62
62
|
|
|
63
|
-
# --- Cursor subscription (LOCAL DEVELOPMENT ONLY --
|
|
63
|
+
# --- Cursor subscription (LOCAL DEVELOPMENT ONLY -- experimental, prefer kiro/codex) ---
|
|
64
64
|
# Requires: the `agent` CLI installed (curl https://cursor.com/install -fsS | bash) and signed in
|
|
65
65
|
# via `agent login` (or CURSOR_API_KEY). Runs `agent -p --trust --mode ask --output-format json` --
|
|
66
66
|
# `--mode ask` is Cursor's read-only Q&A mode, so a heal call can't edit files or run commands.
|
package/CHANGELOG.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
All notable changes to this project are documented here. Format loosely follows
|
|
4
4
|
[Keep a Changelog](https://keepachangelog.com/); dates are when each version was published.
|
|
5
5
|
|
|
6
|
-
## [0.11.0] - 2026-08-
|
|
6
|
+
## [0.11.0] - 2026-08-31
|
|
7
7
|
|
|
8
8
|
### Fixed
|
|
9
9
|
|
|
@@ -100,8 +100,8 @@ All notable changes to this project are documented here. Format loosely follows
|
|
|
100
100
|
is an interactive assistant rather than a one-shot completion endpoint — given the heal prompt it
|
|
101
101
|
often answers conversationally instead of with the required JSON, so the heal is declined more
|
|
102
102
|
often than with `kiro`/`codex`. It's now invoked in the safest/best-effort form
|
|
103
|
-
(`agent -p --trust --mode ask --output-format json`, read-only) and
|
|
104
|
-
|
|
103
|
+
(`agent -p --trust --mode ask --output-format json`, read-only) and is marked **experimental**;
|
|
104
|
+
the docs point to `kiro`/`codex` as the steadier local-subscription options. Report issues.
|
|
105
105
|
Also: the full e2e healing suite (12 tests) was run end to end against `copilot-subscription` and
|
|
106
106
|
`ollama` — **12/12 each** — to confirm the parser rewrite and provider changes don't regress it.
|
|
107
107
|
|
package/README.md
CHANGED
|
@@ -190,7 +190,7 @@ A no-op if `copilot-subscription` was never used, so it's safe to add unconditio
|
|
|
190
190
|
|
|
191
191
|
### Using a Cursor, Kiro, or Codex subscription — local development only
|
|
192
192
|
|
|
193
|
-
Three more subscription-based providers, all
|
|
193
|
+
Three more subscription-based providers, all **local-development-only, never recommended for CI**, extending the same "use what you're already paying for" idea. `kiro-subscription` and `codex-subscription` are verified healing real broken locators; `cursor-subscription` is experimental (see the note below).
|
|
194
194
|
|
|
195
195
|
**Cursor** — needs the `agent` CLI (`curl https://cursor.com/install -fsS | bash`) and `agent login` (or `CURSOR_API_KEY`):
|
|
196
196
|
|
package/RELEASE-TESTING.md
CHANGED
|
@@ -17,7 +17,7 @@ currently covered · N/A not applicable to that column.
|
|
|
17
17
|
| Core action healing (click/fill/check/selectOption/etc.) | Any wrapped Playwright action retries against a healed locator on failure. | ✅ Extensive unit + e2e coverage (many repro specs) | ✅ Every CI run exercises this against the sample repos' own broken locators |
|
|
18
18
|
| Master on/off switch (`HEALER_ENABLED=false`) | A broken locator fails exactly like vanilla Playwright when healing is off; a working locator is unaffected either way. | ✅ Permanent e2e (`healing-disabled.e2e.spec.ts`) — **found with zero coverage anywhere in this repo, ever, until asked directly whether "with and without AI healing" had actually been tested** | ❌ Neither CI workflow runs with healing disabled (`apply-heals`'s own verification step does, but only to confirm an already-applied fix works standalone — not the same as testing a genuinely broken locator with healing off) |
|
|
19
19
|
| `.describe()` context | Human-readable label chained onto a locator, used as the AI's primary description. | ✅ Used throughout the test suite | ✅ Both sample repos' tests use it |
|
|
20
|
-
| Automatic variable-name description fallback | `extractVariableName` (raw identifier) + `decodeVariableName` (decoded phrase + type hint) when `.describe()` isn't called. | ✅ 10+10 unit tests, permanent e2e spec |
|
|
20
|
+
| Automatic variable-name description fallback | `extractVariableName` (raw identifier) + `decodeVariableName` (decoded phrase + type hint) when `.describe()` isn't called. | ✅ 10+10 unit tests, permanent e2e spec | 🔎 Exercised on every sample-repo CI heal (it's the description path when `.describe()` is absent), no dedicated assertion |
|
|
21
21
|
| Search-scoped snapshots | Sends a narrower excerpt of the accessibility tree when the description matches exactly one node, instead of the full page. | ✅ Live-verified (measured token reduction across several real cases) | 🔎 Silently exercised on every CI heal (it's the default first path), but no dedicated CI assertion checks it specifically |
|
|
22
22
|
| `near` strategy (nameless field via label) | Resolves an unlabeled field by climbing to a shared ancestor and finding the one plausible-role sibling. | ✅ e2e (`aic-form-healing`, `employee-id-healing`) | ✅ Indirectly — the sample repos' own Employee Id field is exactly this shape |
|
|
23
23
|
| `adjacent` strategy (same-row disambiguation) | Precise sibling match when `near`'s ancestor search would find more than one same-role candidate. | ✅ e2e (`adjacent-sibling-healing`) + unit | ❌ No sample test currently has this shape |
|
|
@@ -36,14 +36,14 @@ currently covered · N/A not applicable to that column.
|
|
|
36
36
|
| `getDurable()` | Resolves any locator (e.g. `aria-ref=...`) to a durable, reusable equivalent. | ✅ e2e (`get-durable-*-repro`, 4 specs incl. concurrency) | ❌ No CI sample test calls it directly |
|
|
37
37
|
| Provider: `ollama` | API-key provider, Ollama Cloud. | ✅ Verified this session (live calls, real token counts) | ✅ Both CI workflows now run a `test-ollama` job, confirmed green |
|
|
38
38
|
| Provider: `ollama-local` | Self-hosted Ollama server; `OLLAMA_LOCAL_API_KEY` optional, unlike `ollama`'s required key. | ✅ Verified against a genuine local Ollama installation this session (real `ollama serve`, `qwen2.5:0.5b` pulled and warmed) — confirmed the default `OLLAMA_LOCAL_BASE_URL`, real request/response round-trip (including correct token-usage extraction), and that the real server both works with no `Authorization` header and tolerates one being sent unnecessarily; also confirmed end-to-end via the real `doctor` CLI, not just a direct provider call. (A synthetic fake-HTTP-server test preceded this and is superseded by it.) | ❌ Not used in either CI workflow (no self-hosted Ollama instance available in CI) |
|
|
39
|
-
| Multi-agent skill (`skills/tamash-playwright/`) | Local review/apply/verify/land workflow for AI coding assistants, plus adapters for Claude Code, Kiro, Cursor, Copilot, and `AGENTS.md`-reading tools. | ✅ Exercised end-to-end by real, unbriefed agents in isolated environments (no prior tamash-playwright knowledge given) — three separate walkthroughs: (1) a project with real `doctor` `[WARN]`s → correctly routed to `onboarding.md`, fixed 6 missing `.describe()`s, and correctly stopped at the Page Object gate rather than "fixing" files it verified were intentionally non-POM demos; (2) a `doctor`-clean project with a real broken locator → correctly routed to `heal.md`, ran the full RUN→REVIEW→APPLY→VERIFY loop unattended, and correctly stopped at LAND rather than committing anything; (3) a from-scratch project with zero `tamash-playwright` presence → correctly installed and configured it from the published package's own docs
|
|
39
|
+
| Multi-agent skill (`skills/tamash-playwright/`) | Local review/apply/verify/land workflow for AI coding assistants, plus adapters for Claude Code, Kiro, Cursor, Copilot, and `AGENTS.md`-reading tools. | ✅ Exercised end-to-end by real, unbriefed agents in isolated environments (no prior tamash-playwright knowledge given) — three separate walkthroughs: (1) a project with real `doctor` `[WARN]`s → correctly routed to `onboarding.md`, fixed 6 missing `.describe()`s, and correctly stopped at the Page Object gate rather than "fixing" files it verified were intentionally non-POM demos; (2) a `doctor`-clean project with a real broken locator → correctly routed to `heal.md`, ran the full RUN→REVIEW→APPLY→VERIFY loop unattended, and correctly stopped at LAND rather than committing anything; (3) a from-scratch project with zero `tamash-playwright` presence → correctly installed and configured it from the published package's own docs, proved real healing by deliberately breaking a locator and watching it recover live, and in doing so found a real bug now fixed (see CHANGELOG: `doctor`'s connectivity check was decoupled from the real `actionTimeout`). Six genuine documentation bugs found and fixed across all three runs, not just "read for plausibility." | ❌ Not used in either CI workflow (nothing to run in CI — this is consumed by an agent, not by the test suite) |
|
|
40
40
|
| Provider: `openai` | API-key provider. | ✅ Re-verified live this release (`doctor` connectivity, real key) | ❌ Not used in either CI workflow |
|
|
41
41
|
| Provider: `anthropic` | API-key provider. | ✅ Re-verified live this release (`doctor` connectivity, real key) | ❌ Not used in either CI workflow |
|
|
42
42
|
| Provider: `gemini` | API-key provider. | ⚠️ Key authenticates and the model responds correctly (verified with a raw request, real `200 OK`), but `gemini-3.6-flash` took 50+ seconds to answer a trivial prompt — far beyond `doctor`'s 15s timeout and this repo's real `actionTimeout: 8000`ms, so it fails both `doctor` and real healing as currently configured, despite the key itself being valid | ❌ Not used in either CI workflow |
|
|
43
43
|
| Provider: `claude-subscription` | No API key — uses a Claude subscription. | ✅ Verified this session | ✅ The Playwright sample repo's CI uses this as its default provider |
|
|
44
44
|
| Provider: `copilot-subscription` | No API key — uses a GitHub Copilot subscription. | ✅ Verified this session | ✅ The Cucumber sample repo's CI uses this as its default provider |
|
|
45
45
|
| Provider: `kiro-subscription` / `codex-subscription` | Local-development-only subscription providers (Kiro, Codex) — `child_process` wrappers, no official SDK. | ✅ **Both verified end to end, authenticated (2026-08-31)** — real `kiro-cli` v2.20.1 and `codex-cli` 0.151; `doctor` `[OK] Connected`; `codex` passed a full `npx playwright test` heal-and-recover (broken locator → `HEALED [provider=codex-subscription]` → test green, cache cleared); `kiro` passed the same single-test heal. Verifying them found four bugs, all fixed (see CHANGELOG). Not yet exercised: full `npx playwright test` for `kiro`, and `suggestActionTactic` for both. | ❌ Local-only by design, never in CI |
|
|
46
|
-
| Provider: `cursor-subscription` | Local-only subscription provider (Cursor `agent` CLI),
|
|
46
|
+
| Provider: `cursor-subscription` | Local-only subscription provider (Cursor `agent` CLI), experimental. | ⚠️ **Partial (2026-08-31)** — `doctor` → `[OK] Connected`, and a real `suggestSelector` returns the correct `{strategy:"ref"}` on many calls. But in a real `npx playwright test` run the heal was declined (`stage=ai_declined`): Cursor's `agent` is an interactive assistant that frequently answers conversationally instead of with JSON, and does so more often than `kiro`/`codex`. Tried `--mode ask`, `--output-format json`, empty `--workspace` — the behaviour is the model's. Kept for user feedback with the safest invocation (`--trust --mode ask --output-format json`, read-only); docs mark it experimental and point to `kiro`/`codex`. | ❌ Not in CI |
|
|
47
47
|
| Provider: `tamash` (no AI) | Zero-dependency rule-based healing. | ✅ Verified against the full test suite in both sample repos (all files, cleared cache, run twice each for stability) | ✅ `test-tamash` added to and passing in both sample repos' CI |
|
|
48
48
|
| Non-`@playwright/test` runner support (`bindPageActions`/`bindContext`) | Manual binding for Cucumber, Jest, or a plain script. | ✅ Live-verified via the Cucumber sample repo, this session | ✅ The Cucumber sample repo's entire CI run *is* this |
|
|
49
49
|
| `waitFor()`/`dragTo`/`drop`/`expect()` exclusions | Deliberately never healed — state checks and two-sided actions can't be safely guessed at. | ✅ e2e (`wait-for-not-healed`) | ❌ No CI sample test currently exercises these specifically |
|
|
@@ -123,7 +123,7 @@ After the fixes, verified live:
|
|
|
123
123
|
returns correct answers on many calls, but a real `npx playwright test` heal was declined
|
|
124
124
|
(`stage=ai_declined`) — Cursor's `agent` frequently answers conversationally rather than with
|
|
125
125
|
JSON, more so than `kiro`/`codex`. Not tuned away by `--mode ask` / `--output-format json` /
|
|
126
|
-
empty `--workspace`.
|
|
126
|
+
empty `--workspace`. Kept as an experimental provider for user feedback; docs note `kiro`/`codex` are steadier.
|
|
127
127
|
|
|
128
128
|
**Suite-level validation of this release's changes** (the `diagnose()` + `doctor` rework, the
|
|
129
129
|
shared JSON-parser rewrite, `init-skill`, the CLI-provider fixes), run 2026-08-31 against a real
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tamash-playwright",
|
|
3
|
-
"version": "0.11.0
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "Plug and Play Self-healing for Playwright and automatically recovers broken selectors using an AI model (Ollama, OpenAI, Anthropic, Gemini, or a Claude/GitHub Copilot subscription).",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -18,9 +18,9 @@ Ask the user which they want — don't assume:
|
|
|
18
18
|
- **Free, fastest to start**: Ollama Cloud (`HEALER_PROVIDER=ollama`) — a free API key from `ollama.com/settings/keys`.
|
|
19
19
|
- **An API-key provider they already pay for**: `openai` / `anthropic` / `gemini`.
|
|
20
20
|
- **A subscription they already have, no API key**: `claude-subscription` or `copilot-subscription` — work both locally and in CI (TypeScript only).
|
|
21
|
-
- **A
|
|
22
|
-
- **Free, zero-AI, no network call**: `tamash`
|
|
23
|
-
- **Their own self-hosted Ollama server**: `ollama-local`
|
|
21
|
+
- **A Kiro or Codex subscription instead**: `kiro-subscription` / `codex-subscription` (TypeScript only) — **local development only, never CI** (no confirmed unattended-CI auth token). Both run their CLI in a read-only mode (Codex `codex exec`'s sandbox, Kiro grants no tool trust), so a heal call can't edit files or run commands, and both answer cleanly in a few seconds. There's also `cursor-subscription`, but Cursor's `agent` is an interactive assistant that often replies conversationally instead of with the JSON the healer needs (`stage=ai_declined`) — prefer `kiro`/`codex`.
|
|
22
|
+
- **Free, zero-AI, no network call**: `tamash` — text-matches `.describe()` against the page's own accessibility tree, never guesses; a narrower success rate than an AI provider but no cost and no key at all.
|
|
23
|
+
- **Their own self-hosted Ollama server**: `ollama-local` — same shape as `ollama` but points at their own server instead of Ollama Cloud; `OLLAMA_LOCAL_API_KEY` is optional, only needed if their deployment sits behind an auth gateway.
|
|
24
24
|
|
|
25
25
|
Write (or update) `.env` from `.env.example` with their choice. **Never handle the real API key value yourself** — write the variable name with an empty value and have the user paste the real key into the file directly. Never echo a key back in chat, a commit message, a log line, or a report.
|
|
26
26
|
|