Skip to content

Document parity infrastructure in CLAUDE.md; guard settings:check against unguarded keys#14

Merged
bnfy merged 2 commits into
mainfrom
claude/blanc-ios-port-feasibility-p9iggz
Jul 8, 2026
Merged

Document parity infrastructure in CLAUDE.md; guard settings:check against unguarded keys#14
bnfy merged 2 commits into
mainfrom
claude/blanc-ios-port-feasibility-p9iggz

Conversation

@bnfy

@bnfy bnfy commented Jul 8, 2026

Copy link
Copy Markdown
Owner

Follow-up to the merged parity work (#13).

  • CLAUDE.md — adds a "Cross-platform parity infrastructure" section documenting spec/, the tokens/settings/copy substrates (and the critical guard rule: change a desktop value → update its source-of-truth JSON or substrate:check/CI fails), the test/desktop/ harness + the BLANC_TEST-gated hook, and the parity-guards CI.
  • settings:check hardening — the settings guard validated known schema keys but ignored extra keys in settings.js DEFAULTS, so a new user-facing setting could slip through unguarded (surfaced by Ship end-to-end encrypted profile sync (v1: Favorites + settings) #12's internal _syncMeta clock, which the check silently accepted). Now every DEFAULTS key must be a schema setting or listed in schema.json's new internalDefaults allowlist (desktop-only keys not synced to mobile).

Verified: substrate:check green; the extra-key detection negative-tested (a bogus DEFAULTS key fails with an actionable message); no generated files changed.

🤖 Generated with Claude Code

https://claude.ai/code/session_01FUj45U1QdpG7LWgXRwxA6W


Generated by Claude Code

claude added 2 commits July 8, 2026 02:46
Records the spec/, tokens/, settings-schema/, copy/, and test/desktop/
work merged in PR #13 so future sessions know it exists and how to not
break it:

- spec/ is the platform-neutral source of truth (F1–F24 / D1–D14 / the
  substrates / blocking-backends design)
- the three source-of-truth substrates generate mobile Swift/Kotlin and
  GUARD the desktop against drift — the critical rule being that changing
  a token in styles.css/pages.css, a default/enum in settings.js, or a
  slash-command hint in overlay.js/shortcuts.js requires updating the
  matching JSON (or substrate:check / CI fails), since the desktop is
  guarded, not generated
- test/desktop/ + the BLANC_TEST-gated (unpackaged, exactly "1")
  test-hook.js, the only parity change to shipping code
- parity-guards.yml enforces it all on push/PR

Follow-up after the PR #13 squash-merge; branch restarted from the merged
main (0.12.0, which also carries PR #12's profile sync).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FUj45U1QdpG7LWgXRwxA6W
The settings guard validated known schema keys but ignored EXTRA keys in
settings.js DEFAULTS, so a newly added user-facing setting could slip
through unguarded (surfaced by PR #12's internal `_syncMeta` clock, which
the check silently accepted). Now every DEFAULTS key must be a known
schema setting or listed in schema.json's new `internalDefaults`
allowlist (desktop-only keys not synced to mobile — `_syncMeta` today).
The allowlist is a forcing function: adding a settings key now requires
deciding whether it's mobile-facing (→ schema) or internal (→ allowlist).

Verified: substrate:check green (with _syncMeta allowlisted); negative-
tested — a bogus DEFAULTS key fails the check with an actionable message.
No generated files changed.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FUj45U1QdpG7LWgXRwxA6W
@bnfy bnfy merged commit 34c9134 into main Jul 8, 2026
4 checks 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.

2 participants