Commit graph CultLib/packages/cultmesh-ts/README.md
Author SHA1 Message Date
Meta Vens
f2b3569822 Merge main at cultlib-unity-v2.0.0 (42dce361) into C2a: one owner per collision
Identity: C2a's StoredSchemaId/StoredVersion owns; main's PersistedSchemaId, PersistedIdentity and both MarkWritten are deleted. Stamp rule: ReadStore judges the stamp before the body. Flush over damage refuses (merge-r1-precedence). Mesh single-file writes route through SingleFileMessagePackBackingStore. TS: store-file.ts commits, C2a's header handling kept. Rust: C2a's readable_store_format in front of the grown decoder. Build not yet verified at this commit.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-22 20:35:33 +02:00
Meta Vens
4820ac74c9 cultmesh-ts/content: serve a private copy of the hashed bytes, open the store non-blocking, test the input-shaped mutants
The handler copies the store's bytes before hashing and sends that copy, so a
reused store buffer cannot change the answer. The directory store opens with
O_NONBLOCK so a FIFO named by a hash is refused by fstat instead of holding a
libuv thread. New tests: exact record-key compare and blank keys, empty-hash
prefix lookalikes, single store read, buffer reuse, FIFO (POSIX, uid-independent).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 16:09:15 +02:00
Meta Vens
f243d8b512 cultmesh-ts/content: README section and CI step naming
Builds. Docs and a workflow name/comment only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 15:28:26 +02:00
Meta Vens
3b83cb6c08 Merge origin/main into hands/variants-c2a-main (main-into-c2a)
Sixteen conflicted files resolved by the spec's rule: main owns payload
ownership, bounds and the Clock seam; C2a owns persistence semantics and exact
binding. MintStoredAt is internal static (previous, now); the cache and the
store pass their cache's Clock. Package versions are main's. The cultmesh-ts
payload-parse acceptance and its test are deleted under retire-schema-alias;
peer snapshot reads take the schema's own id, else an id the definition lists
as compatible. The held firstRecordAtKey fallback is removed: main's handles
take definitions only, so nothing could reach it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-14 04:06:41 +02:00
Meta Vens
0c5207b55f One typed owner of document-payload reads and writes: DocumentPayload is opaque, the definition is required
DocumentPayload is an opaque object type over the same runtime Uint8Array, keyed by a string
property, and types CultCacheEnvelope.payload, CultNetRawDocumentRecord.payload and
CultMeshRealtimeFrame.payload. decodeDocumentPayload(definition, payload) and
encodeDocumentPayload(definition, value) are the only reader and writer; documentPayloadFromBytes
and documentPayloadBytes are the two named escapes at the edges where bytes enter and leave.
resolveDocumentFormatter leaves the package index. The cache, cultnet replication, the mesh read
paths, the provider command (now a CultCache document), and the browser's decodeCultNetPayload
(definition required, cultcache-ts/document entry) all go through the owner.

Compile-fail fixtures per payload-carrying package pin the type with expect-error lines.
check-typescript-tests-wired.mjs fails when a test file is run by no script; cultcache-ts now
runs dist-test/test/*.test.js, and the portability workflow runs the check and the cache suite.

Builds in every package (tsc, src and tests); the suites run once, at the end of the pass.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-11 19:33:42 +02:00
Meta Vens
852ea0fe1a CultMesh TS: a node's returned documents belong to its cache
Soul F8 (M6, M7 survived): node.get, getRequired and put return the
object the cache holds, as C# and Python do (Rust copies). That is the
behaviour that ships.

- The README says the returned object belongs to the cache and must not be
  mutated, and shows the put-a-new-value pattern.
- A test pins it: two reads return the same object, put resolves to that
  object, and the caller's own value is never the one held.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 19:49:57 +02:00
Meta Vens
2c959b228f CultMesh TS: asSchemaAlias is gone; a catalog finds a typed handle by its type
F7 (operator, 2026-09-30): "Schema aliasing sounds like a really bad idea,
I support retiring it." One type owns a schema, so a handle never needs
presenting as another type for the same schema. Parity with C# 1e045502.

- Delete asSchemaAlias from the document, bound document, collection and
  bound collection handles, and cultMeshSchemasAreCompatible, which only it
  and the catalogs' alias step used.
- Document and collection catalogs answer a typed lookup from that type's
  handle or not at all. A descriptor without a type is still looked up by
  schema id, then schema name and version. The parse option on every catalog
  method existed only to convert an aliased value, and is deleted.
- CultMeshNode passes the caller's definition to its cache. The node no
  longer resolves another type's definition by schema id, and no longer
  re-parses values into the requested type, so a type the node did not
  register is refused by the cache. node.get and node.put now return the
  cache's own value, as CultCache.get and put do.
- Tests: the noteAliasDocument fixture is deleted. Tests that used it for
  publication, sync, snapshot, store and prediction paths now use
  noteDocument. otherTypeForNoteSchema stands for another type claiming the
  note schema: catalogs do not find it, and a node refuses it on every path
  and refuses to register it beside noteDocument.
- README stops documenting node aliasing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 16:59:17 +02:00
Meta Vens
425b430fe6 Make CultMesh TypeScript document writes explicit 2026-08-17 19:58:54 +02:00
Meta Vens
5c075bc212 Fence provider RUDP connection generations 2026-07-19 00:50:20 +01:00
Meta Vens
262b5cc53d Add provider session wire transport 2026-07-14 23:47:30 +01:00
Meta Vens
18cebf740f Add durable TypeScript provider sessions 2026-07-14 23:13:13 +01:00
Meta Vens
7a335b1a11 Add TS typed publication node sync 2026-06-27 23:27:01 +01:00
Meta Vens
743979eca7 Add TS typed peer snapshot node sync 2026-06-27 23:14:18 +01:00
Meta Vens
a2ec06f90e Resolve Python node document aliases transparently 2026-06-27 20:52:26 +01:00
Meta Vens
47941b5fb3 Add TS configured publication document handles 2026-06-27 17:07:04 +01:00
Meta Vens
e905aa7a0c Type TS store document handles 2026-06-27 16:49:43 +01:00
Meta Vens
a0509f223b Type TS peer snapshot document handles 2026-06-27 16:45:14 +01:00
Meta Vens
cb6301e1cf Add TS document prediction submissions 2026-06-27 16:24:08 +01:00
Meta Vens
1753dfbb92 Add CultMesh peer snapshot document handles 2026-06-27 15:56:45 +01:00
Meta Vens
6e000a71a9 Mirror CultMesh primitives in TypeScript 2026-06-27 14:35:08 +01:00
Meta Vens
cc0d52bfc5 Add TypeScript CultMesh RUDP peer helpers 2026-06-17 03:58:12 +01:00
Meta Vens
50ac886fd7 Document TypeScript authorized RUDP peer flow 2026-06-16 17:03:55 +01:00
Meta Vens
3deabd706d Add TS CultMesh RUDP factories 2026-06-16 16:37:16 +01:00
Meta Vens
da48d58df7 Add TS CultMesh catalog factories 2026-06-16 16:18:08 +01:00
Meta Vens
4c80cafe5d Add TS catalog watch ergonomics 2026-06-16 10:11:37 +01:00
Meta Vens
8c91a5d687 Add TypeScript CultMesh catalog ergonomics 2026-06-16 00:27:16 +01:00
Meta Vens
f7182159b4 Add C# CultMesh streaming surface 2026-06-02 01:13:08 +01:00
Meta Vens
67d3bf3dcf Add CultMesh streaming mode surface 2026-06-02 00:57:07 +01:00