Skip to content

Watchface gate: refuse what can't be parsed or measured - #115

Merged
freethinkel merged 1 commit into
mainfrom
gate-fail-closed
Nov 22, 2026
Merged

freethinkel merged 1 commit into
mainfrom
gate-fail-closed

Conversation

@freethinkel

Copy link
Copy Markdown
Collaborator

The bug

The pre-install gate failed open. assertFlashable returned on a parse error, and the Watch 3 Pro memory budget counted whatever the parser couldn't follow as zero bytes. The face that boot-looped a Watch 3 Pro passed the gate in four shapes:

Change to that face Before After
None fitted, installs same
One byte of the footer sent untouched refused, every watch
Images in an unknown color format sent untouched refused, Watch 3 Pro
Unknown image reference type sent untouched refused, Watch 3 Pro
Main screen's layer list broken sent untouched refused, Watch 3 Pro

These are constructed files. Whether the watch's own installer would accept each one has not been tried on hardware or in the emulator.

The change

  • A file that doesn't parse goes to no watch.
  • measurable() in budget.ts: a face whose memory can't be counted doesn't go to a Watch 3 Pro. Watch Pro 2 is unaffected by this rule.
  • Both refusals are translated into the five UI languages.
  • The disconnect analytics test used to flash an empty file, which relied on the hole. It now flashes a fixture face.

Effect on existing faces

Old and new gate compared for three device values (none, Watch Pro 2, Watch 3 Pro) on the 936 catalog faces of 2026-11-22, the 100 stock faces, the 130 Watch Pro 3 faces from #49 and the 19 fixtures.

Every file parses, and no factory face changes verdict. Four catalog faces are now refused, on a Watch 3 Pro only. Each has an image reference that points at no resource:

Record Face Listed for Installs so far
dwf3dime0v738iv SoftGlow (CMF Watch 3 Pro) Watch 3 Pro 57
nv9vkdfbj4aptan Custom unset 7
cuc26dfn9965rdt Pixel Overlap Purple Watch Pro 2 6
3l3zu68h4esp842 Phone Orbit Watch Pro 2 4

Decide before merging: SoftGlow may have been working for the people who installed it. Its creator would need to repair and republish it.

Not covered

  • The 5 MB budget itself, still measured only in the emulator on firmware 1.0.1.77.
  • A watch whose advertised name isn't recognized gets no budget check.
  • A container tag not seen in any corpus could still hide images (noted at CONTAINERS).

Testing

  • New tests failed on main (5), pass here.
  • pnpm lint (0 errors), pnpm format:check, pnpm check, pnpm test (482 passed, 1 skipped), vite build.

Merging deploys fmc.tools once CI passes.

🤖 Generated with Claude Code

https://claude.ai/code/session_01CQSU8MMWXV9aP97uzpiX18

A file parseBin couldn't read went to the watch with no checks, and on a
Watch 3 Pro whatever the parser couldn't follow counted as zero bytes of
the memory budget. The face that boot-looped a Watch 3 Pro passed the gate
in four such shapes.

A file that doesn't parse now goes to no watch; one that can't be measured
doesn't go to a Watch 3 Pro.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CQSU8MMWXV9aP97uzpiX18
freethinkel added a commit to fmctools/companion that referenced this pull request Nov 22, 2026
Both apps passed a file that didn't parse, and counted whatever the parser
couldn't follow as zero bytes of a Watch 3 Pro's memory budget. Same rules
as fmctools/fmc#115, held to it by shared vectors.


Claude-Session: https://claude.ai/code/session_01CQSU8MMWXV9aP97uzpiX18

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
@freethinkel
freethinkel merged commit 266b4bf into main Nov 22, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant