@ait-co/devtools 0.1.40 → 0.1.41
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/README.en.md +26 -0
- package/README.md +26 -0
- package/dist/mcp/cli.js +530 -33
- package/dist/mcp/cli.js.map +1 -1
- package/dist/mcp/server.js +155 -5
- package/dist/mcp/server.js.map +1 -1
- package/dist/panel/index.js +2 -2
- package/package.json +3 -2
package/README.en.md
CHANGED
|
@@ -777,6 +777,30 @@ Please file an issue: https://github.com/apps-in-toss-community/devtools/issues
|
|
|
777
777
|
2. Updates to the latest version and runs the type check
|
|
778
778
|
3. On detecting a new version, automatically opens a GitHub Issue (including whether there are type errors)
|
|
779
779
|
|
|
780
|
+
## Fidelity QA
|
|
781
|
+
|
|
782
|
+
`scripts/fidelity-qa/` automatically measures SDK API fidelity between the mock and a real-device relay session.
|
|
783
|
+
|
|
784
|
+
```bash
|
|
785
|
+
pnpm qa:fidelity --runner=mock # mock-only (CI default, regression detection)
|
|
786
|
+
pnpm qa:fidelity --runner=relay # requires attached device (devtools MCP)
|
|
787
|
+
pnpm qa:fidelity --runner=both --diff # run both + print diff
|
|
788
|
+
pnpm qa:fidelity --include-writes # include Storage write cycle (off by default)
|
|
789
|
+
pnpm qa:fidelity --output=results.json # write JSON results to file
|
|
790
|
+
```
|
|
791
|
+
|
|
792
|
+
CI runs `pnpm qa:fidelity --runner=mock` automatically (exits 0 on a clean state).
|
|
793
|
+
|
|
794
|
+
**Diff labels**:
|
|
795
|
+
|
|
796
|
+
- `MATCH` — mock and relay values are equal
|
|
797
|
+
- `EXPECTED_MISMATCH` — known difference registered in `scripts/fidelity-qa/whitelist.json` (e.g. jsdom UA vs real WebView UA)
|
|
798
|
+
- `UNEXPECTED` — mismatch not in whitelist → exits 1 (potential regression)
|
|
799
|
+
|
|
800
|
+
**Updating the whitelist**: when an intentional difference is found during a relay session, add `{ "id": "<probe-id>", "reason": "<explanation>" }` to `scripts/fidelity-qa/whitelist.json`.
|
|
801
|
+
|
|
802
|
+
The relay runner is currently a stub (CDP Runtime.evaluate implementation is a follow-up in devtools#261).
|
|
803
|
+
|
|
780
804
|
## Contributing
|
|
781
805
|
|
|
782
806
|
### Adding a new API mock
|
|
@@ -847,6 +871,8 @@ A local browser (env 1) and a phone Toss WebView (env 2/3) both speak CDP, so ev
|
|
|
847
871
|
|
|
848
872
|
### Debug mode (CDP via Chii)
|
|
849
873
|
|
|
874
|
+
For a step-by-step walkthrough of the on-device relay debug loop (dogfood build → QR scan → relay attach) including common failure recovery, see **[`docs/dogfood-relay-loop.md`](./docs/dogfood-relay-loop.md)** (Korean). For crash triage — `list_pages.crashDetectedAt`, iOS Console.app `.ips` analysis, and the redact procedure — see **[`docs/crash-triage.md`](./docs/crash-triage.md)** (Korean).
|
|
875
|
+
|
|
850
876
|
Read-only tools only. Tools are registered in two tiers based on attach state — before attach, only the bootstrap tools (`build_attach_url`, `list_pages`) are visible; once a relay/local page attaches, the attach-dependent tools are registered dynamically in the same session via `notifications/tools/list_changed` (no session restart needed). The phone attach roundtrip is fully wired; all that remains is a single on-device acceptance run. The tool layer is CI-verified via a mockable injectable CDP connection / AIT source.
|
|
851
877
|
|
|
852
878
|
Running `devtools-mcp` as a stdio server starts a local Chii relay on an OS-assigned port and opens a cloudflared quick tunnel, printing a public `wss://*.trycloudflare.com` URL and a QR code in the terminal (secrets/auth codes are never printed). When the phone enters the dogfood entry point, the in-app attach UI connects to the relay with that URL, and the agent reads console/network/page state via `chrome-devtools-mcp`-compatible tools — diagnosing regressions without anyone watching the phone.
|
package/README.md
CHANGED
|
@@ -788,6 +788,30 @@ Please file an issue: https://github.com/apps-in-toss-community/devtools/issues
|
|
|
788
788
|
2. 최신 버전으로 업데이트 후 타입 체크 실행
|
|
789
789
|
3. 새 버전 감지 시 자동으로 GitHub Issue 생성 (타입 에러 여부 포함)
|
|
790
790
|
|
|
791
|
+
## Fidelity QA
|
|
792
|
+
|
|
793
|
+
`scripts/fidelity-qa/`는 mock SDK와 실기기 relay 사이의 **SDK API 정합성을 자동으로 측정**하는 도구다.
|
|
794
|
+
|
|
795
|
+
```bash
|
|
796
|
+
pnpm qa:fidelity --runner=mock # mock-only (CI 기본값, 회귀 감지)
|
|
797
|
+
pnpm qa:fidelity --runner=relay # 실기기 relay 필요 (devtools MCP 연결)
|
|
798
|
+
pnpm qa:fidelity --runner=both --diff # mock+relay 동시 실행 + diff 출력
|
|
799
|
+
pnpm qa:fidelity --include-writes # Storage write 사이클 포함 (기본 OFF)
|
|
800
|
+
pnpm qa:fidelity --output=results.json # JSON 결과 파일 저장
|
|
801
|
+
```
|
|
802
|
+
|
|
803
|
+
CI는 `pnpm qa:fidelity --runner=mock`을 자동 실행한다 (mock-only, exit 0이면 통과).
|
|
804
|
+
|
|
805
|
+
**Diff 레이블**:
|
|
806
|
+
|
|
807
|
+
- `MATCH` — mock과 relay 값이 동일
|
|
808
|
+
- `EXPECTED_MISMATCH` — `scripts/fidelity-qa/whitelist.json`에 등록된 알려진 차이 (예: jsdom UA vs 실 WebView UA)
|
|
809
|
+
- `UNEXPECTED` — whitelist에 없는 불일치 → exit 1 (회귀 의심)
|
|
810
|
+
|
|
811
|
+
**whitelist 갱신 절차**: relay 세션에서 의도적 차이가 발견되면 `scripts/fidelity-qa/whitelist.json`에 `{ "id": "<probe-id>", "reason": "<설명>" }`을 추가한다.
|
|
812
|
+
|
|
813
|
+
relay runner는 현재 stub (devtools#261 follow-up에서 CDP Runtime.evaluate 구현 예정).
|
|
814
|
+
|
|
791
815
|
## Contributing
|
|
792
816
|
|
|
793
817
|
### 새 API mock 추가 절차
|
|
@@ -859,6 +883,8 @@ AI 코딩 에이전트(Claude Code, Cursor 등)가 [MCP(Model Context Protocol)]
|
|
|
859
883
|
|
|
860
884
|
### Debug 모드 (CDP via Chii)
|
|
861
885
|
|
|
886
|
+
실기기 relay 디버깅 루프(dogfood 빌드 → QR 스캔 → relay attach)의 단계별 절차와 복구 방법은 **[`docs/dogfood-relay-loop.md`](./docs/dogfood-relay-loop.md)** 를 참고하세요. crash가 발생한 경우 — `list_pages.crashDetectedAt`, iOS Console.app `.ips` 분석, redact 절차를 포함한 원인 추적 절차는 **[`docs/crash-triage.md`](./docs/crash-triage.md)** 를 참고하세요.
|
|
887
|
+
|
|
862
888
|
read-only tool만 노출합니다. 도구는 attach 상태에 따라 2단계로 등록됩니다 — attach 전에는 bootstrap
|
|
863
889
|
도구(`build_attach_url`·`list_pages`)만 보이고, 릴레이/로컬 페이지가 attach되면 `notifications/tools/list_changed`로
|
|
864
890
|
attach 의존 도구가 같은 세션에서 동적 등록됩니다(세션 재시작 불필요). 폰 attach 라운드트립은 fully wired
|