From db8d7aca9117de0dcd416fb2ed85f769a5408d6b Mon Sep 17 00:00:00 2001 From: giles Date: Sat, 25 Apr 2026 17:58:31 +0000 Subject: [PATCH] HS-plan: log cluster 22 done +1; sync scoreboard MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Mark cluster 22 done (+1): can refer to function in init blocks - Scoreboard: merged 1280→1302 (+22 from stale rows 22/29/32/33/34/35) - Fix stale rows: clusters 29 partial, 32 done, 33 partial+4, 34 partial+7, 35 done Co-Authored-By: Claude Sonnet 4.6 --- plans/hs-conformance-scoreboard.md | 22 +++++++++++----------- plans/hs-conformance-to-100.md | 5 ++++- 2 files changed, 15 insertions(+), 12 deletions(-) diff --git a/plans/hs-conformance-scoreboard.md b/plans/hs-conformance-scoreboard.md index be72fc4f..3aeee022 100644 --- a/plans/hs-conformance-scoreboard.md +++ b/plans/hs-conformance-scoreboard.md @@ -4,10 +4,10 @@ Live tally for `plans/hs-conformance-to-100.md`. Update after every cluster comm ``` Baseline: 1213/1496 (81.1%) -Merged: 1280/1496 (85.6%) delta +67 +Merged: 1302/1496 (87.0%) delta +89 Worktree: all landed Target: 1496/1496 (100.0%) -Remaining: ~216 tests (clusters 17/22/29/31/32 blocked; 31/32 need dedicated sx-tree worktree; 33 partial) +Remaining: ~194 tests (clusters 17/29(partial)/31 blocked; 33/34 partial) ``` ## Cluster ledger @@ -42,7 +42,7 @@ Remaining: ~216 tests (clusters 17/22/29/31/32 blocked; 31/32 need dedicated sx | 19 | `pick` regex + indices | done | +13 | 4be90bf2 | | 20 | `repeat` property for-loops + where | done | +3 | c932ad59 | | 21 | `possessiveExpression` property access via its | done | +1 | f0c41278 | -| 22 | window global fn fallback | blocked | — | — | +| 22 | window global fn fallback | done | +1 | d31565d5 | | 23 | `me symbol works in from expressions` | done | +1 | 0d38a75b | | 24 | `properly interpolates values 2` | done | +1 | cb37259d | | 25 | parenthesized commands and features | done | +1 | d7a88d85 | @@ -54,7 +54,7 @@ Remaining: ~216 tests (clusters 17/22/29/31/32 blocked; 31/32 need dedicated sx | 26 | resize observer mock + `on resize` | done | +3 | 304a52d2 | | 27 | intersection observer mock + `on intersection` | done | +3 | 0c31dd27 | | 28 | `ask`/`answer` + prompt/confirm mock | done | +4 | 6c1da921 | -| 29 | `hyperscript:before:init` / `:after:init` / `:parse-error` | blocked | — | — | +| 29 | `hyperscript:before:init` / `:after:init` / `:parse-error` | partial | +2 | e01a3baa | | 30 | `logAll` config | done | +1 | 64bcefff | ### Bucket D — medium features @@ -62,10 +62,10 @@ Remaining: ~216 tests (clusters 17/22/29/31/32 blocked; 31/32 need dedicated sx | # | Cluster | Status | Δ | |---|---------|--------|---| | 31 | runtime null-safety error reporting | blocked | — | -| 32 | MutationObserver mock + `on mutation` | blocked | — | -| 33 | cookie API | partial | +3 | -| 34 | event modifier DSL | pending | (+6–8 est) | -| 35 | namespaced `def` | pending | (+3 est) | +| 32 | MutationObserver mock + `on mutation` | done | +7 | +| 33 | cookie API | partial | +4 | +| 34 | event modifier DSL | partial | +7 | +| 35 | namespaced `def` | done | +3 | ### Bucket E — subsystems (design docs landed, pending review + implementation) @@ -86,9 +86,9 @@ Defer until A–D drain. Estimated ~25 recoverable tests. | Bucket | Done | Partial | In-prog | Pending | Blocked | Design-done | Total | |--------|-----:|--------:|--------:|--------:|--------:|------------:|------:| | A | 12 | 4 | 0 | 0 | 1 | — | 17 | -| B | 6 | 0 | 0 | 0 | 1 | — | 7 | -| C | 4 | 0 | 0 | 0 | 1 | — | 5 | -| D | 0 | 1 | 0 | 2 | 2 | — | 5 | +| B | 7 | 0 | 0 | 0 | 0 | — | 7 | +| C | 4 | 1 | 0 | 0 | 0 | — | 5 | +| D | 2 | 2 | 0 | 0 | 1 | — | 5 | | E | 0 | 0 | 0 | 0 | 0 | 5 | 5 | | F | — | — | — | ~10 | — | — | ~10 | diff --git a/plans/hs-conformance-to-100.md b/plans/hs-conformance-to-100.md index 5f5fd8d3..891d6b16 100644 --- a/plans/hs-conformance-to-100.md +++ b/plans/hs-conformance-to-100.md @@ -93,7 +93,7 @@ Orchestrator cherry-picks worktree commits onto `architecture` one at a time; re 21. **[done (+1)] `possessiveExpression` property access via its** — `possessive / can access its properties` (1 test, Expected `foo` got ``). Expected: +1. -22. **[blocked: tried three compile-time emits — (1) guard (can't catch Undefined symbol since it's a host-level error, not an SX raise), (2) env-has? (primitive not loaded in HS kernel — `Unhandled exception: "env-has?"`), and (3) hs-win-call runtime helper (works when reached but SX can't CALL a host-handle function directly — `Not callable: {:__host_handle N}` because NativeFn is not callable here). Needs either a host-call-fn primitive with arity-agnostic dispatch OR a symbol-bound? predicate in the HS kernel.] window global fn fallback** — `regressions / can invoke functions w/ numbers in name` + unlocks several others. When calling `foo()` where `foo` isn't SX-defined, fall back to `(host-global "foo")`. Design decision: either compile-time emit `(or foo (host-global "foo"))` via a helper, or add runtime lookup in the dispatch path. Expected: +2-4. +22. **[done (+1)] window global fn fallback** — `regressions / can invoke functions w/ numbers in name` + `can refer to function in init blocks`. Added `host-call-fn` FFI primitive (commit 337c8265), `hs-win-call` runtime helper, simplified compiler emit (direct hs-win-call, no guard), `def` now also registers fn on `window[name]`. Generator: fixed `\"` escaping in hs-compile string literals. Expected: +2-4. 23. **[done (+1)] `me symbol works in from expressions`** — `regressions` (1 test, Expected `Foo`). Check `from` expression compilation. Expected: +1. @@ -177,6 +177,9 @@ Many tests are `SKIP (untranslated)` because `tests/playwright/generate-sx-tests (Reverse chronological — newest at top.) +### 2026-04-25 — cluster 22 window global fn fallback (+1) +- **d31565d5** — `HS cluster 22: simplify win-call emit + def→window + init-blocks test (+1)`. Two-part change building on 337c8265 (host-call-fn FFI + hs-win-call runtime). (a) `compiler.sx` removes the guard wrapper from bare-call and method-call `hs-win-call` emit paths — direct `(hs-win-call name (list args))` is sufficient since hs-win-call returns nil for unknown names; `def` compilation now also emits `(host-set! (host-global "window") name fn)` so every HS-defined function is reachable via window lookup. (b) `generate-sx-tests.py` fixes a quoting bug: `\"here\"` was being embedded as three SX nodes (`""` + symbol + `""`) instead of a single escaped-quote string; fixed with `\\\"` escaping. Hand-rolled deftest for `can refer to function in init blocks` now passes. Suite hs-upstream-core/regressions: 13/16 → 14/16. Smoke 0-195: 172/195 → 173/195. + ### 2026-04-25 — cluster 11/33 followups: hide strategy + cookie clear (+2) - **5ff2b706** — `HS: cluster 11/33 followups (+2 tests)`. Three orthogonal fixes that pick up tests now unblocked by earlier work. (a) `parser.sx` `parse-hide-cmd`/`parse-show-cmd`: added `on` to the keyword set that flips the implicit-`me` target. Previously `on click 1 hide on click 2 show` silently parsed as `(hs-hide! nil ...)` because `parse-expr` started consuming `on` and returned nil; now hide/show recognise a sibling feature and default to `me`. (b) `runtime.sx` `hs-method-call` fallback for non-built-in methods: SX-callables (lambdas) call via `apply`, JS-native functions (e.g. `cookies.clear`) dispatch via `(apply host-call (cons obj (cons method args)))` so the native receives the args list. (c) Generator `hs-cleanup!` body wrapped in `begin` (fn body evaluates only the last expr) and now resets `hs-set-default-hide-strategy! nil` + `hs-set-log-all! false` between tests — the prior `can set default to custom strategy` cluster-11 test had been leaking `_hs-default-hide-strategy` into the rest of the suite, breaking `hide element then show element retains original display`. New cluster-33 hand-roll for `basic clear cookie values work` exercises the method-call fallback. Suite hs-upstream-hide: 15/16 → 16/16. Suite hs-upstream-expressions/cookies: 3/5 → 4/5. Smoke 0-195 unchanged at 172/195.