Repository navigation
Update for SuperDB v0.4.0, add CI for docs and recipes - #105
Merged
Merged
Conversation
Every mdtest, skdoc example, and runnable doc snippet was re-run against the official v0.4.0 release binary. Upgrade guide: new "Changes in v0.4.0" section and quick-reference rows covering unified BSUP (with a tested migration path), pools -> tables, db attach/detach, file-extension input formats, static type checking, ok()/is_ok() replacing has()/missing()/quiet(), option types and none, greatest()/least(), time -> timestamp, the fuse/blend rename swap, flatten()/paths(), and the new SUP set/map/named-type syntax. Lists known issues observed in v0.4.0. Expert guide: updated in place for the same changes, plus new sections on option types, missing-field handling, method-style calls, -- args, and the persistent database (new "database" section slug). Recipes: ::time -> ::timestamp, sk_keys built on keys(), sk_array_append avoids a none-typed union on [], and skdoc metadata casts to "skdoc" since <skdoc> is no longer an implicit named type (parser accepts both). Tutorials: SQL joins use `is null`, SQL on JSON uses -static, debug streaming demo pins -i sup and -unbuffered, super_db_update rewritten as a tested tables walkthrough, and several pre-existing doc bugs fixed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PmeX9cMYrm5ZcCFq3zZtuD
…ream issues The miscount seen with piped numbers comes from the JSON reader splitting top-level numbers at 512 KiB buffer boundaries (files too), not from stdin auto-detection. Also link full outer join to upstream #6310 and note the timestamp subtraction regression of #1792. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PmeX9cMYrm5ZcCFq3zZtuD
CI (.github/workflows/test.yml) installs the SuperDB release pinned in .superdb-version and runs the typecheck, the recipe tests, and every mdtest example in docs/. Moving to a new SuperDB release is now: bump .superdb-version and fix what fails. - scripts/install-super.sh: installs an official super release binary - scripts/mdtest.mjs: dependency-free runner following superdb/super's mdtest conventions (bash -e -o pipefail, combined output, fails, head); `npm run test:docs` - src/docs.test.ts: every doc's superdb_version must match the pin The skdoc parser used regexes that silently dropped any example whose text contained brackets or braces (11 recipes showed no examples in skops or the MCP server), truncated descriptions at escaped quotes, and didn't decode escapes. It's now a small parser for the SUP subset skdoc uses, and a new test checks it against super's own evaluation of every skdoc record. Example assertions canonicalize the expected output with super instead of string munging, run concurrently, and now cover all recipes with examples. Doc fixes found by the stricter runs: debug.md examples with two debug operators sort their stderr (v0.4.0 interleaves them nondeterministically) and write to the test's working dir instead of /tmp; sk_fields example stores \\t so it decodes to the query text users should type. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PmeX9cMYrm5ZcCFq3zZtuD
4 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Updates all docs, tutorials, and recipes for SuperDB v0.4.0, and adds CI so the next release upgrade is "bump one file, fix what fails."
SuperDB v0.4.0 content
db attach/detach, input format from file extension, static type checking,has()/missing()/quiet()→is_ok()/ok(), option types andnone,greatest()/least(),time→timestamp, thefuse/blendrename swap,flatten()/paths(), new SUP set/map/named-type syntax. Lists known issues.--args, and the persistent database (newexpert:databaseslug).::time→::timestamp,sk_keysbuilt onkeys(),sk_array_append([], x)no longer returns anone-typed union, skdoc metadata casts to"skdoc"(bare<skdoc>is no longer an implicit named type).is null, SQL on JSON uses-static,super_db_updaterewritten as a tested tables walkthrough, and several pre-existing doc bugs fixed (collect-first query inmoar_subqueries,sup_to_bashIFS output, single-quoted SUP data inbash_to_sup,typeof()comparisons,round()output).skdoc parser fix (affects
skopsand the MCP server)The regex-based skdoc parser silently dropped examples whose text contained brackets or braces. 11 recipes (
sk_keys,sk_merge_records,sk_add_ids,sk_array_*, ...) showed no examples inskops/super_recipes. It also truncated three descriptions at escaped quotes and didn't decode escapes. It's replaced with a small parser for the SUP subset skdoc uses, and a new test checks it againstsuper's own evaluation of every skdoc record.CI
.github/workflows/test.yml: on push to main and on PRs, installs the SuperDB release pinned in.superdb-version, then runs typecheck,npm test, andnpm run test:docsscripts/install-super.sh: installs an officialsuperrelease (linux/darwin, amd64/arm64)scripts/mdtest.mjs: dependency-free runner following superdb/super's mdtest conventions; replaces needing a Go build of super fortest-doc.shsrc/docs.test.ts: every doc'ssuperdb_versionmust match the pinsuper, run concurrently (106s → 35s), and now cover every recipe with examplesvitest.config.tslimits tests tosrc/so staledist/copies don't runTest plan
npm test: 109 passed locally against v0.4.0npm run test:docs: 70/71 pass locally; the chess tutorial fetches from lichess.org, which is blocked in the dev sandbox but should work in Actionsforkstreaming demo in debug.md is timing-sensitive on small runnersKnown upstream issues (filed here for now)
{x:1, y?:none}After merge
Bump the package version and
npm publish, then bump@chrismo/superkitin superdb-mcp. Itssuper_db_*tools also need updating for v0.4.0 (-lakeis rejected, pools are now tables).Generated by Claude Code