{"owner":"kubernetes-sigs","repo":"headlamp","hasSkills":true,"hasMcp":false,"mcpConfig":null,"found":["AGENTS.md",".github/copilot-instructions.md"],"skills":{"AGENTS.md":"# AGENTS.md\nversion: 1\ndefault_agent: \"@dev-agent\"\n\n> **Consulted files (agent must populate before committing):**\n> - `/backend/pkg/k8cache/cacheInvalidation.go`\n> - `/backend/pkg/kubeconfig/contextStore.go`\n>\n> **README.md files:**\n> - `/README.md` - Main project README\n> - `/frontend/README.md` - Frontend-specific README\n> - `/backend/README.md` - Backend quickstart guide\n> - `/app/README.md` - Desktop app README\n> - `/e2e-tests/README.md` - End-to-end testing README\n> - `/load-tests/README.md` - Load testing guide\n> - `/plugins/README.md` - Plugins overview\n> - `/plugins/headlamp-plugin/README.md` - Plugin development tools\n> - `/plugins/pluginctl/README.md` - Plugin control utility\n> - `/backend/pkg/telemetry/README.md` - Telemetry module\n> - `/docker-extension/README.md` - Docker extension\n> - `/charts/headlamp/README.md` - Helm chart\n> - `/backstage-test/README.md` - Backstage integration test\n> - `/tools/i18n/README.md` - Internationalization tools\n> - `/eslint-config/README.md` - ESLint configuration\n> - `/frontend/src/i18n/README.md` - Frontend i18n\n> - `/app/e2e-tests/README.md` - Desktop app e2e tests\n> - Plugin examples: `/plugins/examples/*/README.md` (multiple examples)\n>\n> **Documentation files:**\n> - `/docs/development/index.md` - Main development guide with build/run commands\n> - `/docs/development/frontend.md` - Frontend development guide\n> - `/docs/development/backend.md` - Backend development guide with testing commands\n> - `/docs/development/app.md` - Desktop app development guide\n> - `/docs/development/testing.md` - Load testing guide\n> - `/docs/development/architecture.md` - Architecture documentation\n> - `/docs/development/plugins/index.md` - Plugin system overview\n> - `/docs/development/plugins/building.md` - Plugin building guide\n> - `/docs/development/plugins/getting-started.md` - Plugin getting started\n> - `/docs/development/plugins/publishing.md` - Plugin publishing guide\n> - `/docs/development/i18n/index.md` - Internationalization guide\n> - `/docs/development/release-guide.md` - Release process\n> - `/docs/installation/index.mdx` - Installation instructions\n> - `/docs/installation/in-cluster/index.md` - In-cluster deployment\n> - `/docs/installation/desktop/index.mdx` - Desktop installation\n> - `/docs/contributing.md` - Contribution guidelines\n> - `/docs/faq.md` - Frequently asked questions\n> - `/docs/platforms.md` - Tested platforms list\n>\n> **Build/Config files:**\n> - `/package.json` - Root package with all npm scripts and Node.js version (>=20.11.1)\n> - `/backend/go.mod` - Go version (1.25.9)\n> - `/CONTRIBUTING.md` - Contributing guidelines\n> - `/OWNERS` - Code reviewers and approvers\n\n---\n\n### Agent persona and scope\n- **@dev-agent** — pragmatic, conservative, test-first, risk-averse.\n- **Scope:** propose, validate, and prepare code/docs patches; run local build/test commands; create PR drafts.\n- **Not allowed:** push images/releases, modify CI or infra, or merge without human approval.\n\n---\n\n### Explicit non-goals\nshould NOT unless explicitly requested or strictly necessary for the change\n- Propose refactors without a clear bug, performance, or maintenance justification\n- Change public APIs without explicit request\n- Reformat unrelated code\n- Rename files or symbols for stylistic reasons\n- Introduce new dependencies unless required to fix a bug or implement a requested feature and an existing dependency can not be used\n\n---\n\n### Tech stack and environment\n- **Languages:** TypeScript (frontend), Go (backend).\n- **Runtimes/tools:**\n  - Node.js >=20.11.1 (specified in `/package.json` engines field)\n  - npm >=10.0.0 (specified in `/package.json` engines field)\n  - Go 1.25.9 (specified in `/backend/go.mod`)\n- **Reproduce locally:** Use commands from `/package.json` scripts section and documentation files listed above.\n\n---\n\n### Repo map\n- **`frontend/`** — UI code (TypeScript/React); see `/frontend/README.md` and `/docs/development/frontend.md` for build/run/test commands.\n- **`backend/`** — Go server and API; see `/backend/README.md` and `/docs/development/backend.md` for server commands.\n- **`docs/`** — all developer and user docs; reference specific files under `docs/` for workflows.\n- **`plugins/`** — plugin system and examples; see `/plugins/README.md` and `/docs/development/plugins/`.\n- **`app/`** — desktop application (Electron); see `/app/README.md` and `/docs/development/app.md` for build/run/test commands.\n- **CI & infra:** `.github/workflows/`, Dockerfiles (`/Dockerfile`, `/Dockerfile.plugins`), Kubernetes manifests (`kubernetes-headlamp*.yaml`), Helm charts (`/charts/`) — treat as manual-review-only.\n\n---\n\n### Primary entry points (exact commands from repository)\n\n#### Build commands (from `/package.json` and `/docs/development/index.md`):\n- **Build everything:** `npm run build` (builds backend and frontend - from `/package.json`)\n- **Build frontend only:** `npm run frontend:build` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Build backend only:** `npm run backend:build` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Build desktop app:** `npm run app:build` (from `/package.json`)\n\n#### Run commands (from `/package.json` and `/docs/development/index.md`):\n- **Run both backend and frontend:** `npm start` (from `/package.json`, documented in `/docs/development/index.md`)\n- **Run backend only:** `npm run backend:start` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Run frontend only:** `npm run frontend:start` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Run desktop app:** `npm run app:start` (from `/package.json`)\n\n#### Test commands (from `/package.json` and `/docs/development/backend.md`):\n- **Run all tests:** `npm test` (from `/package.json`)\n- **Backend tests:** `npm run backend:test` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Backend coverage:** `npm run backend:coverage` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Backend coverage HTML:** `npm run backend:coverage:html` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Frontend tests:** `npm run frontend:test` (from `/package.json`)\n- **App unit tests:** `npm run app:test:unit` (from `/package.json`)\n- **App e2e tests:** `npm run app:test:e2e` (from `/package.json`)\n\n#### Lint commands (from `/package.json` and `/docs/development/backend.md`):\n- **Lint all:** `npm run lint` (from `/package.json`)\n- **Lint backend:** `npm run backend:lint` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Lint backend (fix):** `npm run backend:lint:fix` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Lint frontend:** `npm run frontend:lint` (from `/package.json`)\n- **Lint frontend (fix):** `npm run frontend:lint:fix` (from `/package.json`)\n- **Lint app:** `npm run app:lint` (from `/package.json`, documented in `/docs/development/app.md`)\n- **Lint app (fix):** `npm run app:lint:fix` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Format commands (from `/package.json` and `/docs/development/backend.md`):\n- **Format backend:** `npm run backend:format` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Format and lint frontend:** `npm run frontend:lint:fix` (from `/package.json`)\n- **Format app:** `npm run app:format` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Documentation generation (from `/package.json` and `/docs/development/frontend.md`):\n- **Generate API docs:** `npm run docs` (from `/package.json`, documented in `/docs/development/frontend.md`)\n\n#### Storybook (from `/package.json` and `/docs/development/frontend.md`):\n- **Run Storybook:** `npm run frontend:storybook` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Build Storybook:** `npm run frontend:build:storybook` (from `/package.json`)\n\n---\n\n### Allowed commands and CI interactions\n- **Permitted to suggest/run locally:**\n  - All npm scripts from `/package.json`\n  - Go commands: `go build`, `go test`, `go fmt` (documented in `/docs/development/backend.md`)\n  - Node/npm commands: `npm install`, `npm run build`, `npm run test`, `npm start`\n- **Require human approval:**\n  - Pushing container images (references in `/docs/development/index.md`)\n  - Publishing releases (process documented in `/docs/development/release-guide.md`)\n  - Modifying `.github/workflows/*`\n  - Changing `Dockerfile` or `/Dockerfile.plugins`\n  - Altering Kubernetes manifests (`kubernetes-headlamp*.yaml`)\n  - Modifying Helm charts in `/charts/`\n- **Reporting CI results:** GitHub Actions workflows in `.github/workflows/` - summarize failing steps, include logs, recommend fixes with local reproduction commands.\n\n---\n\n### Change rules and safety constraints\n- **Manual-review-only:**\n  - `.github/workflows/*` - CI workflows\n  - `Dockerfile`, `Dockerfile.plugins` - container definitions\n  - `charts/` - Helm charts\n  - `kubernetes-*.yaml` - Kubernetes manifests\n  - `SECURITY.md`, `SECURITY_CONTACTS` - security policy files\n  - `OWNERS`, `OWNERS_ALIASES` - maintainer lists (documented in `/OWNERS`)\n  - `LICENSE`, `NOTICE` - license files\n  - `code-of-conduct.md` - code of conduct\n- **Pre-change checks:**\n  - Run `npm run lint` (from `/package.json`)\n  - Run `npm test` (from `/package.json`)\n  - Run `npm run backend:test` for backend changes (from `/package.json`)\n  - Run `npm run frontend:test` for frontend changes (from `/package.json`)\n  - Run `npm run backend:format` for backend code formatting (from `/package.json`)\n  - Run `npm run frontend:lint:fix` for frontend code formatting (from `/package.json`)\n  - Run TypeScript compiler: `npm run frontend:tsc` (from `/package.json`) or `npm run app:tsc` (from `/package.json`)\n  - Run e2e tests for UI changes: `npm run app:test:e2e` (from `/package.json`)\n- **Dependency updates:**\n  - Run full test suite: `npm test`\n  - Tag maintainers from `/OWNERS` (headlamp-maintainers, headlamp-reviewers)\n  - Do not bump major versions without approval\n- **Licenses/copyright:**\n  - Do not alter `/LICENSE` or `/NOTICE` files\n  - Do not modify copyright headers\n\n---\n\n### Best practices and coding guidelines\n- **Reduce solution size:**\n  - Make minimal, surgical changes - modify as few lines as possible to achieve the goal\n  - Prefer focused, single-purpose changes over large refactors\n  - Break down complex changes into smaller, reviewable increments\n  - Remove unnecessary code, dependencies, or complexity when fixing issues\n- **Testing best practices:**\n  - Avoid using mocks in tests if possible - prefer testing with real implementations\n  - Use integration tests over unit tests when it improves test reliability\n  - Only mock external dependencies (APIs, databases, file systems) when necessary\n  - Write tests that validate actual behavior, not implementation details\n- **Consider best practices for the type of change:**\n  - **Bug fixes:** Add regression tests, verify the fix doesn't break existing functionality\n  - **New features:** Follow existing patterns, add comprehensive tests, update documentation\n  - **Refactoring:** Ensure behavior remains unchanged, validate with existing tests\n  - **Performance:** Add benchmarks, measure before and after, document improvements\n  - **Security:** Follow secure coding practices, validate inputs, avoid common vulnerabilities\n  - **Documentation:** Keep it concise, accurate, and consistent with code examples\n- **Frontend-specific guidelines:**\n  - **Screenshots:** Always include screenshots for UI changes in PRs to show visual impact\n  - **React components:** Add Storybook stories with error and loading states for new components (use `npm run frontend:storybook`)\n  - **Formatting:** Run `npm run frontend:lint:fix` to format code before committing\n  - **End-to-end tests:** For significant UI changes, consider adding or updating e2e tests (`npm run app:test:e2e`)\n\n---\n\n### Examples and templates\n\n#### Example 1: Small frontend code fix\n- **Files to change:** `frontend/src/components/Example.tsx` (example path)\n- **Rationale:** Fix null-check to avoid runtime error\n- **Commands to validate:**\n  1. `npm run frontend:install` (from `/package.json`)\n  2. `npm run frontend:lint:fix` (from `/package.json`) - format code\n  3. `npm run frontend:lint` (from `/package.json`)\n  4. `npm run frontend:test` (from `/package.json`)\n  5. `npm run frontend:tsc` (from `/package.json`)\n  6. `npm run app:test:e2e` (from `/package.json`) - if UI changes\n- **Additional requirements:**\n  - Include screenshots of any UI changes in the PR\n  - If adding/modifying React components, add Storybook stories with error and loading states\n\n#### Example 2: Backend code fix\n- **Files to change:** `backend/pkg/example/handler.go` (example path)\n- **Rationale:** Fix error handling in API endpoint\n- **Commands to validate:**\n  1. `npm run backend:build` (from `/package.json`, documented in `/docs/development/backend.md`)\n  2. `npm run backend:lint` (from `/package.json`, documented in `/docs/development/backend.md`)\n  3. `npm run backend:test` (from `/package.json`, documented in `/docs/development/backend.md`)\n  4. `npm run backend:format` (from `/package.json`, documented in `/docs/development/backend.md`)\n\n#### Example 3: Desktop app code fix\n- **Files to change:** `app/electron/example.ts` (example path)\n- **Rationale:** Fix window management issue in Electron app\n- **Commands to validate:**\n  1. `npm run app:install` (from `/package.json`)\n  2. `npm run app:lint:fix` (from `/package.json`, documented in `/docs/development/app.md`)\n  3. `npm run app:format` (from `/package.json`, documented in `/docs/development/app.md`)\n  4. `npm run app:lint` (from `/package.json`, documented in `/docs/development/app.md`)\n  5. `npm run app:tsc` (from `/package.json`, documented in `/docs/development/app.md`)\n  6. `npm run app:test` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Example 4: Documentation update\n- **Files to change:** `docs/development/index.md` (from consulted files list)\n- **Rationale:** Clarify local dev startup steps to match current npm scripts\n- **Commands to validate:**\n  - Run the documented commands exactly as written and confirm they succeed\n  - For doc-only changes, testing commands is sufficient; no build needed\n\n#### Example 5: Plugin development\n- **Files to change:** Plugin code in `/plugins/examples/` directory\n- **Rationale:** Add new plugin example\n- **Commands to validate:**\n  1. `cd plugins/headlamp-plugin && npm install` (from `/package.json`)\n  2. Follow plugin testing commands in `/docs/development/plugins/building.md`\n\n---\n\n### PR review and authoring policy\n\nReference sources:\n- `/.github/copilot-instructions.md` for Copilot PR review rules.\n- `/docs/contributing.md` for commit message and PR description guidance.\n- `/.github/pull_request_template.md` for PR body structure.\n\n#### Commit message format (from `/docs/contributing.md`):\n- **Format:** `<area>: <description of changes>`\n- **Examples:**\n  - `frontend: HomeButton: Fix so it navigates to home`\n  - `backend: config: Add enable-dynamic-clusters flag`\n- **Guidelines:**\n  - Use atomic commits - keep each commit focused on a single change\n  - Keep commit titles under 72 characters (soft requirement)\n  - Commit messages should explain the intention and _why_ something is done\n  - Commit titles should be meaningful and describe _what_ the commit does\n  - Use `git rebase` to squash and order commits for easy review\n  - Do not write \"Fixes #NN\" issue number in the commit message\n\n#### PR description template (from `/.github/pull_request_template.md`):\n- **Summary:** Brief description of what the change does\n- **Related Issue:** Link via `Fixes #ISSUE_NUMBER` if applicable\n- **Changes:** List of added/updated/fixed components\n- **Steps to Test:** Numbered steps to verify the changes\n- **Screenshots:** Include for UI changes\n- **Notes for the Reviewer:** Any relevant context or areas to focus on\n\n#### PR authoring guidelines (from `/docs/contributing.md`):\n- Run tests: `npm run frontend:test`, `npm run backend:test`\n- Run linters: `npm run frontend:lint`, `npm run backend:lint`\n- Summarize changes and explain _why_ they are needed\n- Provide steps to test the changes\n- Link to related issue via `Fixes #ISSUE_NUMBER`\n\n---\n\n### Agent output checklist (must pass before creating patch/PR)\n- **Summary:** one-line intent and short rationale\n- **Sources:** list consulted README/docs file paths with specific line numbers\n- **Files changed:** explicit file list with rationale for each\n- **Diff/patch:** minimal unified diff showing only necessary changes\n- **Tests:**\n  - List tests added/updated\n  - Exact commands to run them (from `/package.json`)\n  - Test results showing pass status\n- **Local validation:**\n  - Exact commands to reproduce build/test results\n  - Output showing successful execution\n  - For frontend: verify in browser at `localhost:3000` (from `/docs/development/frontend.md`)\n  - For backend: verify server starts successfully (from `/docs/development/backend.md`)\n- **CI expectations:**\n  - Which workflows in `.github/workflows/` should pass\n  - Expected test coverage (documented in `/docs/development/backend.md` lines 60-67)\n- **Reviewers:**\n  - Suggested reviewers from `/OWNERS`: headlamp-maintainers, headlamp-reviewers\n  - Tag specific maintainers for specialized areas if needed\n\n---\n\n### Appendix\n\n#### All consulted README.md files:\n1. `/README.md` - Main project README with overview, features, quickstart\n2. `/frontend/README.md` - Frontend module pointer to docs\n3. `/backend/README.md` - Backend quickstart with build/run commands\n4. `/app/README.md` - Desktop app information\n5. `/e2e-tests/README.md` - End-to-end testing guide\n6. `/load-tests/README.md` - Load testing with KWOK\n7. `/plugins/README.md` - Plugins overview\n8. `/plugins/headlamp-plugin/README.md` - Plugin development tools\n9. `/plugins/headlamp-plugin/template/README.md` - Plugin template\n10. `/plugins/pluginctl/README.md` - Plugin control utility\n11. `/backend/pkg/telemetry/README.md` - Telemetry module\n12. `/docker-extension/README.md` - Docker extension\n13. `/charts/headlamp/README.md` - Helm chart documentation\n14. `/backstage-test/README.md` - Backstage integration\n15. `/tools/i18n/README.md` - Internationalization tools\n16. `/eslint-config/README.md` - ESLint configuration\n17. `/frontend/src/i18n/README.md` - Frontend i18n\n18. `/app/e2e-tests/README.md` - Desktop app e2e tests\n19. Plugin examples in `/plugins/examples/` (activity, app-menus, change-logo, cluster-chooser, custom-theme, customizing-map, details-view, dynamic-clusters, headlamp-events, pod-counter, projects, resource-charts, sidebar, tables, ui-panels)\n\n#### Key documentation files:\n1. `/docs/development/index.md` - Primary development guide (lines 1-310)\n2. `/docs/development/frontend.md` - Frontend dev guide (lines 1-82)\n3. `/docs/development/backend.md` - Backend dev guide (lines 1-69)\n4. `/docs/development/app.md` - Desktop app dev guide\n5. `/docs/development/testing.md` - Testing guide (lines 1-83)\n6. `/docs/development/architecture.md` - System architecture\n7. `/docs/development/plugins/index.md` - Plugin system\n8. `/docs/development/plugins/building.md` - Building plugins\n9. `/docs/development/plugins/getting-started.md` - Plugin quickstart\n10. `/docs/development/plugins/publishing.md` - Publishing plugins\n11. `/docs/development/plugins/common-patterns.md` - Plugin patterns\n12. `/docs/development/i18n/index.md` - Internationalization\n13. `/docs/development/release-guide.md` - Release process\n14. `/docs/contributing.md` - Contribution guidelines\n15. `/docs/faq.md` - FAQ\n16. `/docs/platforms.md` - Tested platforms\n\n#### Versioning guidance:\n- Follow semantic versioning (documented in `/docs/development/release-guide.md`)\n- App version defined in `/app/package.json`\n- Docker image version from git tags\n- Request maintainer approval for version bumps and releases\n- Release process documented in `/docs/development/release-guide.md`\n\n---\n\n## Final instructions for the agent (implementation complete)\n1. ✅ **Searched the repository** for all `README.md` files and files under `docs/` - listed their relative paths in \"Consulted files\" section above\n2. ✅ **Extracted exact commands and versions** from package.json, go.mod, and documentation - replaced all placeholders with exact text and file path citations\n3. ✅ **Commands are ready for validation** - all commands listed can be run locally following the exact syntax provided\n4. ✅ **File is ready for commit** - consulted-files list is complete and all placeholders have been replaced with exact commands and paths from the repository\n\n**Version Information:**\n- Node.js: >=20.11.1 (from `/package.json`)\n- npm: >=10.0.0 (from `/package.json`)\n- Go: 1.25.9 (from `/backend/go.mod`)\n\n**Key Command Sources:**\n- Build/test commands: `/package.json`\n- Development workflow: `/docs/development/index.md`\n- Backend specifics: `/docs/development/backend.md`\n- Frontend specifics: `/docs/development/frontend.md`\n",".github/copilot-instructions.md":"# Copilot PR Review Instructions\n\nThese instructions apply when reviewing pull requests in this repository.\n\n## Commit History Rule (Blocking)\n\n- Inspect the PR commit range only (base..head).\n- If any merge commit exists in the PR commit range, raise a blocking review finding.\n- Ask the author to rebase onto the base branch and force-push a linear PR history.\n- Do not flag merge commits that exist only in the target branch history and are not part of the PR range.\n\n## Commit Coherence Rule\n\n- Review commit-to-commit flow in the PR range to detect when later commits fix or significantly rewrite code introduced by earlier commits in the same PR.\n- When this pattern appears, add a review finding asking the author to clean up history for readability (for example by squashing, reordering, or rebasing commits).\n- Focus on cases that make review difficult, hide regressions, or split one logical change across multiple corrective commits.\n\n## Commit Message Rule\n\n- Review commit titles and descriptions in the PR range for clarity and coherence.\n- Prefer commit titles that follow `<area>: <description of changes>`.\n- Ask for improvements when commit titles are not meaningful, are too vague, or do not describe what changed.\n- Ask for improvements when commit messages do not explain intent and why the change is needed.\n- Prefer commit titles under 72 characters.\n- Ask authors not to include `Fixes #NN` in commit messages.\n\n## Review Priorities\n\n- Prioritize correctness, behavior regressions, security risks, and missing tests.\n- Keep findings concrete and actionable, and include file and line references when possible.\n- Avoid style-only or preference-only comments unless they impact maintainability or correctness.\n\n## CI Status Rule\n\n- Review pull request CI/check status when available.\n- If checks are failing, ask the author to inspect failed workflows, share root cause, and post a fix or rerun plan.\n- If failures are clearly caused by changes in the PR, treat this as a blocking finding.\n- If CI status is unavailable in the review context, state that explicitly and ask the author to confirm CI results.\n\n## Repository Constraints To Respect\n\n- Do not approve or merge PRs on behalf of humans.\n- Treat changes to manual-review-only areas as high-risk and call for human review:\n  - `.github/workflows/*`\n  - `Dockerfile`, `Dockerfile.plugins`\n  - `charts/**`\n  - `kubernetes-*.yaml`\n  - `SECURITY.md`, `SECURITY_CONTACTS`\n  - `OWNERS`, `OWNERS_ALIASES`\n  - `LICENSE`, `NOTICE`\n  - `code-of-conduct.md`\n\n## Scope Discipline\n\n- Do not suggest unrelated refactors.\n- Do not suggest public API changes without clear request and justification.\n- Do not suggest new dependencies unless required by the requested change.\n"},"files":{"AGENTS.md":"# AGENTS.md\nversion: 1\ndefault_agent: \"@dev-agent\"\n\n> **Consulted files (agent must populate before committing):**\n> - `/backend/pkg/k8cache/cacheInvalidation.go`\n> - `/backend/pkg/kubeconfig/contextStore.go`\n>\n> **README.md files:**\n> - `/README.md` - Main project README\n> - `/frontend/README.md` - Frontend-specific README\n> - `/backend/README.md` - Backend quickstart guide\n> - `/app/README.md` - Desktop app README\n> - `/e2e-tests/README.md` - End-to-end testing README\n> - `/load-tests/README.md` - Load testing guide\n> - `/plugins/README.md` - Plugins overview\n> - `/plugins/headlamp-plugin/README.md` - Plugin development tools\n> - `/plugins/pluginctl/README.md` - Plugin control utility\n> - `/backend/pkg/telemetry/README.md` - Telemetry module\n> - `/docker-extension/README.md` - Docker extension\n> - `/charts/headlamp/README.md` - Helm chart\n> - `/backstage-test/README.md` - Backstage integration test\n> - `/tools/i18n/README.md` - Internationalization tools\n> - `/eslint-config/README.md` - ESLint configuration\n> - `/frontend/src/i18n/README.md` - Frontend i18n\n> - `/app/e2e-tests/README.md` - Desktop app e2e tests\n> - Plugin examples: `/plugins/examples/*/README.md` (multiple examples)\n>\n> **Documentation files:**\n> - `/docs/development/index.md` - Main development guide with build/run commands\n> - `/docs/development/frontend.md` - Frontend development guide\n> - `/docs/development/backend.md` - Backend development guide with testing commands\n> - `/docs/development/app.md` - Desktop app development guide\n> - `/docs/development/testing.md` - Load testing guide\n> - `/docs/development/architecture.md` - Architecture documentation\n> - `/docs/development/plugins/index.md` - Plugin system overview\n> - `/docs/development/plugins/building.md` - Plugin building guide\n> - `/docs/development/plugins/getting-started.md` - Plugin getting started\n> - `/docs/development/plugins/publishing.md` - Plugin publishing guide\n> - `/docs/development/i18n/index.md` - Internationalization guide\n> - `/docs/development/release-guide.md` - Release process\n> - `/docs/installation/index.mdx` - Installation instructions\n> - `/docs/installation/in-cluster/index.md` - In-cluster deployment\n> - `/docs/installation/desktop/index.mdx` - Desktop installation\n> - `/docs/contributing.md` - Contribution guidelines\n> - `/docs/faq.md` - Frequently asked questions\n> - `/docs/platforms.md` - Tested platforms list\n>\n> **Build/Config files:**\n> - `/package.json` - Root package with all npm scripts and Node.js version (>=20.11.1)\n> - `/backend/go.mod` - Go version (1.25.9)\n> - `/CONTRIBUTING.md` - Contributing guidelines\n> - `/OWNERS` - Code reviewers and approvers\n\n---\n\n### Agent persona and scope\n- **@dev-agent** — pragmatic, conservative, test-first, risk-averse.\n- **Scope:** propose, validate, and prepare code/docs patches; run local build/test commands; create PR drafts.\n- **Not allowed:** push images/releases, modify CI or infra, or merge without human approval.\n\n---\n\n### Explicit non-goals\nshould NOT unless explicitly requested or strictly necessary for the change\n- Propose refactors without a clear bug, performance, or maintenance justification\n- Change public APIs without explicit request\n- Reformat unrelated code\n- Rename files or symbols for stylistic reasons\n- Introduce new dependencies unless required to fix a bug or implement a requested feature and an existing dependency can not be used\n\n---\n\n### Tech stack and environment\n- **Languages:** TypeScript (frontend), Go (backend).\n- **Runtimes/tools:**\n  - Node.js >=20.11.1 (specified in `/package.json` engines field)\n  - npm >=10.0.0 (specified in `/package.json` engines field)\n  - Go 1.25.9 (specified in `/backend/go.mod`)\n- **Reproduce locally:** Use commands from `/package.json` scripts section and documentation files listed above.\n\n---\n\n### Repo map\n- **`frontend/`** — UI code (TypeScript/React); see `/frontend/README.md` and `/docs/development/frontend.md` for build/run/test commands.\n- **`backend/`** — Go server and API; see `/backend/README.md` and `/docs/development/backend.md` for server commands.\n- **`docs/`** — all developer and user docs; reference specific files under `docs/` for workflows.\n- **`plugins/`** — plugin system and examples; see `/plugins/README.md` and `/docs/development/plugins/`.\n- **`app/`** — desktop application (Electron); see `/app/README.md` and `/docs/development/app.md` for build/run/test commands.\n- **CI & infra:** `.github/workflows/`, Dockerfiles (`/Dockerfile`, `/Dockerfile.plugins`), Kubernetes manifests (`kubernetes-headlamp*.yaml`), Helm charts (`/charts/`) — treat as manual-review-only.\n\n---\n\n### Primary entry points (exact commands from repository)\n\n#### Build commands (from `/package.json` and `/docs/development/index.md`):\n- **Build everything:** `npm run build` (builds backend and frontend - from `/package.json`)\n- **Build frontend only:** `npm run frontend:build` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Build backend only:** `npm run backend:build` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Build desktop app:** `npm run app:build` (from `/package.json`)\n\n#### Run commands (from `/package.json` and `/docs/development/index.md`):\n- **Run both backend and frontend:** `npm start` (from `/package.json`, documented in `/docs/development/index.md`)\n- **Run backend only:** `npm run backend:start` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Run frontend only:** `npm run frontend:start` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Run desktop app:** `npm run app:start` (from `/package.json`)\n\n#### Test commands (from `/package.json` and `/docs/development/backend.md`):\n- **Run all tests:** `npm test` (from `/package.json`)\n- **Backend tests:** `npm run backend:test` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Backend coverage:** `npm run backend:coverage` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Backend coverage HTML:** `npm run backend:coverage:html` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Frontend tests:** `npm run frontend:test` (from `/package.json`)\n- **App unit tests:** `npm run app:test:unit` (from `/package.json`)\n- **App e2e tests:** `npm run app:test:e2e` (from `/package.json`)\n\n#### Lint commands (from `/package.json` and `/docs/development/backend.md`):\n- **Lint all:** `npm run lint` (from `/package.json`)\n- **Lint backend:** `npm run backend:lint` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Lint backend (fix):** `npm run backend:lint:fix` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Lint frontend:** `npm run frontend:lint` (from `/package.json`)\n- **Lint frontend (fix):** `npm run frontend:lint:fix` (from `/package.json`)\n- **Lint app:** `npm run app:lint` (from `/package.json`, documented in `/docs/development/app.md`)\n- **Lint app (fix):** `npm run app:lint:fix` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Format commands (from `/package.json` and `/docs/development/backend.md`):\n- **Format backend:** `npm run backend:format` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Format and lint frontend:** `npm run frontend:lint:fix` (from `/package.json`)\n- **Format app:** `npm run app:format` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Documentation generation (from `/package.json` and `/docs/development/frontend.md`):\n- **Generate API docs:** `npm run docs` (from `/package.json`, documented in `/docs/development/frontend.md`)\n\n#### Storybook (from `/package.json` and `/docs/development/frontend.md`):\n- **Run Storybook:** `npm run frontend:storybook` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Build Storybook:** `npm run frontend:build:storybook` (from `/package.json`)\n\n---\n\n### Allowed commands and CI interactions\n- **Permitted to suggest/run locally:**\n  - All npm scripts from `/package.json`\n  - Go commands: `go build`, `go test`, `go fmt` (documented in `/docs/development/backend.md`)\n  - Node/npm commands: `npm install`, `npm run build`, `npm run test`, `npm start`\n- **Require human approval:**\n  - Pushing container images (references in `/docs/development/index.md`)\n  - Publishing releases (process documented in `/docs/development/release-guide.md`)\n  - Modifying `.github/workflows/*`\n  - Changing `Dockerfile` or `/Dockerfile.plugins`\n  - Altering Kubernetes manifests (`kubernetes-headlamp*.yaml`)\n  - Modifying Helm charts in `/charts/`\n- **Reporting CI results:** GitHub Actions workflows in `.github/workflows/` - summarize failing steps, include logs, recommend fixes with local reproduction commands.\n\n---\n\n### Change rules and safety constraints\n- **Manual-review-only:**\n  - `.github/workflows/*` - CI workflows\n  - `Dockerfile`, `Dockerfile.plugins` - container definitions\n  - `charts/` - Helm charts\n  - `kubernetes-*.yaml` - Kubernetes manifests\n  - `SECURITY.md`, `SECURITY_CONTACTS` - security policy files\n  - `OWNERS`, `OWNERS_ALIASES` - maintainer lists (documented in `/OWNERS`)\n  - `LICENSE`, `NOTICE` - license files\n  - `code-of-conduct.md` - code of conduct\n- **Pre-change checks:**\n  - Run `npm run lint` (from `/package.json`)\n  - Run `npm test` (from `/package.json`)\n  - Run `npm run backend:test` for backend changes (from `/package.json`)\n  - Run `npm run frontend:test` for frontend changes (from `/package.json`)\n  - Run `npm run backend:format` for backend code formatting (from `/package.json`)\n  - Run `npm run frontend:lint:fix` for frontend code formatting (from `/package.json`)\n  - Run TypeScript compiler: `npm run frontend:tsc` (from `/package.json`) or `npm run app:tsc` (from `/package.json`)\n  - Run e2e tests for UI changes: `npm run app:test:e2e` (from `/package.json`)\n- **Dependency updates:**\n  - Run full test suite: `npm test`\n  - Tag maintainers from `/OWNERS` (headlamp-maintainers, headlamp-reviewers)\n  - Do not bump major versions without approval\n- **Licenses/copyright:**\n  - Do not alter `/LICENSE` or `/NOTICE` files\n  - Do not modify copyright headers\n\n---\n\n### Best practices and coding guidelines\n- **Reduce solution size:**\n  - Make minimal, surgical changes - modify as few lines as possible to achieve the goal\n  - Prefer focused, single-purpose changes over large refactors\n  - Break down complex changes into smaller, reviewable increments\n  - Remove unnecessary code, dependencies, or complexity when fixing issues\n- **Testing best practices:**\n  - Avoid using mocks in tests if possible - prefer testing with real implementations\n  - Use integration tests over unit tests when it improves test reliability\n  - Only mock external dependencies (APIs, databases, file systems) when necessary\n  - Write tests that validate actual behavior, not implementation details\n- **Consider best practices for the type of change:**\n  - **Bug fixes:** Add regression tests, verify the fix doesn't break existing functionality\n  - **New features:** Follow existing patterns, add comprehensive tests, update documentation\n  - **Refactoring:** Ensure behavior remains unchanged, validate with existing tests\n  - **Performance:** Add benchmarks, measure before and after, document improvements\n  - **Security:** Follow secure coding practices, validate inputs, avoid common vulnerabilities\n  - **Documentation:** Keep it concise, accurate, and consistent with code examples\n- **Frontend-specific guidelines:**\n  - **Screenshots:** Always include screenshots for UI changes in PRs to show visual impact\n  - **React components:** Add Storybook stories with error and loading states for new components (use `npm run frontend:storybook`)\n  - **Formatting:** Run `npm run frontend:lint:fix` to format code before committing\n  - **End-to-end tests:** For significant UI changes, consider adding or updating e2e tests (`npm run app:test:e2e`)\n\n---\n\n### Examples and templates\n\n#### Example 1: Small frontend code fix\n- **Files to change:** `frontend/src/components/Example.tsx` (example path)\n- **Rationale:** Fix null-check to avoid runtime error\n- **Commands to validate:**\n  1. `npm run frontend:install` (from `/package.json`)\n  2. `npm run frontend:lint:fix` (from `/package.json`) - format code\n  3. `npm run frontend:lint` (from `/package.json`)\n  4. `npm run frontend:test` (from `/package.json`)\n  5. `npm run frontend:tsc` (from `/package.json`)\n  6. `npm run app:test:e2e` (from `/package.json`) - if UI changes\n- **Additional requirements:**\n  - Include screenshots of any UI changes in the PR\n  - If adding/modifying React components, add Storybook stories with error and loading states\n\n#### Example 2: Backend code fix\n- **Files to change:** `backend/pkg/example/handler.go` (example path)\n- **Rationale:** Fix error handling in API endpoint\n- **Commands to validate:**\n  1. `npm run backend:build` (from `/package.json`, documented in `/docs/development/backend.md`)\n  2. `npm run backend:lint` (from `/package.json`, documented in `/docs/development/backend.md`)\n  3. `npm run backend:test` (from `/package.json`, documented in `/docs/development/backend.md`)\n  4. `npm run backend:format` (from `/package.json`, documented in `/docs/development/backend.md`)\n\n#### Example 3: Desktop app code fix\n- **Files to change:** `app/electron/example.ts` (example path)\n- **Rationale:** Fix window management issue in Electron app\n- **Commands to validate:**\n  1. `npm run app:install` (from `/package.json`)\n  2. `npm run app:lint:fix` (from `/package.json`, documented in `/docs/development/app.md`)\n  3. `npm run app:format` (from `/package.json`, documented in `/docs/development/app.md`)\n  4. `npm run app:lint` (from `/package.json`, documented in `/docs/development/app.md`)\n  5. `npm run app:tsc` (from `/package.json`, documented in `/docs/development/app.md`)\n  6. `npm run app:test` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Example 4: Documentation update\n- **Files to change:** `docs/development/index.md` (from consulted files list)\n- **Rationale:** Clarify local dev startup steps to match current npm scripts\n- **Commands to validate:**\n  - Run the documented commands exactly as written and confirm they succeed\n  - For doc-only changes, testing commands is sufficient; no build needed\n\n#### Example 5: Plugin development\n- **Files to change:** Plugin code in `/plugins/examples/` directory\n- **Rationale:** Add new plugin example\n- **Commands to validate:**\n  1. `cd plugins/headlamp-plugin && npm install` (from `/package.json`)\n  2. Follow plugin testing commands in `/docs/development/plugins/building.md`\n\n---\n\n### PR review and authoring policy\n\nReference sources:\n- `/.github/copilot-instructions.md` for Copilot PR review rules.\n- `/docs/contributing.md` for commit message and PR description guidance.\n- `/.github/pull_request_template.md` for PR body structure.\n\n#### Commit message format (from `/docs/contributing.md`):\n- **Format:** `<area>: <description of changes>`\n- **Examples:**\n  - `frontend: HomeButton: Fix so it navigates to home`\n  - `backend: config: Add enable-dynamic-clusters flag`\n- **Guidelines:**\n  - Use atomic commits - keep each commit focused on a single change\n  - Keep commit titles under 72 characters (soft requirement)\n  - Commit messages should explain the intention and _why_ something is done\n  - Commit titles should be meaningful and describe _what_ the commit does\n  - Use `git rebase` to squash and order commits for easy review\n  - Do not write \"Fixes #NN\" issue number in the commit message\n\n#### PR description template (from `/.github/pull_request_template.md`):\n- **Summary:** Brief description of what the change does\n- **Related Issue:** Link via `Fixes #ISSUE_NUMBER` if applicable\n- **Changes:** List of added/updated/fixed components\n- **Steps to Test:** Numbered steps to verify the changes\n- **Screenshots:** Include for UI changes\n- **Notes for the Reviewer:** Any relevant context or areas to focus on\n\n#### PR authoring guidelines (from `/docs/contributing.md`):\n- Run tests: `npm run frontend:test`, `npm run backend:test`\n- Run linters: `npm run frontend:lint`, `npm run backend:lint`\n- Summarize changes and explain _why_ they are needed\n- Provide steps to test the changes\n- Link to related issue via `Fixes #ISSUE_NUMBER`\n\n---\n\n### Agent output checklist (must pass before creating patch/PR)\n- **Summary:** one-line intent and short rationale\n- **Sources:** list consulted README/docs file paths with specific line numbers\n- **Files changed:** explicit file list with rationale for each\n- **Diff/patch:** minimal unified diff showing only necessary changes\n- **Tests:**\n  - List tests added/updated\n  - Exact commands to run them (from `/package.json`)\n  - Test results showing pass status\n- **Local validation:**\n  - Exact commands to reproduce build/test results\n  - Output showing successful execution\n  - For frontend: verify in browser at `localhost:3000` (from `/docs/development/frontend.md`)\n  - For backend: verify server starts successfully (from `/docs/development/backend.md`)\n- **CI expectations:**\n  - Which workflows in `.github/workflows/` should pass\n  - Expected test coverage (documented in `/docs/development/backend.md` lines 60-67)\n- **Reviewers:**\n  - Suggested reviewers from `/OWNERS`: headlamp-maintainers, headlamp-reviewers\n  - Tag specific maintainers for specialized areas if needed\n\n---\n\n### Appendix\n\n#### All consulted README.md files:\n1. `/README.md` - Main project README with overview, features, quickstart\n2. `/frontend/README.md` - Frontend module pointer to docs\n3. `/backend/README.md` - Backend quickstart with build/run commands\n4. `/app/README.md` - Desktop app information\n5. `/e2e-tests/README.md` - End-to-end testing guide\n6. `/load-tests/README.md` - Load testing with KWOK\n7. `/plugins/README.md` - Plugins overview\n8. `/plugins/headlamp-plugin/README.md` - Plugin development tools\n9. `/plugins/headlamp-plugin/template/README.md` - Plugin template\n10. `/plugins/pluginctl/README.md` - Plugin control utility\n11. `/backend/pkg/telemetry/README.md` - Telemetry module\n12. `/docker-extension/README.md` - Docker extension\n13. `/charts/headlamp/README.md` - Helm chart documentation\n14. `/backstage-test/README.md` - Backstage integration\n15. `/tools/i18n/README.md` - Internationalization tools\n16. `/eslint-config/README.md` - ESLint configuration\n17. `/frontend/src/i18n/README.md` - Frontend i18n\n18. `/app/e2e-tests/README.md` - Desktop app e2e tests\n19. Plugin examples in `/plugins/examples/` (activity, app-menus, change-logo, cluster-chooser, custom-theme, customizing-map, details-view, dynamic-clusters, headlamp-events, pod-counter, projects, resource-charts, sidebar, tables, ui-panels)\n\n#### Key documentation files:\n1. `/docs/development/index.md` - Primary development guide (lines 1-310)\n2. `/docs/development/frontend.md` - Frontend dev guide (lines 1-82)\n3. `/docs/development/backend.md` - Backend dev guide (lines 1-69)\n4. `/docs/development/app.md` - Desktop app dev guide\n5. `/docs/development/testing.md` - Testing guide (lines 1-83)\n6. `/docs/development/architecture.md` - System architecture\n7. `/docs/development/plugins/index.md` - Plugin system\n8. `/docs/development/plugins/building.md` - Building plugins\n9. `/docs/development/plugins/getting-started.md` - Plugin quickstart\n10. `/docs/development/plugins/publishing.md` - Publishing plugins\n11. `/docs/development/plugins/common-patterns.md` - Plugin patterns\n12. `/docs/development/i18n/index.md` - Internationalization\n13. `/docs/development/release-guide.md` - Release process\n14. `/docs/contributing.md` - Contribution guidelines\n15. `/docs/faq.md` - FAQ\n16. `/docs/platforms.md` - Tested platforms\n\n#### Versioning guidance:\n- Follow semantic versioning (documented in `/docs/development/release-guide.md`)\n- App version defined in `/app/package.json`\n- Docker image version from git tags\n- Request maintainer approval for version bumps and releases\n- Release process documented in `/docs/development/release-guide.md`\n\n---\n\n## Final instructions for the agent (implementation complete)\n1. ✅ **Searched the repository** for all `README.md` files and files under `docs/` - listed their relative paths in \"Consulted files\" section above\n2. ✅ **Extracted exact commands and versions** from package.json, go.mod, and documentation - replaced all placeholders with exact text and file path citations\n3. ✅ **Commands are ready for validation** - all commands listed can be run locally following the exact syntax provided\n4. ✅ **File is ready for commit** - consulted-files list is complete and all placeholders have been replaced with exact commands and paths from the repository\n\n**Version Information:**\n- Node.js: >=20.11.1 (from `/package.json`)\n- npm: >=10.0.0 (from `/package.json`)\n- Go: 1.25.9 (from `/backend/go.mod`)\n\n**Key Command Sources:**\n- Build/test commands: `/package.json`\n- Development workflow: `/docs/development/index.md`\n- Backend specifics: `/docs/development/backend.md`\n- Frontend specifics: `/docs/development/frontend.md`\n",".github/copilot-instructions.md":"# Copilot PR Review Instructions\n\nThese instructions apply when reviewing pull requests in this repository.\n\n## Commit History Rule (Blocking)\n\n- Inspect the PR commit range only (base..head).\n- If any merge commit exists in the PR commit range, raise a blocking review finding.\n- Ask the author to rebase onto the base branch and force-push a linear PR history.\n- Do not flag merge commits that exist only in the target branch history and are not part of the PR range.\n\n## Commit Coherence Rule\n\n- Review commit-to-commit flow in the PR range to detect when later commits fix or significantly rewrite code introduced by earlier commits in the same PR.\n- When this pattern appears, add a review finding asking the author to clean up history for readability (for example by squashing, reordering, or rebasing commits).\n- Focus on cases that make review difficult, hide regressions, or split one logical change across multiple corrective commits.\n\n## Commit Message Rule\n\n- Review commit titles and descriptions in the PR range for clarity and coherence.\n- Prefer commit titles that follow `<area>: <description of changes>`.\n- Ask for improvements when commit titles are not meaningful, are too vague, or do not describe what changed.\n- Ask for improvements when commit messages do not explain intent and why the change is needed.\n- Prefer commit titles under 72 characters.\n- Ask authors not to include `Fixes #NN` in commit messages.\n\n## Review Priorities\n\n- Prioritize correctness, behavior regressions, security risks, and missing tests.\n- Keep findings concrete and actionable, and include file and line references when possible.\n- Avoid style-only or preference-only comments unless they impact maintainability or correctness.\n\n## CI Status Rule\n\n- Review pull request CI/check status when available.\n- If checks are failing, ask the author to inspect failed workflows, share root cause, and post a fix or rerun plan.\n- If failures are clearly caused by changes in the PR, treat this as a blocking finding.\n- If CI status is unavailable in the review context, state that explicitly and ask the author to confirm CI results.\n\n## Repository Constraints To Respect\n\n- Do not approve or merge PRs on behalf of humans.\n- Treat changes to manual-review-only areas as high-risk and call for human review:\n  - `.github/workflows/*`\n  - `Dockerfile`, `Dockerfile.plugins`\n  - `charts/**`\n  - `kubernetes-*.yaml`\n  - `SECURITY.md`, `SECURITY_CONTACTS`\n  - `OWNERS`, `OWNERS_ALIASES`\n  - `LICENSE`, `NOTICE`\n  - `code-of-conduct.md`\n\n## Scope Discipline\n\n- Do not suggest unrelated refactors.\n- Do not suggest public API changes without clear request and justification.\n- Do not suggest new dependencies unless required by the requested change.\n"},"items":[{"name":"AGENTS.md","path":"AGENTS.md","title":"AGENTS.md","content":"# AGENTS.md\nversion: 1\ndefault_agent: \"@dev-agent\"\n\n> **Consulted files (agent must populate before committing):**\n> - `/backend/pkg/k8cache/cacheInvalidation.go`\n> - `/backend/pkg/kubeconfig/contextStore.go`\n>\n> **README.md files:**\n> - `/README.md` - Main project README\n> - `/frontend/README.md` - Frontend-specific README\n> - `/backend/README.md` - Backend quickstart guide\n> - `/app/README.md` - Desktop app README\n> - `/e2e-tests/README.md` - End-to-end testing README\n> - `/load-tests/README.md` - Load testing guide\n> - `/plugins/README.md` - Plugins overview\n> - `/plugins/headlamp-plugin/README.md` - Plugin development tools\n> - `/plugins/pluginctl/README.md` - Plugin control utility\n> - `/backend/pkg/telemetry/README.md` - Telemetry module\n> - `/docker-extension/README.md` - Docker extension\n> - `/charts/headlamp/README.md` - Helm chart\n> - `/backstage-test/README.md` - Backstage integration test\n> - `/tools/i18n/README.md` - Internationalization tools\n> - `/eslint-config/README.md` - ESLint configuration\n> - `/frontend/src/i18n/README.md` - Frontend i18n\n> - `/app/e2e-tests/README.md` - Desktop app e2e tests\n> - Plugin examples: `/plugins/examples/*/README.md` (multiple examples)\n>\n> **Documentation files:**\n> - `/docs/development/index.md` - Main development guide with build/run commands\n> - `/docs/development/frontend.md` - Frontend development guide\n> - `/docs/development/backend.md` - Backend development guide with testing commands\n> - `/docs/development/app.md` - Desktop app development guide\n> - `/docs/development/testing.md` - Load testing guide\n> - `/docs/development/architecture.md` - Architecture documentation\n> - `/docs/development/plugins/index.md` - Plugin system overview\n> - `/docs/development/plugins/building.md` - Plugin building guide\n> - `/docs/development/plugins/getting-started.md` - Plugin getting started\n> - `/docs/development/plugins/publishing.md` - Plugin publishing guide\n> - `/docs/development/i18n/index.md` - Internationalization guide\n> - `/docs/development/release-guide.md` - Release process\n> - `/docs/installation/index.mdx` - Installation instructions\n> - `/docs/installation/in-cluster/index.md` - In-cluster deployment\n> - `/docs/installation/desktop/index.mdx` - Desktop installation\n> - `/docs/contributing.md` - Contribution guidelines\n> - `/docs/faq.md` - Frequently asked questions\n> - `/docs/platforms.md` - Tested platforms list\n>\n> **Build/Config files:**\n> - `/package.json` - Root package with all npm scripts and Node.js version (>=20.11.1)\n> - `/backend/go.mod` - Go version (1.25.9)\n> - `/CONTRIBUTING.md` - Contributing guidelines\n> - `/OWNERS` - Code reviewers and approvers\n\n---\n\n### Agent persona and scope\n- **@dev-agent** — pragmatic, conservative, test-first, risk-averse.\n- **Scope:** propose, validate, and prepare code/docs patches; run local build/test commands; create PR drafts.\n- **Not allowed:** push images/releases, modify CI or infra, or merge without human approval.\n\n---\n\n### Explicit non-goals\nshould NOT unless explicitly requested or strictly necessary for the change\n- Propose refactors without a clear bug, performance, or maintenance justification\n- Change public APIs without explicit request\n- Reformat unrelated code\n- Rename files or symbols for stylistic reasons\n- Introduce new dependencies unless required to fix a bug or implement a requested feature and an existing dependency can not be used\n\n---\n\n### Tech stack and environment\n- **Languages:** TypeScript (frontend), Go (backend).\n- **Runtimes/tools:**\n  - Node.js >=20.11.1 (specified in `/package.json` engines field)\n  - npm >=10.0.0 (specified in `/package.json` engines field)\n  - Go 1.25.9 (specified in `/backend/go.mod`)\n- **Reproduce locally:** Use commands from `/package.json` scripts section and documentation files listed above.\n\n---\n\n### Repo map\n- **`frontend/`** — UI code (TypeScript/React); see `/frontend/README.md` and `/docs/development/frontend.md` for build/run/test commands.\n- **`backend/`** — Go server and API; see `/backend/README.md` and `/docs/development/backend.md` for server commands.\n- **`docs/`** — all developer and user docs; reference specific files under `docs/` for workflows.\n- **`plugins/`** — plugin system and examples; see `/plugins/README.md` and `/docs/development/plugins/`.\n- **`app/`** — desktop application (Electron); see `/app/README.md` and `/docs/development/app.md` for build/run/test commands.\n- **CI & infra:** `.github/workflows/`, Dockerfiles (`/Dockerfile`, `/Dockerfile.plugins`), Kubernetes manifests (`kubernetes-headlamp*.yaml`), Helm charts (`/charts/`) — treat as manual-review-only.\n\n---\n\n### Primary entry points (exact commands from repository)\n\n#### Build commands (from `/package.json` and `/docs/development/index.md`):\n- **Build everything:** `npm run build` (builds backend and frontend - from `/package.json`)\n- **Build frontend only:** `npm run frontend:build` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Build backend only:** `npm run backend:build` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Build desktop app:** `npm run app:build` (from `/package.json`)\n\n#### Run commands (from `/package.json` and `/docs/development/index.md`):\n- **Run both backend and frontend:** `npm start` (from `/package.json`, documented in `/docs/development/index.md`)\n- **Run backend only:** `npm run backend:start` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Run frontend only:** `npm run frontend:start` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Run desktop app:** `npm run app:start` (from `/package.json`)\n\n#### Test commands (from `/package.json` and `/docs/development/backend.md`):\n- **Run all tests:** `npm test` (from `/package.json`)\n- **Backend tests:** `npm run backend:test` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Backend coverage:** `npm run backend:coverage` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Backend coverage HTML:** `npm run backend:coverage:html` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Frontend tests:** `npm run frontend:test` (from `/package.json`)\n- **App unit tests:** `npm run app:test:unit` (from `/package.json`)\n- **App e2e tests:** `npm run app:test:e2e` (from `/package.json`)\n\n#### Lint commands (from `/package.json` and `/docs/development/backend.md`):\n- **Lint all:** `npm run lint` (from `/package.json`)\n- **Lint backend:** `npm run backend:lint` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Lint backend (fix):** `npm run backend:lint:fix` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Lint frontend:** `npm run frontend:lint` (from `/package.json`)\n- **Lint frontend (fix):** `npm run frontend:lint:fix` (from `/package.json`)\n- **Lint app:** `npm run app:lint` (from `/package.json`, documented in `/docs/development/app.md`)\n- **Lint app (fix):** `npm run app:lint:fix` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Format commands (from `/package.json` and `/docs/development/backend.md`):\n- **Format backend:** `npm run backend:format` (from `/package.json`, documented in `/docs/development/backend.md`)\n- **Format and lint frontend:** `npm run frontend:lint:fix` (from `/package.json`)\n- **Format app:** `npm run app:format` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Documentation generation (from `/package.json` and `/docs/development/frontend.md`):\n- **Generate API docs:** `npm run docs` (from `/package.json`, documented in `/docs/development/frontend.md`)\n\n#### Storybook (from `/package.json` and `/docs/development/frontend.md`):\n- **Run Storybook:** `npm run frontend:storybook` (from `/package.json`, documented in `/docs/development/frontend.md`)\n- **Build Storybook:** `npm run frontend:build:storybook` (from `/package.json`)\n\n---\n\n### Allowed commands and CI interactions\n- **Permitted to suggest/run locally:**\n  - All npm scripts from `/package.json`\n  - Go commands: `go build`, `go test`, `go fmt` (documented in `/docs/development/backend.md`)\n  - Node/npm commands: `npm install`, `npm run build`, `npm run test`, `npm start`\n- **Require human approval:**\n  - Pushing container images (references in `/docs/development/index.md`)\n  - Publishing releases (process documented in `/docs/development/release-guide.md`)\n  - Modifying `.github/workflows/*`\n  - Changing `Dockerfile` or `/Dockerfile.plugins`\n  - Altering Kubernetes manifests (`kubernetes-headlamp*.yaml`)\n  - Modifying Helm charts in `/charts/`\n- **Reporting CI results:** GitHub Actions workflows in `.github/workflows/` - summarize failing steps, include logs, recommend fixes with local reproduction commands.\n\n---\n\n### Change rules and safety constraints\n- **Manual-review-only:**\n  - `.github/workflows/*` - CI workflows\n  - `Dockerfile`, `Dockerfile.plugins` - container definitions\n  - `charts/` - Helm charts\n  - `kubernetes-*.yaml` - Kubernetes manifests\n  - `SECURITY.md`, `SECURITY_CONTACTS` - security policy files\n  - `OWNERS`, `OWNERS_ALIASES` - maintainer lists (documented in `/OWNERS`)\n  - `LICENSE`, `NOTICE` - license files\n  - `code-of-conduct.md` - code of conduct\n- **Pre-change checks:**\n  - Run `npm run lint` (from `/package.json`)\n  - Run `npm test` (from `/package.json`)\n  - Run `npm run backend:test` for backend changes (from `/package.json`)\n  - Run `npm run frontend:test` for frontend changes (from `/package.json`)\n  - Run `npm run backend:format` for backend code formatting (from `/package.json`)\n  - Run `npm run frontend:lint:fix` for frontend code formatting (from `/package.json`)\n  - Run TypeScript compiler: `npm run frontend:tsc` (from `/package.json`) or `npm run app:tsc` (from `/package.json`)\n  - Run e2e tests for UI changes: `npm run app:test:e2e` (from `/package.json`)\n- **Dependency updates:**\n  - Run full test suite: `npm test`\n  - Tag maintainers from `/OWNERS` (headlamp-maintainers, headlamp-reviewers)\n  - Do not bump major versions without approval\n- **Licenses/copyright:**\n  - Do not alter `/LICENSE` or `/NOTICE` files\n  - Do not modify copyright headers\n\n---\n\n### Best practices and coding guidelines\n- **Reduce solution size:**\n  - Make minimal, surgical changes - modify as few lines as possible to achieve the goal\n  - Prefer focused, single-purpose changes over large refactors\n  - Break down complex changes into smaller, reviewable increments\n  - Remove unnecessary code, dependencies, or complexity when fixing issues\n- **Testing best practices:**\n  - Avoid using mocks in tests if possible - prefer testing with real implementations\n  - Use integration tests over unit tests when it improves test reliability\n  - Only mock external dependencies (APIs, databases, file systems) when necessary\n  - Write tests that validate actual behavior, not implementation details\n- **Consider best practices for the type of change:**\n  - **Bug fixes:** Add regression tests, verify the fix doesn't break existing functionality\n  - **New features:** Follow existing patterns, add comprehensive tests, update documentation\n  - **Refactoring:** Ensure behavior remains unchanged, validate with existing tests\n  - **Performance:** Add benchmarks, measure before and after, document improvements\n  - **Security:** Follow secure coding practices, validate inputs, avoid common vulnerabilities\n  - **Documentation:** Keep it concise, accurate, and consistent with code examples\n- **Frontend-specific guidelines:**\n  - **Screenshots:** Always include screenshots for UI changes in PRs to show visual impact\n  - **React components:** Add Storybook stories with error and loading states for new components (use `npm run frontend:storybook`)\n  - **Formatting:** Run `npm run frontend:lint:fix` to format code before committing\n  - **End-to-end tests:** For significant UI changes, consider adding or updating e2e tests (`npm run app:test:e2e`)\n\n---\n\n### Examples and templates\n\n#### Example 1: Small frontend code fix\n- **Files to change:** `frontend/src/components/Example.tsx` (example path)\n- **Rationale:** Fix null-check to avoid runtime error\n- **Commands to validate:**\n  1. `npm run frontend:install` (from `/package.json`)\n  2. `npm run frontend:lint:fix` (from `/package.json`) - format code\n  3. `npm run frontend:lint` (from `/package.json`)\n  4. `npm run frontend:test` (from `/package.json`)\n  5. `npm run frontend:tsc` (from `/package.json`)\n  6. `npm run app:test:e2e` (from `/package.json`) - if UI changes\n- **Additional requirements:**\n  - Include screenshots of any UI changes in the PR\n  - If adding/modifying React components, add Storybook stories with error and loading states\n\n#### Example 2: Backend code fix\n- **Files to change:** `backend/pkg/example/handler.go` (example path)\n- **Rationale:** Fix error handling in API endpoint\n- **Commands to validate:**\n  1. `npm run backend:build` (from `/package.json`, documented in `/docs/development/backend.md`)\n  2. `npm run backend:lint` (from `/package.json`, documented in `/docs/development/backend.md`)\n  3. `npm run backend:test` (from `/package.json`, documented in `/docs/development/backend.md`)\n  4. `npm run backend:format` (from `/package.json`, documented in `/docs/development/backend.md`)\n\n#### Example 3: Desktop app code fix\n- **Files to change:** `app/electron/example.ts` (example path)\n- **Rationale:** Fix window management issue in Electron app\n- **Commands to validate:**\n  1. `npm run app:install` (from `/package.json`)\n  2. `npm run app:lint:fix` (from `/package.json`, documented in `/docs/development/app.md`)\n  3. `npm run app:format` (from `/package.json`, documented in `/docs/development/app.md`)\n  4. `npm run app:lint` (from `/package.json`, documented in `/docs/development/app.md`)\n  5. `npm run app:tsc` (from `/package.json`, documented in `/docs/development/app.md`)\n  6. `npm run app:test` (from `/package.json`, documented in `/docs/development/app.md`)\n\n#### Example 4: Documentation update\n- **Files to change:** `docs/development/index.md` (from consulted files list)\n- **Rationale:** Clarify local dev startup steps to match current npm scripts\n- **Commands to validate:**\n  - Run the documented commands exactly as written and confirm they succeed\n  - For doc-only changes, testing commands is sufficient; no build needed\n\n#### Example 5: Plugin development\n- **Files to change:** Plugin code in `/plugins/examples/` directory\n- **Rationale:** Add new plugin example\n- **Commands to validate:**\n  1. `cd plugins/headlamp-plugin && npm install` (from `/package.json`)\n  2. Follow plugin testing commands in `/docs/development/plugins/building.md`\n\n---\n\n### PR review and authoring policy\n\nReference sources:\n- `/.github/copilot-instructions.md` for Copilot PR review rules.\n- `/docs/contributing.md` for commit message and PR description guidance.\n- `/.github/pull_request_template.md` for PR body structure.\n\n#### Commit message format (from `/docs/contributing.md`):\n- **Format:** `<area>: <description of changes>`\n- **Examples:**\n  - `frontend: HomeButton: Fix so it navigates to home`\n  - `backend: config: Add enable-dynamic-clusters flag`\n- **Guidelines:**\n  - Use atomic commits - keep each commit focused on a single change\n  - Keep commit titles under 72 characters (soft requirement)\n  - Commit messages should explain the intention and _why_ something is done\n  - Commit titles should be meaningful and describe _what_ the commit does\n  - Use `git rebase` to squash and order commits for easy review\n  - Do not write \"Fixes #NN\" issue number in the commit message\n\n#### PR description template (from `/.github/pull_request_template.md`):\n- **Summary:** Brief description of what the change does\n- **Related Issue:** Link via `Fixes #ISSUE_NUMBER` if applicable\n- **Changes:** List of added/updated/fixed components\n- **Steps to Test:** Numbered steps to verify the changes\n- **Screenshots:** Include for UI changes\n- **Notes for the Reviewer:** Any relevant context or areas to focus on\n\n#### PR authoring guidelines (from `/docs/contributing.md`):\n- Run tests: `npm run frontend:test`, `npm run backend:test`\n- Run linters: `npm run frontend:lint`, `npm run backend:lint`\n- Summarize changes and explain _why_ they are needed\n- Provide steps to test the changes\n- Link to related issue via `Fixes #ISSUE_NUMBER`\n\n---\n\n### Agent output checklist (must pass before creating patch/PR)\n- **Summary:** one-line intent and short rationale\n- **Sources:** list consulted README/docs file paths with specific line numbers\n- **Files changed:** explicit file list with rationale for each\n- **Diff/patch:** minimal unified diff showing only necessary changes\n- **Tests:**\n  - List tests added/updated\n  - Exact commands to run them (from `/package.json`)\n  - Test results showing pass status\n- **Local validation:**\n  - Exact commands to reproduce build/test results\n  - Output showing successful execution\n  - For frontend: verify in browser at `localhost:3000` (from `/docs/development/frontend.md`)\n  - For backend: verify server starts successfully (from `/docs/development/backend.md`)\n- **CI expectations:**\n  - Which workflows in `.github/workflows/` should pass\n  - Expected test coverage (documented in `/docs/development/backend.md` lines 60-67)\n- **Reviewers:**\n  - Suggested reviewers from `/OWNERS`: headlamp-maintainers, headlamp-reviewers\n  - Tag specific maintainers for specialized areas if needed\n\n---\n\n### Appendix\n\n#### All consulted README.md files:\n1. `/README.md` - Main project README with overview, features, quickstart\n2. `/frontend/README.md` - Frontend module pointer to docs\n3. `/backend/README.md` - Backend quickstart with build/run commands\n4. `/app/README.md` - Desktop app information\n5. `/e2e-tests/README.md` - End-to-end testing guide\n6. `/load-tests/README.md` - Load testing with KWOK\n7. `/plugins/README.md` - Plugins overview\n8. `/plugins/headlamp-plugin/README.md` - Plugin development tools\n9. `/plugins/headlamp-plugin/template/README.md` - Plugin template\n10. `/plugins/pluginctl/README.md` - Plugin control utility\n11. `/backend/pkg/telemetry/README.md` - Telemetry module\n12. `/docker-extension/README.md` - Docker extension\n13. `/charts/headlamp/README.md` - Helm chart documentation\n14. `/backstage-test/README.md` - Backstage integration\n15. `/tools/i18n/README.md` - Internationalization tools\n16. `/eslint-config/README.md` - ESLint configuration\n17. `/frontend/src/i18n/README.md` - Frontend i18n\n18. `/app/e2e-tests/README.md` - Desktop app e2e tests\n19. Plugin examples in `/plugins/examples/` (activity, app-menus, change-logo, cluster-chooser, custom-theme, customizing-map, details-view, dynamic-clusters, headlamp-events, pod-counter, projects, resource-charts, sidebar, tables, ui-panels)\n\n#### Key documentation files:\n1. `/docs/development/index.md` - Primary development guide (lines 1-310)\n2. `/docs/development/frontend.md` - Frontend dev guide (lines 1-82)\n3. `/docs/development/backend.md` - Backend dev guide (lines 1-69)\n4. `/docs/development/app.md` - Desktop app dev guide\n5. `/docs/development/testing.md` - Testing guide (lines 1-83)\n6. `/docs/development/architecture.md` - System architecture\n7. `/docs/development/plugins/index.md` - Plugin system\n8. `/docs/development/plugins/building.md` - Building plugins\n9. `/docs/development/plugins/getting-started.md` - Plugin quickstart\n10. `/docs/development/plugins/publishing.md` - Publishing plugins\n11. `/docs/development/plugins/common-patterns.md` - Plugin patterns\n12. `/docs/development/i18n/index.md` - Internationalization\n13. `/docs/development/release-guide.md` - Release process\n14. `/docs/contributing.md` - Contribution guidelines\n15. `/docs/faq.md` - FAQ\n16. `/docs/platforms.md` - Tested platforms\n\n#### Versioning guidance:\n- Follow semantic versioning (documented in `/docs/development/release-guide.md`)\n- App version defined in `/app/package.json`\n- Docker image version from git tags\n- Request maintainer approval for version bumps and releases\n- Release process documented in `/docs/development/release-guide.md`\n\n---\n\n## Final instructions for the agent (implementation complete)\n1. ✅ **Searched the repository** for all `README.md` files and files under `docs/` - listed their relative paths in \"Consulted files\" section above\n2. ✅ **Extracted exact commands and versions** from package.json, go.mod, and documentation - replaced all placeholders with exact text and file path citations\n3. ✅ **Commands are ready for validation** - all commands listed can be run locally following the exact syntax provided\n4. ✅ **File is ready for commit** - consulted-files list is complete and all placeholders have been replaced with exact commands and paths from the repository\n\n**Version Information:**\n- Node.js: >=20.11.1 (from `/package.json`)\n- npm: >=10.0.0 (from `/package.json`)\n- Go: 1.25.9 (from `/backend/go.mod`)\n\n**Key Command Sources:**\n- Build/test commands: `/package.json`\n- Development workflow: `/docs/development/index.md`\n- Backend specifics: `/docs/development/backend.md`\n- Frontend specifics: `/docs/development/frontend.md`\n","category":"root","tokens":5286},{"name":"copilot-instructions.md","path":".github/copilot-instructions.md","title":"copilot-instructions.md","content":"# Copilot PR Review Instructions\n\nThese instructions apply when reviewing pull requests in this repository.\n\n## Commit History Rule (Blocking)\n\n- Inspect the PR commit range only (base..head).\n- If any merge commit exists in the PR commit range, raise a blocking review finding.\n- Ask the author to rebase onto the base branch and force-push a linear PR history.\n- Do not flag merge commits that exist only in the target branch history and are not part of the PR range.\n\n## Commit Coherence Rule\n\n- Review commit-to-commit flow in the PR range to detect when later commits fix or significantly rewrite code introduced by earlier commits in the same PR.\n- When this pattern appears, add a review finding asking the author to clean up history for readability (for example by squashing, reordering, or rebasing commits).\n- Focus on cases that make review difficult, hide regressions, or split one logical change across multiple corrective commits.\n\n## Commit Message Rule\n\n- Review commit titles and descriptions in the PR range for clarity and coherence.\n- Prefer commit titles that follow `<area>: <description of changes>`.\n- Ask for improvements when commit titles are not meaningful, are too vague, or do not describe what changed.\n- Ask for improvements when commit messages do not explain intent and why the change is needed.\n- Prefer commit titles under 72 characters.\n- Ask authors not to include `Fixes #NN` in commit messages.\n\n## Review Priorities\n\n- Prioritize correctness, behavior regressions, security risks, and missing tests.\n- Keep findings concrete and actionable, and include file and line references when possible.\n- Avoid style-only or preference-only comments unless they impact maintainability or correctness.\n\n## CI Status Rule\n\n- Review pull request CI/check status when available.\n- If checks are failing, ask the author to inspect failed workflows, share root cause, and post a fix or rerun plan.\n- If failures are clearly caused by changes in the PR, treat this as a blocking finding.\n- If CI status is unavailable in the review context, state that explicitly and ask the author to confirm CI results.\n\n## Repository Constraints To Respect\n\n- Do not approve or merge PRs on behalf of humans.\n- Treat changes to manual-review-only areas as high-risk and call for human review:\n  - `.github/workflows/*`\n  - `Dockerfile`, `Dockerfile.plugins`\n  - `charts/**`\n  - `kubernetes-*.yaml`\n  - `SECURITY.md`, `SECURITY_CONTACTS`\n  - `OWNERS`, `OWNERS_ALIASES`\n  - `LICENSE`, `NOTICE`\n  - `code-of-conduct.md`\n\n## Scope Discipline\n\n- Do not suggest unrelated refactors.\n- Do not suggest public API changes without clear request and justification.\n- Do not suggest new dependencies unless required by the requested change.\n","category":".github","tokens":685}]}