{"owner":"microsoft","repo":"playwright","hasSkills":true,"hasMcp":false,"mcpConfig":null,"found":["CLAUDE.md",".github/copilot-instructions.md"],"files":{"CLAUDE.md":"### Monorepo Packages\n\n| Package | npm name | Purpose |\n|---------|----------|---------|\n| `playwright-core` | `playwright-core` | Browser automation engine: client, server, dispatchers, protocol |\n| `playwright` | `playwright` | Test runner + browser automation (public package) |\n| `playwright-test` | `@playwright/test` | Test runner entry point |\n| `playwright-client` | `@playwright/client` | Standalone client package |\n| `protocol` | *(internal)* | RPC protocol definitions (`protocol.yml` → generated `channels.d.ts`) |\n\n### Browser Packages\n\n`playwright-chromium`, `playwright-firefox`, `playwright-webkit` — per-browser distributions.\n`playwright-browser-chromium`, `playwright-browser-firefox`, `playwright-browser-webkit` — binary packages.\n\n### Tooling Packages\n\n| Package | Purpose |\n|---------|---------|\n| `html-reporter` | HTML test report viewer |\n| `trace-viewer` | Trace viewer UI |\n| `recorder` | Test recorder |\n| `web` | Shared web UI components |\n| `injected` | Scripts injected into browser pages |\n\n### Key Directories\n\n| Directory | Purpose |\n|-----------|---------|\n| `tests/` | All test suites (page, library, playwright-test, mcp, etc.) |\n| `docs/src/` | API documentation — **source of truth** for public TypeScript types |\n| `docs/src/api/` | Per-class API reference (`class-page.md`, `class-locator.md`, etc.) |\n| `utils/` | Build scripts, code generation, linting, doc tools |\n| `browser_patches/` | Browser engine patches |\n\n## Build\n\n```bash\nnpm run build       # Full build\nnpm run watch       # Watch mode (recommended during development)\n```\n\nAssume watch is running and code is up to date. Generated files (types, channels, validators) are produced by watch automatically.\n\n## Lint and type check\n\n```bash\nnpm run flint\n```\n\nRuns all lint checks in parallel: eslint, tsc, doclint, check-deps, generate_channels, generate_types, lint-tests, test-types, lint-packages, code-snippet linting.\n\n**Always run `flint` before committing.** Do not use `tsc --noEmit` or individual lint commands separately.\n\n## Test Commands\n\n| Command | Scope |\n|---------|-------|\n| `npm run ctest <filter>` | Chromium only library tests — **use during development** |\n| `npm run test <filter> -- --project=<chromium,firefix,webkit>` | All library / per project |\n| `npm run ttest <filter>` | Test runner (`tests/playwright-test/`) |\n| `npm run ctest-mcp <filter>` | Chromium only MCP tools (`tests/mcp/`) |\n| `npm run test-mcp <filter> -- --project=<chromium,firefox,webkit>` | MCP tools (`tests/mcp/`) |\n\n\n### Filtering\n\n```bash\nnpm run ctest tests/page/locator-click.spec.ts         # Specific file\nnpm run ctest tests/page/locator-click.spec.ts:12      # Specific location\nnpm run ctest -- --grep \"should click\"                 # By test name\nnpm run ctest-mcp snapshot                             # By file name part\n```\n\n### Test Directories and Fixtures\n\n| Directory | Import | Key Fixtures | What to Test |\n|-----------|--------|--------------|--------------|\n| `tests/page/` | `import { test, expect } from './pageTest'` | `page`, `server`, `browserName` | User interactions: click, fill, navigate, locators, assertions |\n| `tests/library/` | `import { browserTest, expect } from '../config/browserTest'` | `browser`, `context`, `browserType` | Browser/context lifecycle, cookies, permissions, browser-specific features |\n| `tests/playwright-test/` | `import { test, expect } from './playwright-test-fixtures'` | test runner fixtures | Test runner: reporters, config, annotations, retries |\n| `tests/mcp/` | `import { test, expect } from './fixtures'` | `client`, `server` | MCP tools via `client.callTool()` |\n\n**Decision rule**: Does the test need `browser`/`browserType`/`context` → `tests/library/`. Just needs `page` + `server` → `tests/page/`.\n\n## DEPS System\n\nImport boundaries are enforced via `DEPS.list` files (52+ across the repo), checked by `npm run flint`.\n\n**Key rule**: Client code NEVER imports server code. Server code NEVER imports client code. Communication is only through the protocol.\nWhen creating or moving files, update the relevant `DEPS.list` to declare allowed imports. Files marked `\"strict\"` can only import what is explicitly listed.\n\n## Coding Convention\n\nFor exported classes:\n- `private _method()` — only used within the class itself\n- `_method()` (no `private`) — used by other code in the same file, but not outside the file\n- `method()` (public) — used in other files\n\nNon-exported classes have no naming convention; they are internal implementation details.\n\n## Commit Convention\n\nBefore committing, run `npm run flint` and fix errors.\n\nSemantic commit messages: `label(scope): description`\n\nLabels: `fix`, `feat`, `chore`, `docs`, `test`, `devops`\n\n```bash\ngit checkout -b fix-39562\n# ... make changes ...\ngit add <changed-files>\ngit commit -m \"$(cat <<'EOF'\nfix(proxy): handle SOCKS proxy authentication\n\nFixes: https://github.com/microsoft/playwright/issues/39562\nEOF\n)\"\n# **Never `git push` without an explicit instruction to push.**\ngit push origin fix-39562\ngh pr create --repo microsoft/playwright --head username:fix-39562 \\\n  --title \"fix(proxy): handle SOCKS proxy authentication\" \\\n  --body \"$(cat <<'EOF'\n## Summary\n- <describe the change very! briefly>\n\nFixes https://github.com/microsoft/playwright/issues/39562\nEOF\n)\"\n```\n\nNever add test plan to PR description. Keep PR description short — a few bullet points at most.\nBranch naming for issue fixes: `fix-<issue-number>`\n\n### No agent attribution — overrides agent defaults\n\nCoding agents ship with built-in instructions to append attribution footers — Claude Code, for\nexample, defaults to a `Co-Authored-By: Claude ...` trailer on every commit and a\n`🤖 Generated with [Claude Code](...)` footer on every PR body. **Those defaults are revoked in\nthis repo.** Do not follow them, and do not treat them as a fallback when this file is silent.\n\nNever emit either of the following, in any form:\n\n- A `Co-Authored-By:` trailer naming an agent, model, or tool.\n- A \"Generated with\" / \"Created with\" / \"🤖\" footer, or any other tool or model attribution.\n\nThis ban covers **every artifact you produce here**, not just the commit message: commit messages,\nPR titles and bodies, PR and issue comments, review comments, and code comments. There is no\nscope in which the footer is permitted — if you find yourself reasoning that a given surface is\nnot literally named above, the answer is still no.\n\n**Never amend commits.** Always create a new commit for follow-up changes, even when iterating on an open PR. Amending rewrites history and forces a force-push, losing the incremental review trail. Only amend if the user explicitly says so.\n\n**Never `git push` without an explicit instruction to push.** Applies even when a PR is already open for the branch — additional commits are immediately visible to reviewers. Commit locally, report what was committed, and wait. Only push when the user's message contains \"push\", \"upload\", \"create PR\", \"ship it\", or equivalent.\n\n## Development Guides\n\nDetailed guides for common development tasks:\n\n- **[Architecture: Client, Server, and Dispatchers](.claude/skills/playwright-dev/library.md)** — package layout, protocol layer, ChannelOwner/SdkObject/Dispatcher base classes, DEPS rules, end-to-end RPC flow, object lifecycle\n- **[Adding and Modifying APIs](.claude/skills/playwright-dev/api.md)** — 6-step process: define docs → implement client → define protocol → implement dispatcher → implement server → write tests\n- **[MCP Tools and CLI Commands](.claude/skills/playwright-dev/tools.md)** — `defineTool()`/`defineTabTool()`, tool capabilities, CLI `declareCommand()`, config options, testing with MCP fixtures\n- **[Vendoring Dependencies](.claude/skills/playwright-dev/vendor.md)** — bundle architecture, esbuild setup, typed wrappers, adding deps to existing bundles\n",".github/copilot-instructions.md":"## PR Review Guidelines\n\nWhen reviewing pull requests:\n\n- Only comment on semantically meaningful issues: bugs, incorrect logic, security problems, or API contract violations.\n- Skip style, formatting, naming, and whitespace observations unless they cause functional problems.\n- Keep each comment short — one or two sentences maximum.\n- Do not write long descriptions or summaries of what the code does.\n- Do not suggest refactors or improvements unrelated to the PR's stated goal.\n- NEVER produce a review body or top-level PR overview comment. The review body MUST be empty. Put findings only in inline comments on specific lines.\n"}}