50 most recent check-ins that include changes to files matching 'src/sim/*'
|
2026-11-22
| ||
| 17:34 | Receive keeps every delta as sent at any depth, as Fossil does, and pack and writes base an artifact on its parent, storing it whole only when its chain's delta bytes would exceed its own size: a clone of fossil.fossil stores 42 MB instead of 226 check-in: 1ff436a23c user: dmestas tags: trunk | |
|
2026-11-21
| ||
| 04:52 | The checkpoint claims a prefix of the repo cache instead of copying it: pkgsrc's cache is 288 MB instead of 427 check-in: ab016fbfed user: dmestas tags: trunk | |
| 04:10 | Delta chains have no depth cap: writes and pack use skip-deltas keyed on the artifact, receive keeps deltas as sent up to depth 64, and reads walk chains in a bounded, cycle-safe loop; a packed quarry store is 24.8 MB instead of 46.2 check-in: b9e1b63b4c user: dmestas tags: trunk | |
|
2026-11-18
| ||
| 12:30 | New repositories get a random project code, as in Fossil; a clone takes its origin's check-in: 0e9ddab4ff user: dmestas tags: trunk | |
|
2026-11-15
| ||
| 22:21 | dst splits its default sweep across four child processes; a seed or seed range still runs in one check-in: 57f7c47ae2 user: dmestas tags: trunk | |
| 16:51 | Group the library by subsystem under src/store, artifact, repo, diff, worktree and sync, with the verb layer in cli and net; the no-CLI guard covers every library directory check-in: 0ed57b625c user: dmestas tags: trunk | |
| 13:16 | Split cmd/sync.zig into one file per verb; sync.zig keeps the sync verb and autosync check-in: f879a6159b user: dmestas tags: trunk | |
|
2026-11-13
| ||
| 17:25 | Nothing below main.zig imports it: help text, shared failure wording, init and digest names move to their own modules check-in: 45dd12c6d9 user: dmestas tags: trunk | |
| 15:15 | The fault simulation asks zit whether a cut clone can pull, instead of reading a store whose tail the crash tore check-in: 7f383e5bd4 user: dmestas tags: trunk | |
| 00:30 | A clone saves the origin's project code before its first artifact, so one cut short still pulls from its origin check-in: 4441f6ec99 user: dmestas tags: trunk | |
|
2026-11-11
| ||
| 23:13 | Allocation-failure walks refuse in-place resizes, so their counts do not depend on the heap check-in: e225204f4b user: dmestas tags: trunk | |
|
2026-11-07
| ||
| 02:39 | Sync and pull open the store before reading leaves for the fork report, so a torn last frame left by a crash is repaired first; the simulator counts a forked sync or pull as success check-in: 5da8555024 user: dmestas tags: trunk | |
|
2026-11-06
| ||
| 18:54 | A sub-manifest received as a delta before its basis closes its tree's gap when the basis arrives, so a deepen from a zit server completes; a store header torn while its version is restamped reads as the stamp it was leaving instead of corrupt, and a new horizon clone writes its version when the store is created check-in: 8a547a40f9 user: dmestas tags: trunk | |
|
2026-10-28
| ||
| 21:52 | Horizon sweep: a generated merge that conflicts after criss-cross merges keeps the owner's later version check-in: 3d46cafc30 user: dmestas tags: trunk | |
| 15:17 | Horizon clones state a held root as a held entry; dst names each seed before running it and the soak keeps a failed run's stderr check-in: bc6778450a user: dmestas tags: trunk | |
|
2026-10-26
| ||
| 16:10 | Structural horizon clones state their held entries so a shrinking leaves-rule K keeps what was served check-in: 1b26775768 user: dmestas tags: trunk | |
|
2026-10-25
| ||
| 20:34 | Horizon sweep: the commit after a cut pull picks its file from the clone's cone, so a whole-tree listing no longer fetches withheld nodes on the twin alone check-in: 7bc0c50b0a user: dmestas tags: trunk | |
| 17:29 | A push-only client asks for no content, as Fossil's does; the sync sweep expects a push to leave the client the phantoms it began with check-in: 81ccbcdc30 user: dmestas tags: trunk | |
|
2026-10-23
| ||
| 19:01 | Merge horizon-rfc: horizon clones, the Fossil horizon draft, streaming cone persist check-in: d00faba684 user: dmestas tags: trunk | |
| 02:15 | Horizon clones from a filtering origin persist round by round, then classify over the log; the batched local filter stays for an origin that did not filter check-in: db1ffa3ce2 user: dmestas tags: horizon-rfc | |
|
2026-10-22
| ||
| 22:59 | Content horizon cones: the origin withholds the tree nodes no slot reaches, walking only new trees; a cone clone classifies and persists through a bounded window; verify skips the path tracker under a horizon check-in: 3a2df62515 user: dmestas tags: horizon-rfc | |
|
2026-10-21
| ||
| 22:41 | Horizon clones: older releases refuse them, interop with stock Fossil, oracle-checked pull, deepen, seed and leaves rule, and fail-closed crossing operations check-in: 5be6fcc866 user: dmestas tags: horizon-rfc | |
|
2026-10-16
| ||
| 12:28 | sync-protocol §6.6: a server may append to a refusal's text; clients match its leading text check-in: 0a804be143 user: dmestas tags: trunk | |
|
2026-10-14
| ||
| 11:54 | dst oracle: keep the leaf table by recheck events, as the implementation does check-in: 4af011b305 user: dmestas tags: trunk | |
|
2026-10-13
| ||
| 16:05 | Re-key the draft citations to the revised -00 texts; rekey-citations.py moves them across a render check-in: c8e4f73193 user: dmestas tags: trunk | |
| 16:00 | Leaf table: recheck only on branch-tag events, as Fossil does; ckout is an ordinary name check-in: ae8e6d6e3c user: dmestas tags: trunk | |
|
2026-10-12
| ||
| 23:50 | Build with Zig 0.17.0; version 0.4.0 and its release notes check-in: 7ad0e1704f user: dmestas tags: trunk | |
|
2026-09-28
| ||
| 12:53 |
pack, shun --force: fsync the directory after the rename; model it in DST
The rename that installs a new generation was never made durable, so a power loss after a reported success could bring the old store back, and with it content a shun had removed. The fault layer now reverts creates, renames and deletes no directory fsync made durable, and the shun sweep requires a rewrite that succeeded to survive a power cut. check-in: 3873759cfa user: dmestas tags: trunk | |
| 11:59 |
Lock the store with exclusive-create lock files instead of flock
Writers create .zit.lock with O_CREAT|O_EXCL before opening the store. A waiter names the holder and gives up after a minute; a dead holder's lock is broken; pack and shun --force hold the writer lock across their final check and rename. Release 0.3.33. check-in: d6cf7bf59c user: dmestas tags: trunk, version-0.3.33 | |
| 02:39 |
Take the writer lock inside LogStore.open and test the lock class
LogStore.open now takes the exclusive lock before it reads the file's length and scans for the end, and a read-only handle refuses to append. purge undo opens the store through the shared writer path. A new DST sweep runs two to four writers interleaved against one log through a file that models the lock. It flags unlocked or misplaced appends as they happen, checks each writer sees everything committed before it locked and reads back its own writes, including deltas. A source check fails on any write-mode open of the store outside openStoreAppend. An e2e test races commits, tags and user-table writes on one store and counts what landed. check-in: 5c445bb3f3 user: dmestas tags: trunk, version-0.3.32 | |
|
2026-09-18
| ||
| 16:31 |
dst: a bitflip inside a config frame owes a repair, as one in a content frame does
The first full nightly soak found seed 22 at 10000 steps: the crash sweep flipped a bit inside a committed config frame, the store's checksum refused to serve it, and the harness reported a config mismatch because only its content-frame path knew that refusal as detection. The config check now routes rot inside the surviving config frame to the repair, and the repair's cut keeps every frame of either kind that ended before the rot, since config frames interleave with content. check-in: 79059346bc user: dmestas tags: trunk | |
|
2026-09-17
| ||
| 17:04 |
Remove issue-tracker numbers from source and documents
The tracker is disposable and does not live with the source, so a number is a dangling pointer. Every zit#NN and #NN reference in code comments, test names, help text, smoke labels, identifiers, release notes and errata is replaced by enough context to stand alone, or by a short plain statement of the problem. No behaviour changed. check-in: 9033c13f21 user: dmestas tags: trunk | |
| 13:39 |
log: open once, on the zero-parse image
log reached past the open funnel and called Repository.open with the default options, which is the full record replay meant for write verbs, and did so twice for a symbolic name. On pkgsrc that was 0.94s before the first row; on the image path it is 0.05-0.10s, output byte-identical on every route. The open mode has no default any more: every direct caller declares it, so the next verb written past the funnel cannot inherit the expensive one silently. An e2e runs every log route under the derive-footprint seam and fails if any of them replays a record. check-in: 0910bc00f5 user: dmestas tags: trunk | |
|
2026-08-21
| ||
| 21:08 |
merge materialize-perf into trunk (#114)
Both sides had made the repository-tier setting read adopt the scan index (#112); trunk's write-on-miss refresh is kept inside the shared helper the autosync read now also uses. check-in: 6f540c5d77 user: dmestas tags: trunk | |
| 20:50 |
update/open: materialize 2x faster on large trees (#114)
Stage payloads once and rename them into place instead of writing them twice with an fsync each; keep the parent directory open across a path-sorted plan instead of re-walking it per file; read the repository setting through the persisted log index instead of a full frame scan; reuse the verb's open repository for the target's branch facts rather than deriving repo state a second (update: third) time. tk (146k artifacts, 1,079 files): open 1.1s -> 0.48s; fossil is 0.34s. Rename-into-place also closes the checkout_sweep H2 finding: no crash cut can leave a hybrid file, so the pinned test now asserts that. closed check-in: 244523acfa user: dmestas tags: materialize-perf | |
|
2026-08-15
| ||
| 01:03 | merge sparse-cone: sparse checkouts and sparse stores per draft-fossil-sparse-cone-00 — worktree cones with exclusions, cone-scoped clone/open/update, cone/cone-not wire pragmas with graceful degradation, demand fetch, pack --drop-elided, cross-cone record merges, and the sparse-origin clone refusal check-in: 2ad75a9bea user: dmestas tags: trunk | |
|
2026-08-14
| ||
| 20:17 | merge trunk check-in: 8b3d577ec1 user: dmestas tags: sparse-cone | |
| 19:39 | sync: unversioned cards tolerate-and-report (#58) — validated, counted, never an abort; sessions report N not transferred; NotImplemented retired; uv-only replies are the clean §3.7 terminal check-in: 3cf76b982e user: dmestas tags: trunk | |
| 14:12 | sparse cone at the seam: MergeWalk filter, cone-aware requireClean, SparseOpt on applyCheckin (record+cone one splice), cross-cone merge refuses fail-closed check-in: 259219f90e user: dmestas tags: sparse-cone | |
| 12:21 | merge sub-manifest: delta-manifest dialect, R cards, diff hunks, server identity, stash, open/log resolution, clone remote+progress, timestamp names; e2e expectations updated check-in: 8a45a021f9 user: dmestas tags: trunk | |
|
2026-08-12
| ||
| 09:04 |
checkpoint: retire the tree shape — sidecar only, structurally
The tree shape minted permanent SUBMANIFEST artifacts for benefits already had elsewhere: the rebuild win lives in the prefix record, verify's §6.2 oracle runs buildTree in memory, and the subtree-sharing bytes re-materialize at the first real S-emitting commit at identical cost. Minting early only created unreferenced permanent artifacts and the allow-tree/demotion/gate apparatus needed to keep automation from doing it by accident — all deleted with it. build no longer opens the log for writing or reads the emission settings at all; sidecar layout v3 (old sidecars miss and rebuild in seconds). Proven at scale: SHA-256 of pkgsrc's 593MB store is byte-identical across a full build; cold 4:12, rebuild 3.4s. check-in: 2a8fdcff60 user: dmestas tags: sub-manifest | |
|
2026-08-10
| ||
| 23:12 |
Add zit checkpoint: durable prefix resume for hybrid history
.zit-cache/checkpoint pairs a validated log-prefix key with the prefix's crosslink record body; Repository.open resumes past the flat segment on a cache miss instead of re-parsing it. Witness shape under a closed emission gate creates zero artifacts; tree shape pins the anchor's file set as the canonical S-tree (batch-oracle byte-identical, one interior root node). verify re-derives every claim from real history; --no-cache bypasses both sidecars. New verb: zit checkpoint [show|build|verify|drop]. pkgsrc (163k commits, 60k files): cold open 8.4s vs 352s full derive; verify passes; 366/367 tree nodes deduplicated against the imported tree. check-in: e4026acd7b user: dmestas tags: sub-manifest | |
| 19:31 |
Fold managed/undo/bisect into the .zit-checkout container v2 (consolidation Task 6)
Sectioned container (ZITCKOT, tagged table, whole-file CRC); payloads are the existing formats unchanged. Byte-1 dispatch migrates legacy checkouts on first write; siblings dead once a container exists. Undo/redo restore and the commit/merge record+membership writes each collapse to one atomic splice. DST gains a legacy-seeded migration sweep (full-legacy or full-container at every crash cut). Registry: the three names move to the legacy tier. Perf on pkgsrc: adjacent update 6.50s (was 6.8), no-op 5.14s (was 7.69); migration of a 66k-file checkout invisible inside one update. check-in: efa29d234f user: dmestas tags: sub-manifest | |
|
2026-08-05
| ||
| 21:16 |
citations: re-key 31 verified line ranges, baseline 512 to 481
Each was located by reading the draft text that supports what the code comment actually claims, then adversarially re-checked against a verbatim quote of those lines. Clamping a range into its section would satisfy the checker while pointing at the wrong paragraph, so the checker alone was never the gate. Of 33 proposals, 2 were refuted on exactly that ground -- the quote verified byte-for-byte and still did not state the claim -- and 4 came back unresolved because no draft's §4.1 states what those comments assert at all. Those are mis-sectioned, not line-rotted, and need a section decision rather than a re-key. Also restores container.zig's `decode` doc block, which 7d26a31305 left stranded above `decodePrefix` when that function was inserted between the comment and the function it describes. test 3495/3495, fmt. Issue #18. check-in: e5db38a6df user: dmestas tags: sub-manifest | |
|
2026-08-01
| ||
| 08:31 |
dst storage sweep: the repair's own reopen is not workload under test
crashCheckOnce repairs by truncating below the earliest injected bitflip and reopening. When the truncation empties the log, that reopen writes a fresh header - and the injected short-write fault could land on it, so open returned Storage, the sweep mapped it to Io, and the run failed. Nothing there was a statement about the store: the simulator faulted its own recovery. The repair and its reopen now run against the healthy disk phase 2 heals to, the all-zero FaultCfg. Faults come back before the invariant check, which is workload again. Pre-existing: trunk fails seed 201 with the same Io. check-in: 9e3107e570 user: dmestas tags: sub-manifest | |
| 08:31 |
dst gen: check merge parents for cycles, not just the primary chain
The generator's own note says a real check-in DAG is acyclic by construction - a manifest's hash covers its P-card - while the phantom-parent flavor lets a hash be named before its record exists, so a later pick can close a loop and must be checked. The check only ever walked primary_parent_of, and the merge parent was drawn by pickInsertedIndex with the comment "no cycle risk". That holds for the primary chain alone. Section 3.3 ancestry, which the B1 tie-break walks, follows merge parents too: a merge edge into an already inserted check-in, paired with a phantom primary edge out of it, closes a loop the guard never looked at. ancestryMaximal then finds every candidate dominated and no maximal element, and panics - seed 192 built exactly that, 9 to 14 to 13 and back. parent_indices records every parent index a record names, wouldCloseCycle walks that graph visited-once, and the merge draw is checked like the primary one. A losing draw degrades to the single-parent record rather than drawing again, so the seeded stream shifts as little as it can. Pre-existing: trunk fails seed 192 identically, and gen.zig is byte-identical there. Only the default six seeds hid it. check-in: 992ff19a23 user: dmestas tags: sub-manifest | |
| 07:22 |
merge trunk: land the logstore slices, repair the sweep's rot oracle
Trunk's Slice 1/2 made both open paths header-only, so a rotted payload now opens clean and surfaces at content() instead of at open. The storage sweep still assumed open was the tripwire, so two of its own claims were wrong once the merge combined them with this branch's store: - crashCheckOnce repaired only "if the open itself reports corruption", a precondition Slice 2 removed. Injected rot reached the invariant check and read as data loss. NeedsRepair, private to the harness, now carries "refused AND genuinely damaged" to the repair that already existed. - rotWithinFrame spelled the per-frame overhead as 22, the header alone, so a frame's own trailing frame_crc32 counted as inert pad. A bitflip in those four bytes makes a reader recompute a correct checksum, compare it to a corrupted stored one, and refuse the frame; the sweep called that data loss. logstore now exports frame_fixed_overhead and the sweep derives it instead of respelling it. Both are trunk defects, not merge damage: trunk alone fails dst at seed 8. The merge only shifted the draws far enough to reach the first one at seed 3, inside the default gate's range. cli.zig's verb enum was the single textual conflict: a pure union of trunk's verify and this branch's submanifest and import-git. fmt, test, gate, dst green. check-in: 584314dcb7 user: dmestas tags: sub-manifest | |
|
2026-07-31
| ||
| 21:15 |
merge logstore-slice2: the open-cost work reaches production
openReadOnly is what every CLI verb opens through, and until now it still checksummed every payload byte on every invocation -- so nothing users ran had gotten faster. It scans header-only now: 10k frames 42 MB 42.2ms -> 10.3ms 10k frames 410 MB 298.0ms -> 12.3ms 100k frames 416 MB 511.9ms -> 115.4ms 100 frames 419 MB 321.4ms -> 0.10ms Open cost is a function of frame count rather than repository size. On a store of a few large artifacts it is effectively free. This completes the sequence: vendor a faster crc, measure the path production actually takes, scan header-only on the append path, ship the fsck verb, then delete the eager check. Each step was gated on the one before it, and the deletion was deliberately last because it is the only one that gives something up. What is given up: opening a repository no longer detects payload corruption. It surfaces on the read instead -- readFrameAt crc-checks every frame unconditionally now -- or on demand through "zit verify". That is the split git draws between ordinary operation and fsck, and it was signed off knowing the tradeoff. A damaged store also stays usable for everything that does not touch the damaged bytes, which the old eager check made impossible. Slices 0 and 4 are closed too: the 4 KiB chunk widening landed inside verify, the only place that loop still runs, and the sidecar index is dead on its own gate -- the 100k-frame shape was to justify it by exceeding 150ms and came in at 119ms. mmap is dead alongside it, separately, because a mapping would keep shunned bytes resident and readable until every mapping dropped, which defeats reclamation rather than merely slowing it. Neither rejection is recorded at the logstore extension comment yet; that is the one piece of follow-up this leaves behind. Verified on the merged tree: fmt clean, test 2327/2327, gate 19/19. On the branch tip, additionally e2e 671/671 and dst 6 seeds x 1000 steps. check-in: 6d9172d488 user: dmestas tags: trunk | |
| 21:12 |
logstore: openReadOnly scans header-only; verified_on_open is gone
The speedup reaches production. openReadOnly is the path every CLI verb takes -- Repository.open falls back to it, and Repository.logStore, the content channel behind cat, artifact, checkout and sync, calls it with no cache in front. It scanned every payload byte on every invocation: 10k frames 42 MB 42.2ms -> 10.3ms 10k frames 410 MB 298.0ms -> 12.3ms 100k frames 416 MB 511.9ms -> 115.4ms 100 frames 419 MB 321.4ms -> 0.10ms Open cost is now a function of frame count, not repository size. verified_on_open was the flag openReadOnly set to tell readFrameAt that the scan had already checked every frame, so reads could skip their own crc. With no scan doing that, the exemption had nothing left to rest on and the flag is deleted. readFrameAt now crc-checks unconditionally: it is the only thing standing between a rotted payload and a caller that believes it, and restoring any skip there means restoring the scan. Detection is relocated, not removed. A payload bitflip no longer voids the open -- the rest of the repository stays usable -- and surfaces the first time anyone reads those bytes: "zit cat" and "zit artifact" both refuse with 'repository is corrupt', and "zit verify" names the artifact and the offset. That verb shipped first for exactly this reason. openForVerify is deleted. It existed because openReadOnly both aborted on a damaged store and granted read-time trust, neither of which verify could accept; both properties are gone, it became byte-identical to openReadOnly, and its own doc comment said to remove it in this commit. The DST prove-it-can-fail arm is inverted rather than deleted. It asserted that openReadOnly WOULD serve latent rot silently, across a seed range where at least one corpus lands a payload rot on a raw frame whose header survived. That hazard is gone, so the same range now asserts the opposite: the read path never serves rot as success. trust_on_read goes with it -- there are no longer two paths to select between. Losing the eager whole-log scan cost nothing here, because per-read verification is what was catching this all along. Net -40 lines. Verified: fmt clean, test 2327/2327, gate, e2e 671/671, dst 6 seeds x 1000 steps. The Slice 1 tripwire -- the assertion that openReadOnly still rejected eagerly, written to fail if the flag was deleted without an fsck verb -- fired on this commit, which is the one it was aimed at. closed check-in: b224ffeb40 user: dmestas tags: logstore-slice2 | |
| 04:56 |
merge trunk: shun, the release-assert guard, and the split test lanes
Trunk since d186a44e brought the repository shun table and its whole- branch verification fixes, the release-assert guard, the `test`/`gate` lane split, the structurally bounded logstore priority window, and the vendored crc32. Eight files conflicted. The decisions worth naming: Lanes. `git-import-e2e` was a compile-only proof hanging off `test`; that is exactly the cost trunk moved to `gate`, so it moves with `e2e` and `smoke`. `import-git-bench` stays on `test` because it registers a real unit-test run rather than a compile proof. `declared_steps` is the union plus `gate`. Sync ingest. Both sides rewrote it: trunk added the §7.7 receive-side shun admission, this branch added §7.1 phantom minting for a pushed tree's missing sub-manifests. They compose in one direction — admission is asked first, so a card §7.7 refuses is never stored and mints no phantoms either. The S references of an artifact this repository declines to hold are not names it should then go begging for. Client construction. Trunk factored the three verbs' `Client` literal into `syncClient` and threaded `RepoAdmission`; this branch had widened `project_code` into `RepoSyncIdentity`. The helper now carries both, which is what trunk's own comment asked for: three copies of that literal is how a repository filter comes to be wired into two verbs and not the third. Per-round server refresh. Trunk made the snapshot mandatory — `error.ServerStorage` rather than serving with no shun table — where this branch read its four sub-manifest fields through fail-open defaults. Trunk's reading wins for all six fields: serving a stale default is the failure, not the fallback. Two guards trunk owns caught real defects in this branch's code, which is the whole point of them: The total switch in `shunConsequence` refused to compile against the `submanifest` artifact type, exactly as its comment promised. It has an arm now. The release-assert guard found nine asserts on untrusted input across six functions. Two were reachable faults, not style: `lookupTree` asserted §4.4 on a sub-manifest a peer supplies, so a malformed node panicked a ReleaseSafe reader and was walked anyway under `--release=fast`. It returns `SubUnresolvable` now, which §5.2 already defines as "absent, or is not a SUBMANIFEST". The empty-S-run assert became an early `null`. The two sub-manifest writers refuse an empty group through a new `SubmanifestWriteError` rather than asserting; the builder's internal path keeps its allocation-only surface through `serializeLeafCore`, since the partitioner is what establishes non- emptiness there. The rest were tautologies or restatements of invariants the card parser already enforces, and now say so in a comment instead of carrying a panic. Verified on the merged tree: `gate`, `e2e`, `dst` (6 seeds x 1000 steps), `smoke` (S1-S10, including trunk's new shun interop), and `git- import-e2e` all green, `zig fmt --check` clean. Beyond the suite, the importer was run for real: the empty-email repro imports and its check- in carries `U mohye77`, and marktext imports end to end with the analyzed pin at k=5. check-in: 562cf5be74 user: dmestas tags: sub-manifest | |