A store on SQLite MUST have the capability merge and pass every case of the merge suite of AnyFS (a union in any order, grouping and repetition, a vector that never goes back, refusal of what is not trusted, tampered or from the future).
Enforced (check): .github: cd commons/anyfs-sql && bun run verify — suite/merge.test.ts
A database MUST hold an identity (a replica and the fingerprint of its file); where it is opened and the fingerprint is not the stored one it MUST take a new identity, keep the old one as trusted and report where it was forked from, and where it is the same it MUST keep its own.
Enforced (check): .github: cd commons/anyfs-sql && bun run verify — suite/merge.test.ts
A database MUST take rows only from replicas it trusts (itself alone where not told otherwise, an allowlist, or any), MUST refuse a delta from another with a sentence, and MUST take nothing of it.
Enforced (check): .github: cd commons/anyfs-sql && bun run verify — suite/merge.test.ts
Writes to one path on two replicas MUST leave one winner, the same on both once they have exchanged what they hold (the greatest id), and every other head MUST be kept and be given as a sibling.
Enforced (check): .github: cd commons/anyfs-sql && bun run verify — suite/merge.test.ts
Every behaviour is tested on the real engine and, where a program of the system is used (sqlite3, git), on the real program, in temporary folders, with no network.