From be9cc78479e24772410b402a6a88ec0f2c0b63d8 Mon Sep 17 00:00:00 2001 From: PJ Date: Sun, 16 Aug 2026 01:03:47 +0530 Subject: [PATCH] docs(skills): noUncaughtExceptions only fires on web --- skills/sanderling-spec-authoring/SKILL.md | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/skills/sanderling-spec-authoring/SKILL.md b/skills/sanderling-spec-authoring/SKILL.md index d90a040..d8be86b 100644 --- a/skills/sanderling-spec-authoring/SKILL.md +++ b/skills/sanderling-spec-authoring/SKILL.md @@ -125,12 +125,20 @@ for good the first time it holds; written inside `always` it re-arms at every step, which asks for the window to be met from everywhere. Every formula has `.implies`, `.and`, `.or`, `.not`. -The stock properties are in `@sanderling/spec/defaults`. Put -`noUncaughtExceptions` in every spec: it fails when the run captures an uncaught -throwable or a `Sanderling.reportError` call, it needs no hooks and no -calibration, and it is free. `noLogcatErrors` (also exported from -`@sanderling/spec/defaults/properties`) fails on any error-level logcat line and -is Android-only, holding vacuously elsewhere. +The stock properties are in `@sanderling/spec/defaults`. Both are cheap and both +are narrower than their names suggest, so know which platform yours runs on. + +`noUncaughtExceptions` fails when `state.exceptions` is non-empty, and today only +the web runtime fills it: `pkg/spec/src/web-runtime.ts` installs `error` and +`unhandledrejection` listeners in the page. On Android and iOS nothing populates +the field, so it holds at every step whatever the app does. Export it on web, +where it is free and real; on native, understand that a green run says nothing +about crashes. + +`noLogcatErrors` fails on any log line the driver reports at level `E`, which is +where an uncaught Java or Kotlin throwable lands, so on Android it is the closest +thing to `noUncaughtExceptions`. It holds vacuously on web and iOS. Neither +platform has an equivalent today: an iOS crash is invisible to both properties. ## What makes a good first property