Prepare the 20 October table demo with same-document schemas and Atomic lib reuse #40

Merged
michielbdejong merged 5 commits from codex/colocate-atomic-schema into main 2026-10-15 15:44:42 +02:00

The table editor previously stored schemas in a separate document from its RDF rows. It now creates or reopens one YMap document for both, persists the initial Atomic JSON-AD schema before enabling edits, and reconstructs runtime shapes from verified saved revisions. Explicit graph-only documents fail visibly; existing private-store rows are not moved.

This PR prepares the Tuesday 20 October 2026 review, with a rehearsal target of Monday 19 October and 21–23 October reserved for fixes before the consortium meeting on the 26th.

The reference app is db-table-editor-atomic. Schema edits support adding string/date fields and renaming populated columns without rebuilding. Initialization failures have a retry action. Verified revision staging, stale-draft guards, migration preflight and previous revisions are preserved.

The shared SchemaTable now has an SDK-free contract: column descriptors, values, validation, record IDs and a save callback. The independent /atomic-reuse page uses that same React component with actual @tomic/lib 0.40.0 Store/Resource objects and ordinary Atomic Class/Property metadata. It demonstrates typed edits, a new text column, external updates, overlapping-write protection and failed-save retry without loading NextGraph. Its persistence is explicitly in memory; it does not claim Atomic Server transport or permissions. The small stable-lib adapter rejects unsupported Class constraints rather than silently ignoring validation; the existing upstream compatibility helpers used by the broader schema compiler remain documented.

The native acceptance test exercises runtime schema changes, same-document storage, independent verifiers using the same imported wallet, offline edits/reconnect and persistent-profile restart. The former CI failure is fixed by explicitly importing/unlocking the wallet when navigating between origins: different ports do not share wallet storage.

The review runbook contains exact launch/demo commands, the Atomic feature/version audit, storage boundaries and the proposed work-package sequence. Related PRDs now distinguish this narrow milestone from the broader future viewer and withdraw the old RDF linked-list encoding proposal.

Validation:

  • 260 unit tests pass, including the real offline NextGraph WASM schema test and new Atomic library adapter coverage.
  • All five type checks and deterministic schema/artifact generation pass.
  • All ten apps build; the final Atomic build includes /atomic-reuse.
  • The clean complete browser suite passes with retries disabled: 48 passed, four existing skips.
  • All three broker-backed native tests pass, including the new complete demo, same-wallet replication, offline edit/reconnect, schema revision reads, persistent-profile restart, distinct-wallet isolation and the existing issue-tracker checks.
  • The separate native offline-conflict characterization passes, including its test-owned broker restart.
  • Full remote CI passed on final head b8fa50d681a2ab7805e75005b8b13bd2e3c11728, including native and offline-conflict checks: run 63.

The native harness now waits for wallet import handlers to be ready before importing. User identity checks are separate from document display checks: the task grid intentionally uses its private-store graph while the expense demo selects its combined document. The older issue-tracker list-cell encoding is recorded in backlog #47 and does not gate this reference demo.

Closes #41
Closes #42
Closes #43
Closes #44

Actual Atomic Server persistence, forms and later ontology/schema/webhook research remain in #45–47.

The table editor previously stored schemas in a separate document from its RDF rows. It now creates or reopens one YMap document for both, persists the initial Atomic JSON-AD schema before enabling edits, and reconstructs runtime shapes from verified saved revisions. Explicit graph-only documents fail visibly; existing private-store rows are not moved. This PR prepares the **Tuesday 20 October 2026 review**, with a rehearsal target of Monday 19 October and **21–23 October reserved for fixes** before the consortium meeting on the 26th. The reference app is `db-table-editor-atomic`. Schema edits support adding string/date fields and renaming populated columns without rebuilding. Initialization failures have a retry action. Verified revision staging, stale-draft guards, migration preflight and previous revisions are preserved. The shared `SchemaTable` now has an SDK-free contract: column descriptors, values, validation, record IDs and a save callback. The independent `/atomic-reuse` page uses that same React component with actual `@tomic/lib` 0.40.0 Store/Resource objects and ordinary Atomic Class/Property metadata. It demonstrates typed edits, a new text column, external updates, overlapping-write protection and failed-save retry without loading NextGraph. Its persistence is explicitly in memory; it does not claim Atomic Server transport or permissions. The small stable-lib adapter rejects unsupported Class constraints rather than silently ignoring validation; the existing upstream compatibility helpers used by the broader schema compiler remain documented. The native acceptance test exercises runtime schema changes, same-document storage, independent verifiers using the same imported wallet, offline edits/reconnect and persistent-profile restart. The former CI failure is fixed by explicitly importing/unlocking the wallet when navigating between origins: different ports do not share wallet storage. [The review runbook](https://git.elfaconsortium.eu/ELFA/database-apps/src/branch/codex/colocate-atomic-schema/docs/demo-2026-10-20.md) contains exact launch/demo commands, the Atomic feature/version audit, storage boundaries and the proposed work-package sequence. Related PRDs now distinguish this narrow milestone from the broader future viewer and withdraw the old RDF linked-list encoding proposal. Validation: - 260 unit tests pass, including the real offline NextGraph WASM schema test and new Atomic library adapter coverage. - All five type checks and deterministic schema/artifact generation pass. - All ten apps build; the final Atomic build includes `/atomic-reuse`. - The clean complete browser suite passes with retries disabled: 48 passed, four existing skips. - All three broker-backed native tests pass, including the new complete demo, same-wallet replication, offline edit/reconnect, schema revision reads, persistent-profile restart, distinct-wallet isolation and the existing issue-tracker checks. - The separate native offline-conflict characterization passes, including its test-owned broker restart. - Full remote CI passed on final head `b8fa50d681a2ab7805e75005b8b13bd2e3c11728`, including native and offline-conflict checks: [run 63](https://git.elfaconsortium.eu/ELFA/database-apps/actions/runs/63/jobs/0). The native harness now waits for wallet import handlers to be ready before importing. User identity checks are separate from document display checks: the task grid intentionally uses its private-store graph while the expense demo selects its combined document. The older issue-tracker list-cell encoding is recorded in backlog #47 and does not gate this reference demo. Closes #41 Closes #42 Closes #43 Closes #44 Actual Atomic Server persistence, forms and later ontology/schema/webhook research remain in #45–47.
Keep Atomic schemas and RDF records in one YMap document
Some checks failed
db-app-runner tests / test (pull_request) Failing after 23m26s
e095ca4a99
michielbdejong changed title from Keep Atomic schemas and RDF records in the same YMap document to Prepare the 20 October table demo with same-document schemas and Atomic lib reuse 2026-10-15 13:46:17 +02:00
Correct native wallet readiness and separate user and document assertions
All checks were successful
db-app-runner tests / test (pull_request) Successful in 25m7s
b8fa50d681
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
ELFA/database-apps!40
No description provided.