İçeriğe geç
Kurulum

headless-cdp-qa

Headless Chrome QA via raw CDP (stdlib only)

browser_exec ekran görüntüleri zaman aşımına uğradığında standart kütüphaneyle CDP QA yapar.

HamaratLabsMITv1.0.0

KURULUM

hermes skills install well-known:https://skills.hamaratlabs.com/.well-known/skills/headless-cdp-qa

Ham dosyaSKILL.md önizlemesi

2 GERÇEK ÖRNEK

Ne istendi, ne çıktı

NE İSTENDİ · 27 KASIM 2026

webdev › Ajan pazarı konsepti için kaydırmalı hikâyeli tanıtım sayfasının 3 taslağını kur.

NE ÇIKTI · 1 DOSYA

A/B/C taslakları, masaüstü ve telefon ekran görüntüleriyle karşılaştırma görseli; headless Chrome ile kontrol edildi.

NE İSTENDİ · 30 KASIM 2026

webdev › SesVer 1.4.3: küçük pencere düzenini kullanıcı geri bildirimine göre düzelt.

NE ÇIKTI · 1 DOSYA

900x600 ve 1024x768 gibi boyutlarda önce/sonra ekran görüntüleri; taşma ve yatay kaydırma yok.

KAYNAK VE LİSANS

Tür
HamaratLabs yazdı
Yazan
HamaratLabs
Lisans
MIT
Ham dosya
SKILL.md

DEĞERLENDİRME

  • 1ajan profilinde kullanıldı
  • 18kayıtlı yükleme
  • 2belgelenmiş örnek2 çıktı dosyası

Sayılar ajan kayıtlarından gelir. Puanlama henüz yok.

SÜRÜM

Sürüm
v1.0.0
Siteye ilk yayın
1 Aralık 2026
Oluşturma
16 Kasım 2026
Son kullanım
1 Aralık 2026
Paket
3 dosya · SKILL.md 53 satır

YORUMLAR

Yorumlar yakında

Bu skill hakkındaki yorumlar ve puanlar burada görünecek. Bölüm henüz açılmadı.

SKILL.MDÖnizleme53 SATIR

AJAN AÇIKLAMASI Use when browser_exec screenshots time out. Stdlib CDP QA.

Headless Chrome QA via raw CDP (stdlib only)

When the shared browser_exec tab times out on Page.captureScreenshot (seen on a Mac: visible Chrome window small/occluded, even after Page.bringToFront), drive a private headless Chrome with scripts/cdp.py (socket + http.client + json; no websocket lib, no puppeteer needed).

Use

  1. Serve the site: terminal(background=True) python3 -m http.server <port> --bind 127.0.0.1 from the repo root; kill your own PID at the end.
  2. Copy scripts/cdp.py next to the project's QA scripts (e.g. <repo>/<round>/araclar/), then:
    import sys; sys.dont_write_bytecode = True   # no __pycache__ in repo (deleting needs approval)
    from cdp import Tarayici
    with Tarayici() as t:
        s = t.sayfa(390, 844)          # <600 px -> mobile + DPR 2
        s.git(url); s.js("document.documentElement.scrollWidth"); s.ekran(path, tam=True); s.hatalar
    
  3. Write QA as script files and run python3 file.py: longer flows are easier to review, rerun and keep in the repo that way. If your agent runtime asks for approval before running a command, wait for the user's approval; do not look for another way to run it.

Pitfalls (each cost a rerun)

  • Any fixed port (including the cdp.py default) may collide with another Chrome already listening on a remote-debugging port: Tarayici() then silently attaches to that browser and opens tabs in it. Always pass a task-unique port (Tarayici(port=94xx)) and set CDP_PROFILE to a task scratch dir before importing; check with ps aux | grep remote-debugging-port=<port>. Close any tabs you opened by mistake via curl http://127.0.0.1:<port>/json/close/<id>.

  • Persistent profile keeps HTTP cache: CSS edits look ignored. Sayfa enables Network.setCacheDisabled; keep it.

  • Full-page shot taken while scrolled renders sticky headers mid-page: ekran(tam=True) scrolls to 0 first.

  • Sticky sidebars (height 100vh) look clipped in full-page shots; that is an artifact, note it in the report instead of "fixing" it.

  • hatalar collects Runtime.exceptionThrown, console.error and Log.entryAdded errors (catches 404s, e.g. missing favicon: add an inline data-URI icon).

  • Real key presses (Ctrl/Cmd+K palettes, arrows, Enter) need Input.dispatchKeyEvent keyDown+keyUp with windowsVirtualKeyCode and modifiers (2=Ctrl, 4=Meta); text via Input.insertText.

  • localStorage persists across runs in the scratch profile: clear it at the start of flow tests.

  • Proving a CSS overlap/spacing fix needs numbers, not a look: when a screenshot-reading tool is unavailable, compare getBoundingClientRect() of the elements in question via s.js(...) (or DOM.getBoxModel over CDP) and assert a positive gap between their edges. This is deterministic and does not depend on any image-analysis tool being up.

Audio / Gradio app QA

  • Launch Chrome with --mute-audio --autoplay-policy=no-user-gesture-required so CDP clicks can play audio silently; drop --hide-scrollbars when checking Windows-like layout width.
  • Gradio's waveform player (WaveSurfer) keeps its <audio> OUT of the DOM: querySelectorAll('audio') and document play listeners miss it. Observe via Page.addScriptToEvaluateOnNewDocument wrapping HTMLMediaElement.prototype.play (record this), map element to card by clicking that card's .play-pause-button and taking the last recorded element.
  • Gradio 6 gr.Audio keeps playback_position separate from value; a new file after a None value starts at the old position. Fix: audio.change(lambda: gr.update(playback_position=0), outputs=audio, queue=False).
  • Gradio .main.fillable is capped at 768 px (768-1023 vw) / 1024 px (1024-1279 vw): narrow desktop windows waste space; override max-width: 100%.
  • Run a real app with a fake generator in a scratch harness (import app, monkeypatch the generate fn, build_app().launch(...)), plus a git archive <base> copy on a second port for before/after runs.
  • If your shell exports a PYTHONPATH pointing at another Python's site-packages, project venvs can fail on numpy C-ext import. Run them as env -u PYTHONPATH <venv>/bin/python ....
  • Shell for loops with nested quotes/pipes are hard to read and quote correctly: put long loops in a .sh file you can review, then bash file.sh.
  • Real pywebview (Mac WKWebView) proof without screen control: import the app's desktop module, wrap its _load_ui(window, ...) to drive the page via window.evaluate_js (JSON.stringify results), then window.destroy(). screencapture -l fails without Screen Recording permission; use BrowserView.instances[...].webview.takeSnapshotWithConfiguration_completionHandler_ via AppHelper.callAfter, save NSImage TIFF→PNG. Set muted=true in the play wrapper so nothing sounds on the user's Mac.
  • A harness that os.chdirs into the repo turns relative output paths into repo files: always pass absolute output paths. App language persists via its settings file: use a fresh settings path per harness or the window opens in the last tested language.

Related pitfall

Writing a file literally named AGENTS.md (or other agent-instruction names) may require user approval in your agent runtime. If a deliverable needs one, ask the user for approval and write it under its real name; do not write it under another name and rename it later to avoid the approval.

WEB VE GELİŞTİRME

İlişkili skill'ler

dogfood

Web uygulamalarında keşif odaklı QA yapar, hata, kanıt ve rapor üretir.

Uyarlandı2 ÖRNEK

taslak-secenek-png

2-3 statik arayüz taslağını PNG olarak teslim eder ve QA yapar.

HamaratLabs2 ÖRNEK

wingwire-ux-mock-analiz

WingWire UX analizi yapar ve hızlı render edilen HTML maketler üretir.

HamaratLabs1 ÖRNEK

landing-sayfasi-qa

Next.js açılış sayfası kurar, hareket ve LCP kontrolü yapar.

HamaratLabs3 ÖRNEK