Skip to content

chore(showcase): seed Field Zoo with all field types + guard budget hook - #2005

Merged
os-zhuang merged 1 commit into
mainfrom
chore/showcase-field-zoo-seed
Jun 17, 2026
Merged

chore(showcase): seed Field Zoo with all field types + guard budget hook#2005
os-zhuang merged 1 commit into
mainfrom
chore/showcase-field-zoo-seed

Conversation

@os-zhuang

Copy link
Copy Markdown
Contributor

Completes the showcase capability-coverage gap found while driving it end-to-end. The Field Zoo declared all 48 field types but shipped no seed data — so no field type was ever exercised with a real value, which is exactly why the array-serialization and Field.time bugs (fixed in #2004) went unnoticed for so long.

Changes

  • Seed two Field Zoo specimens ("Full" + "Minimal") covering every input-able field type with real values:

    • arrays — multiselect / checkboxes / tags / repeater / vector
    • objects — composite / address / location / json / record
    • time14:30 / 09:05:30
    • relational — lookup → Account, master_detail → Project (by seed externalId)
    • computed — formula (= 315), autonumber (= 0001)
    • f_secret is intentionally omitted: the seed path has no CryptoProvider, so a secret value is correctly refused fail-closed.

    This doubles as a runtime regression guard — a field type that can't persist now fails the boot seed instead of shipping silently green.

  • Guard showcase_warn_over_budget with has(). A partial rollup update (the task_count recompute) fires the project afterUpdate with a record lacking spent/budget, and CEL throws "No such key" on a bare record.spent. has() is the missing-key-safe macro; the noisy warning is gone. (Hook object-scoping itself was fine — verified.)

Verification

  • Live boot: both specimens seed cleanly (no insert errors); the "Full" row has 37 populated f_* fields — f_time='14:30', f_multiselect=['red','green'], f_repeater=[{…},{…}], f_vector=[…], f_lookup/f_master_detail resolved to IDs, f_formula=315, f_autonumber='0001'.
  • After a task update, warn_over_budget "No such key" warnings = 0.
  • Coverage test: 20 green; typecheck clean.

Depends on #2004 (merged) for the array/time persistence — without it the Full specimen's array/time fields would fail to seed.

🤖 Generated with Claude Code

The Field Zoo declared all 48 field types but shipped NO seed data, so no
field type was ever exercised with a real value — which is exactly why the
array-serialization and Field.time bugs (fixed in #2004) went unnoticed.
- Seed two field-zoo specimens ("Full" + "Minimal") covering every input-able
field type with real values: arrays (multiselect/checkboxes/tags/repeater/
vector), objects (composite/address/location/json/record), time (14:30 /
09:05:30), relational (lookup→Account, master_detail→Project by externalId),
and computed (formula=315, autonumber). `f_secret` is intentionally omitted —
the seed path has no CryptoProvider so a secret value is refused fail-closed.
This doubles as a runtime regression guard: a field type that can't persist
now fails the boot seed instead of shipping silently.
- Guard the showcase_warn_over_budget hook condition with has() — a partial
rollup update (task_count recompute) fires afterUpdate with a record lacking
spent/budget, and CEL throws "No such key" on a bare record.spent. has() is
the missing-key-safe macro; the noisy warning is gone.
Verified live: both specimens seed (37 populated f_* fields on Full); coverage
test 20 green; warn_over_budget "No such key" warnings = 0 after a task update.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@vercel

vercelBot commented Jun 17, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

ProjectDeploymentActionsUpdated (UTC)
specBuildingBuildingPreview, CommentJun 17, 2026 5:35am

Request Review

@github-actionsgithub-actionsBot added documentation Improvements or additions to documentation tooling size/s labels Jun 17, 2026
@os-zhuang
os-zhuang merged commit b8471d5 into mainJun 17, 2026
11 of 12 checks passed
@os-zhuang
os-zhuang deleted the chore/showcase-field-zoo-seed branch June 17, 2026 05:38
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/stooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@os-zhuang