diff --git a/work/projects/cpm-permanent-breakage-metric-tech-design-2026-11-10.md b/work/projects/cpm-permanent-breakage-metric-tech-design-2026-11-10.md index 209152ed..9ddd3c8c 100644 --- a/work/projects/cpm-permanent-breakage-metric-tech-design-2026-11-10.md +++ b/work/projects/cpm-permanent-breakage-metric-tech-design-2026-11-10.md @@ -41,7 +41,7 @@ Report pages that really never got the extension's answer, and tell persistent b | Navigation finished, extension loaded | The document becomes judgeable and its clock starts. If the extension loads later, the clock starts then. | | Attributed answer (dashboard refresh) | Healthy. Resets the streak. | | Document ends: new navigation or tab close | If unanswered and alive at least **30 s**: breakage. Shorter silence is not judged (it may be a slow wake). | -| Web content process terminated | Not judged. The tab's next navigation gets `reason=tab_crash`. | +| Web content process terminated | Not judged. | | Extension signals `cpmStage` = `config_unavailable` or `settings_missing` | Breakage at once, no lifetime limit. The signal normally arrives while the page is still loading, so it is remembered and applied when the page finishes. | | Answer that cannot be tied to one document | That document is not judged. | | App suspended | Nothing is judged while suspended. | @@ -63,12 +63,11 @@ Judged documents are never re-judged. Measurement state never expires (the old f | Parameter | Values | |---|---| -| `reason` | `session_restoration`, `tab_crash`, `extension_reload`, `other` (as in the episode pixel). | | `background` | `woken` (a background view was created during this navigation), `warm` (views were seen, none created for it), `unknown` (no background view seen yet). From the manager's `didCreateBackgroundWebView` callback. | `web_extension_cpm_breakage_persistent` has no parameters. `last_stage` is added by the companion design. -Dashboard: persistent installs / DAU from `breakage_persistent_daily` (the success metric); any-breakage installs / DAU from `breakage_daily`; breakages per day from `breakage_count` by `reason` and `background`. +Dashboard: persistent installs / DAU from `breakage_persistent_daily` (the success metric); any-breakage installs / DAU from `breakage_daily`; breakages per day from `breakage_count` by `background`. ### Removed in the same PR @@ -80,12 +79,14 @@ Measurements older than five minutes dropped; no minimum lifetime; tab process c ### PR stack -| PR | Content | State | +| PR | Content | State, 11 Nov | |---|---|---| | 1, [#8025](https://github.com/duckduckgo/apple-browsers/pull/8025) | Remove ineffective recovery fixes and flags | pushed, in review | -| 2, `alex/cpm-pixel-cleanup` | Remove diagnostics, trim the episode pixel | local, tests pass, not pushed | -| 3, `alex/cpm-breakage-metric` (`b8a4361c26`) | This design: new pixels and removal of the old ones, one commit | local; package tests 1013 pass; both pixel validators pass; macOS app and tests build; iOS build running; not pushed | -| 4, `alex/cpm-init-marks` (`7bb259e9cf`) | Marks and `last_stage` ([[cpm-wake-init-detection-tech-design-2026-11-10]]) | local; package tests 1023 pass; validators pass; not pushed. Extension: `alex/cpm-init-progress` has the new commit `908f9a62`, not pushed | +| 2, `alex/cpm-pixel-cleanup` (`9b7fc4b6e1`) | All removal: diagnostics, the episode pixel with its timers and the failure reason, the restart and network-recovery pixels, orphaned helpers. The monitor shrinks to matching a page with the extension's answer. | local; 999 package tests pass; macOS build running; not pushed | +| 3, `alex/cpm-breakage-metric` (`d98976fbe9`) | All addition: verdict at the end of the document, series, buffered responses, `background`, the two pixels | local; 1017 package tests pass; validators pass; not pushed | +| 4, `alex/cpm-init-marks` (`4aad5f89dd`) | Init progress marks and `last_stage`; extension #3727 | local; 1023 package tests pass; not pushed | + +Between PR 2 and PR 3 no CPM breakage pixel exists, so they must ship in the same release. ### Known limits @@ -110,7 +111,7 @@ Measurements older than five minutes dropped; no minimum lifetime; tab process c ## Testing -- Unit tests per row of the table, streak at 3 once and reset, `reason` values, `background` values, simulation switch, `cpmStage` parsing, extension reload. +- Unit tests per row of the table, streak at 3 once and reset, `background` values, simulation switch, `cpmStage` parsing, extension reload. - Pixel definitions pass both validators; parameters match what is sent. - Manual: [[CPM Breakage Testing Steps]] with the Debug switch. - Real WebKit (CPM repro harness, [PR #7378](https://github.com/duckduckgo/apple-browsers/pull/7378)): not run. diff --git a/work/projects/cpm-project-summary-2026-11-03.md b/work/projects/cpm-project-summary-2026-11-03.md index e9817d2d..2279b9c8 100644 --- a/work/projects/cpm-project-summary-2026-11-03.md +++ b/work/projects/cpm-project-summary-2026-11-03.md @@ -105,7 +105,7 @@ Open: ## 10 ноября, вечер: разрез PR и tech design -**Разрез.** Ветка `alex/cpm-breakage-pixel` (`e6419bb910`) смешивала чистку с новым пикселем и удаляла эпизодный пиксель сразу, против плана. Новая раскладка: PR 1 [#8025](https://github.com/duckduckgo/apple-browsers/pull/8025) без изменений. **PR 2** `alex/cpm-pixel-cleanup` (`f04c93730f` + `f90d321308`, поверх `6928847174`) уже содержит чистую чистку по плану: удалены recorder, `CPMMessagingDiagnostics`, delegate proxy, readiness observer и два флага с проводкой и пунктом debug-меню macOS; эпизодный пиксель урезан до `reason`, `outcome`, `tabs_affected`, `repeat_failures`, `reload_state`, без нового пикселя и без изменения таймеров. Проверено: `swift test` пакета WebExtensions 1104 теста, 0 падений; SwiftLint strict без замечаний на `CPMMessagingHealthMonitor`, `WebExtensionPixelFiring`, `WebExtensionManager`. Не проверено: сборка приложений iOS и macOS, валидатор определений пикселей (CI). Не запушена, PR не создан (нужна ссылка на задачу Asana и ревьюер; метка Danger, потому что параметры существующего пикселя меняются). **PR 3** (перманентный пиксель) и **PR 4** (метки init и `last_stage`, плюс расширение) ещё не начаты, ждут ревью tech design. Старые `alex/cpm-breakage-pixel` и `alex/cpm-init-diagnostics` остаются только источником. +**Разрез.** Ветка `alex/cpm-breakage-pixel` (`e6419bb910`) смешивала чистку с новым пикселем и удаляла эпизодный пиксель сразу, против плана. Новая раскладка: PR 1 [#8025](https://github.com/duckduckgo/apple-browsers/pull/8025) без изменений. **PR 2** `alex/cpm-pixel-cleanup` (`9b7fc4b6e1`, поверх `6928847174`) уже содержит чистую чистку по плану: удалены recorder, `CPMMessagingDiagnostics`, delegate proxy, readiness observer и два флага с проводкой и пунктом debug-меню macOS; эпизодный пиксель урезан до `reason`, `outcome`, `tabs_affected`, `repeat_failures`, `reload_state`, без нового пикселя и без изменения таймеров. Проверено: `swift test` пакета WebExtensions 1104 теста, 0 падений; SwiftLint strict без замечаний на `CPMMessagingHealthMonitor`, `WebExtensionPixelFiring`, `WebExtensionManager`. Не проверено: сборка приложений iOS и macOS, валидатор определений пикселей (CI). Не запушена, PR не создан (нужна ссылка на задачу Asana и ревьюер; метка Danger, потому что параметры существующего пикселя меняются). **PR 3** (перманентный пиксель) и **PR 4** (метки init и `last_stage`, плюс расширение) ещё не начаты, ждут ревью tech design. Старые `alex/cpm-breakage-pixel` и `alex/cpm-init-diagnostics` остаются только источником. **Что неверно в `e6419bb910`** (проверено по коду): тихие замеры старше 5 минут сбрасываются (`discardExpiredState`); нет минимального времени жизни страницы; падение процесса вкладки засчитывается поломкой; `background` берётся из «загрузка ≥ 1 с» и одного общего сигнала; страницы, живущие до выхода приложения, не оцениваются; определение macOS без `pixelSource` и `channel`, суффиксы от iOS; утечка `navigationWaitContexts`; нет теста на разбор `cpmStage`.