8000 feat: BrowserDb user functions in the consumer test and README (minigraf#180) by adityamukho · Pull Request #20 · project-minigraf/minigraf-wasm · GitHub
[go: up one dir, main page]

Skip to content

feat: BrowserDb user functions in the consumer test and README (minigraf#180) - #20

Merged
adityamukho merged 1 commit into
v3from
feat/180-browser-udfs
Oct 25, 2026
Merged

adityamukho merged 1 commit into
v3from
feat/180-browser-udfs

Conversation

@adityamukho
Copy link
Copy Markdown
Contributor

Step 22 of the #180 plan, after core PR 7 (project-minigraf/minigraf#757).

  • Pin: minigraf v3 7cdfcb48 → 02243f16 (#757 merge). The commits in between are #306 :limit/:order-by (query syntax only, no BrowserDb API change) and #180 PRs 1 and 7. The old pin already had every #316 change, so nothing else is needed.
  • Consumer contract (consumer-test/browser/contract.js): registers predicate adult? and aggregate product (bigint accumulator; finish checks count), and checks that a predicate that throws rejects with [QRY-014] user function \boom?` failed: boom`.
  • README: new "User functions" section with examples, value shapes, errors, lifecycle (spec §6.1), cost, and what a function may call on the database (synchronous query/prepare/exportGraph/register*; execute/checkpoint/importGraph start after the outer query).

Browser CI jobs already run on ubuntu-24.04.

Local run (headless Chromium): the consumer test fails at the old pin (mem.registerPredicate is not a function). At the new pin all 15 checks pass, including the three new ones.

Part of project-minigraf/minigraf#180.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Urda7FD9CYYoxdeGGJa11x

…raf#180)

Pins minigraf v3 to 02243f16 (#757, BrowserDb.registerPredicate /
registerAggregate). The browser consumer contract registers a predicate
and an aggregate and checks that a function that throws fails the query
with QRY-014. The README gains a "User functions" section: examples,
value shapes, errors, lifecycle, cost and what a function may call on
the database.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Urda7FD9CYYoxdeGGJa11x
@adityamukho
adityamukho merged commit 7f69e78 into v3 Oct 25, 2026
7 checks passed
@adityamukho
adityamukho deleted the feat/180-browser-udfs branch October 25, 2026 05:30
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

0