@bastani/atomic 0.10.10 → 0.10.11-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +139 -0
- package/README.md +1 -1
- package/dist/_shared/dist-KOELCESV.js +2 -2
- package/dist/_shared/fork-row-index-UAUAQRD5.js +2 -2
- package/dist/_shared/lib-4PES5P4V.js +2 -2
- package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js +11 -13
- package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js.map +1 -1
- package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js +9 -9
- package/dist/_shared/mode-shared-2QJSCUM6.js +55 -18
- package/dist/_shared/mode-shared-2QJSCUM6.js.map +1 -1
- package/dist/_shared/p1a-prewarm-XIU57JHF.js +3 -3
- package/dist/_shared/runtime-O4KCSG4C.js +5 -5
- package/dist/_shared/{sdk-RRLVN7ER.js → sdk-IQMULKFU.js} +2962 -470
- package/dist/_shared/sdk-IQMULKFU.js.map +1 -0
- package/dist/_shared/session-data-AHTU7IS6.js +4 -4
- package/dist/_shared/session-manager-list-2BLEEZVG.js +1 -1
- package/dist/_shared/settings-startup-8-DNZ2RIHM.js +1 -1
- package/dist/_shared/{settings-startup-4QCVCI53.js → settings-startup-HXQLSUWM.js} +8 -2
- package/dist/_shared/settings-startup-HXQLSUWM.js.map +1 -0
- package/dist/_shared/{startup-0-0-4VG2G44V.js → startup-0-0-3IXNMFM2.js} +482 -53
- package/dist/_shared/startup-0-0-3IXNMFM2.js.map +1 -0
- package/dist/_shared/{startup-0-1-XTIL65D4.js → startup-0-1-7T2IAE7J.js} +121 -251
- package/dist/_shared/startup-0-1-7T2IAE7J.js.map +1 -0
- package/dist/_shared/{startup-0-2-27OWFHV6.js → startup-0-2-5QHPCEON.js} +293 -10
- package/dist/_shared/startup-0-2-5QHPCEON.js.map +1 -0
- package/dist/_shared/{startup-0-3-T4DVFYWX.js → startup-0-3-4ZYBYQNM.js} +273 -14
- package/dist/_shared/startup-0-3-4ZYBYQNM.js.map +1 -0
- package/dist/_shared/startup-0-4-ZMJV547D.js +6 -6
- package/dist/_shared/{startup-0-5-FD2P735I.js → startup-0-5-YDW47QX6.js} +29 -71
- package/dist/_shared/startup-0-5-YDW47QX6.js.map +1 -0
- package/dist/_shared/startup-10-0-TDQNBDDL.js +9 -9
- package/dist/_shared/startup-12-0-55AAXBJZ.js +4 -4
- package/dist/_shared/startup-14-0-MLX36RBG.js +6 -6
- package/dist/_shared/startup-15-0-YUKGAC63.js +34 -10
- package/dist/_shared/startup-15-0-YUKGAC63.js.map +1 -1
- package/dist/_shared/startup-15-1-4S7FLMNG.js +10 -9
- package/dist/_shared/startup-15-1-4S7FLMNG.js.map +1 -1
- package/dist/_shared/startup-8-0-34CBHPZH.js +421 -84
- package/dist/_shared/startup-8-0-34CBHPZH.js.map +1 -1
- package/dist/_shared/{startup-8-1-4KANEHRA.js → startup-8-1-X32CYSXB.js} +1291 -722
- package/dist/_shared/startup-8-1-X32CYSXB.js.map +1 -0
- package/dist/_shared/storage-command-7MGXLJGZ.js +17 -9
- package/dist/_shared/storage-command-7MGXLJGZ.js.map +1 -1
- package/dist/_shared/task-reference-stream-JWMUZSJX.js +1 -1
- package/dist/_shared/task-unsaved-answer-VJ2KTB4V.js +2 -2
- package/dist/_shared/tree-outline-MUEPK5B7.js +3 -3
- package/dist/builtin/intercom/CHANGELOG.md +29 -0
- package/dist/builtin/intercom/broker/broker.bundle.mjs +1138 -384
- package/dist/builtin/intercom/broker/database-wake-up-bus.ts +103 -24
- package/dist/builtin/intercom/broker/multinode-router.ts +42 -21
- package/dist/builtin/intercom/broker/multinode-state-store.ts +22 -1
- package/dist/builtin/intercom/broker/open-broker-state.ts +82 -31
- package/dist/builtin/intercom/broker/paths.ts +8 -4
- package/dist/builtin/intercom/broker/released-asker-remote-replies.ts +18 -6
- package/dist/builtin/intercom/broker/sql-add-column.ts +4 -1
- package/dist/builtin/intercom/broker/sql-ended-child-queue-store.ts +65 -44
- package/dist/builtin/intercom/broker/sql-held-send-store.ts +11 -3
- package/dist/builtin/intercom/broker/sql-known-session-store.ts +24 -12
- package/dist/builtin/intercom/broker/sql-lease-store.ts +386 -65
- package/dist/builtin/intercom/broker/sql-outbox-store.ts +462 -130
- package/dist/builtin/intercom/broker/sql-pending-ask-store.ts +20 -9
- package/dist/builtin/intercom/broker/sql-released-ask-store.ts +14 -6
- package/dist/builtin/intercom/broker/sql-restoring-reservation-store.ts +27 -11
- package/dist/builtin/intercom/broker/sql-schema.ts +198 -5
- package/dist/builtin/intercom/broker/sql-sent-message-authority.ts +97 -34
- package/dist/builtin/intercom/index.bundle.mjs +11 -8
- package/dist/builtin/intercom/package.json +1 -1
- package/dist/builtin/mcp/index.bundle.mjs +1 -1
- package/dist/builtin/mcp/package.json +1 -1
- package/dist/builtin/subagents/CHANGELOG.md +18 -0
- package/dist/builtin/subagents/package.json +1 -1
- package/dist/builtin/subagents/skills/skill-creator/SKILL.md +1 -1
- package/dist/builtin/subagents/src/extension/index.bundle.mjs +62 -23
- package/dist/builtin/web-access/index.bundle.mjs +1 -1
- package/dist/builtin/web-access/package.json +1 -1
- package/dist/cli/args.js +2 -2
- package/dist/cli/auth-cli.code.js +6 -6
- package/dist/cli/auth-cli.impl.js +3 -3
- package/dist/cli/auth-cli.js +3 -3
- package/dist/cli/blueprint-command.code.js +4 -4
- package/dist/cli/blueprint-command.impl.js +3 -3
- package/dist/cli/blueprint-command.js +3 -3
- package/dist/cli/intercom-command.code.js +3 -3
- package/dist/cli/intercom-command.impl.js +3 -3
- package/dist/cli/intercom-command.js +3 -3
- package/dist/cli/list-models.code.js +2 -2
- package/dist/cli/list-models.impl.js +3 -3
- package/dist/cli/list-models.js +3 -3
- package/dist/cli/session-picker.code.js +2 -2
- package/dist/cli/session-picker.impl.js +3 -3
- package/dist/cli/session-picker.js +3 -3
- package/dist/cli/startup-ui.code.js +2 -2
- package/dist/cli/startup-ui.impl.js +3 -3
- package/dist/cli/startup-ui.js +3 -3
- package/dist/cli/storage-command.impl.js +3 -3
- package/dist/cli/storage-command.js +3 -3
- package/dist/cli/storage-search-session.code.js +3 -3
- package/dist/cli/storage-search-session.impl.js +3 -3
- package/dist/cli/storage-search-session.js +3 -3
- package/dist/cli/team-command.code.js +3 -3
- package/dist/cli/team-command.impl.js +3 -3
- package/dist/cli/team-command.js +3 -3
- package/dist/cli.js +2 -2
- package/dist/core/agent-session-methods.d.ts +3 -0
- package/dist/core/agent-session-methods.js.map +1 -1
- package/dist/core/agent-session.d.ts +1 -0
- package/dist/core/compaction/compactor.d.ts +2 -0
- package/dist/core/debug.impl.js +3 -3
- package/dist/core/debug.js +3 -3
- package/dist/core/export-html/card-projection.code.js +1 -1
- package/dist/core/export-html/card-projection.impl.js +3 -3
- package/dist/core/export-html/card-projection.js +3 -3
- package/dist/core/export-html/index.code.js +2 -2
- package/dist/core/export-html/index.impl.js +3 -3
- package/dist/core/export-html/index.js +3 -3
- package/dist/core/export-html/json-spans.impl.js +3 -3
- package/dist/core/export-html/json-spans.js +3 -3
- package/dist/core/export-html/oversized-render-inputs.code.js +2 -2
- package/dist/core/export-html/oversized-render-inputs.impl.js +3 -3
- package/dist/core/export-html/oversized-render-inputs.js +3 -3
- package/dist/core/export-html/tool-renderer.impl.js +3 -3
- package/dist/core/export-html/tool-renderer.js +3 -3
- package/dist/core/extensions/jiti-loader.impl.js +3 -3
- package/dist/core/extensions/jiti-loader.js +3 -3
- package/dist/core/extensions/jiti-static-loader.impl.js +3 -3
- package/dist/core/extensions/jiti-static-loader.js +3 -3
- package/dist/core/extensions/loader-host-modules.code.js +1 -1
- package/dist/core/extensions/loader-host-modules.impl.js +3 -3
- package/dist/core/extensions/loader-host-modules.js +3 -3
- package/dist/core/extensions/loader-virtual-modules.js +2 -2
- package/dist/core/extensions/runner-context.js +4 -4
- package/dist/core/extensions/runner-context.js.map +1 -1
- package/dist/core/intercom-broker-control-host.code.js +1 -1
- package/dist/core/intercom-broker-control-host.impl.js +3 -3
- package/dist/core/intercom-broker-control-host.js +3 -3
- package/dist/core/intercom-broker-control.code.js +3 -3
- package/dist/core/intercom-broker-control.impl.js +3 -3
- package/dist/core/intercom-broker-control.js +3 -3
- package/dist/core/model-registry.js +1 -1
- package/dist/core/model-resolver-defaults.d.ts +3 -2
- package/dist/core/package-manager-storage-adapters.code.js +1 -1
- package/dist/core/package-manager-storage-adapters.impl.js +3 -3
- package/dist/core/package-manager-storage-adapters.js +3 -3
- package/dist/core/sdk.code.js +4 -5
- package/dist/core/sdk.impl.js +3 -3
- package/dist/core/sdk.js +3 -3
- package/dist/core/session-manager-core.d.ts +5 -2
- package/dist/core/session-manager-core.js +39 -23
- package/dist/core/session-manager-core.js.map +1 -1
- package/dist/core/session-manager-list.impl.js +3 -3
- package/dist/core/session-manager-list.js +3 -3
- package/dist/core/session-manager.code.js +3 -3
- package/dist/core/session-manager.impl.js +3 -3
- package/dist/core/session-manager.js +3 -3
- package/dist/core/session-open-markers.js +3 -0
- package/dist/core/session-open-markers.js.map +1 -0
- package/dist/core/session-storage.code.js +1 -1
- package/dist/core/session-storage.impl.js +3 -3
- package/dist/core/session-storage.js +3 -3
- package/dist/core/storage/added-exports.d.ts +6 -0
- package/dist/core/storage/added-exports.js +19 -0
- package/dist/core/storage/added-exports.js.map +1 -0
- package/dist/core/storage/database.d.ts +53 -0
- package/dist/core/storage/database.js.map +1 -1
- package/dist/core/storage/fenced-paths.d.ts +47 -0
- package/dist/core/storage/fenced-paths.js +53 -0
- package/dist/core/storage/fenced-paths.js.map +1 -1
- package/dist/core/storage/file-identity.js +31 -2
- package/dist/core/storage/file-identity.js.map +1 -1
- package/dist/core/storage/index.d.ts +4 -1
- package/dist/core/storage/index.js +5 -2
- package/dist/core/storage/index.js.map +1 -1
- package/dist/core/storage/migrations.d.ts +33 -2
- package/dist/core/storage/migrations.js +73 -5
- package/dist/core/storage/migrations.js.map +1 -1
- package/dist/core/storage/node-sqlite-thread.js +48 -6
- package/dist/core/storage/node-sqlite-thread.js.map +1 -1
- package/dist/core/storage/node-sqlite.js +137 -4
- package/dist/core/storage/node-sqlite.js.map +1 -1
- package/dist/core/storage/offline-snapshot-file.impl.js +3 -3
- package/dist/core/storage/offline-snapshot-file.js +3 -3
- package/dist/core/storage/prefix.d.ts +3 -2
- package/dist/core/storage/prefix.js +23 -2
- package/dist/core/storage/prefix.js.map +1 -1
- package/dist/core/storage/provider.js +2 -2
- package/dist/core/storage/schema-catalog.d.ts +120 -0
- package/dist/core/storage/schema-catalog.js +351 -0
- package/dist/core/storage/schema-catalog.js.map +1 -0
- package/dist/core/storage/selection.js +2 -2
- package/dist/core/storage/session/branch-fork-source.code.js +47 -25
- package/dist/core/storage/session/branch-fork-source.code.js.map +1 -1
- package/dist/core/storage/session/branch-fork-source.impl.js +3 -3
- package/dist/core/storage/session/branch-fork-source.js +3 -3
- package/dist/core/storage/session/card-view.impl.js +3 -3
- package/dist/core/storage/session/card-view.js +3 -3
- package/dist/core/storage/session/child-reader.code.js +4 -4
- package/dist/core/storage/session/child-reader.impl.js +3 -3
- package/dist/core/storage/session/child-reader.js +3 -3
- package/dist/core/storage/session/chunked-resume-projection.code.js +1 -1
- package/dist/core/storage/session/chunked-resume-projection.impl.js +3 -3
- package/dist/core/storage/session/chunked-resume-projection.js +3 -3
- package/dist/core/storage/session/errors.js +1 -1
- package/dist/core/storage/session/expanded-child-details.code.js +4 -4
- package/dist/core/storage/session/expanded-child-details.impl.js +3 -3
- package/dist/core/storage/session/expanded-child-details.js +3 -3
- package/dist/core/storage/session/fork-detach.d.ts +118 -0
- package/dist/core/storage/session/fork-row-bytes.impl.js +3 -3
- package/dist/core/storage/session/fork-row-bytes.js +3 -3
- package/dist/core/storage/session/fork-row-index.impl.js +3 -3
- package/dist/core/storage/session/fork-row-index.js +3 -3
- package/dist/core/storage/session/fork-schema.js +53 -0
- package/dist/core/storage/session/fork-schema.js.map +1 -0
- package/dist/core/storage/session/fork-segments.d.ts +58 -0
- package/dist/core/storage/session/fork-staging.code.js +176 -36
- package/dist/core/storage/session/fork-staging.code.js.map +1 -1
- package/dist/core/storage/session/fork-staging.impl.js +3 -3
- package/dist/core/storage/session/fork-staging.js +3 -3
- package/dist/core/storage/session/fork-sweep.js +61 -0
- package/dist/core/storage/session/fork-sweep.js.map +1 -0
- package/dist/core/storage/session/fork-window.code.js +4 -4
- package/dist/core/storage/session/fork-window.impl.js +3 -3
- package/dist/core/storage/session/fork-window.js +3 -3
- package/dist/core/storage/session/history-pages.impl.js +3 -3
- package/dist/core/storage/session/history-pages.js +3 -3
- package/dist/core/storage/session/jsonl-entry-projection.impl.js +3 -3
- package/dist/core/storage/session/jsonl-entry-projection.js +3 -3
- package/dist/core/storage/session/jsonl-session-store.d.ts +37 -1
- package/dist/core/storage/session/jsonl-session-store.impl.js +3 -3
- package/dist/core/storage/session/jsonl-session-store.js +3 -3
- package/dist/core/storage/session/memory-session-store.impl.js +3 -3
- package/dist/core/storage/session/memory-session-store.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.code.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.impl.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.js +3 -3
- package/dist/core/storage/session/released-history-files.code.js +3 -3
- package/dist/core/storage/session/released-history-files.impl.js +3 -3
- package/dist/core/storage/session/released-history-files.js +3 -3
- package/dist/core/storage/session/resident-fork-rows.code.js +1 -1
- package/dist/core/storage/session/resident-fork-rows.impl.js +3 -3
- package/dist/core/storage/session/resident-fork-rows.js +3 -3
- package/dist/core/storage/session/session-resume.impl.js +3 -3
- package/dist/core/storage/session/session-resume.js +3 -3
- package/dist/core/storage/session/session-search-index.d.ts +5 -0
- package/dist/core/storage/session/snapshot-cut.impl.js +3 -3
- package/dist/core/storage/session/snapshot-cut.js +3 -3
- package/dist/core/storage/session/snapshot-history.code.js +4 -4
- package/dist/core/storage/session/snapshot-history.impl.js +3 -3
- package/dist/core/storage/session/snapshot-history.js +3 -3
- package/dist/core/storage/session/sql-chat-records.d.ts +15 -0
- package/dist/core/storage/session/sql-session-store.code.js +1 -1
- package/dist/core/storage/session/sql-session-store.d.ts +445 -11
- package/dist/core/storage/session/sql-session-store.impl.js +4 -4
- package/dist/core/storage/session/sql-session-store.js +4 -4
- package/dist/core/storage/session/tree-outline.impl.js +3 -3
- package/dist/core/storage/session/tree-outline.js +3 -3
- package/dist/core/storage/session/tree-presentation.code.js +1 -1
- package/dist/core/storage/session/tree-presentation.impl.js +3 -3
- package/dist/core/storage/session/tree-presentation.js +3 -3
- package/dist/core/storage/session/types.d.ts +36 -0
- package/dist/core/storage/sqlite-facade.d.ts +54 -6
- package/dist/core/storage/sqlite-facade.js +384 -18
- package/dist/core/storage/sqlite-facade.js.map +1 -1
- package/dist/core/storage/statement-sequence.d.ts +83 -0
- package/dist/core/storage/statement-sequence.js +21 -0
- package/dist/core/storage/statement-sequence.js.map +1 -1
- package/dist/core/storage/storage-status.code.js +1 -1
- package/dist/core/storage/storage-status.impl.js +3 -3
- package/dist/core/storage/storage-status.js +3 -3
- package/dist/core/storage/team.code.js +1 -1
- package/dist/core/storage/team.impl.js +3 -3
- package/dist/core/storage/team.js +3 -3
- package/dist/core/structured-output/index.code.js +1 -1
- package/dist/core/structured-output/index.impl.js +3 -3
- package/dist/core/structured-output/index.js +3 -3
- package/dist/core/tasks/task-completion-entry.code.js +1 -1
- package/dist/core/tasks/task-completion-entry.impl.js +3 -3
- package/dist/core/tasks/task-completion-entry.js +3 -3
- package/dist/core/tasks/task-file-history.code.js +4 -4
- package/dist/core/tasks/task-file-history.impl.js +3 -3
- package/dist/core/tasks/task-file-history.js +3 -3
- package/dist/core/tasks/task-reference-archive.code.js +5 -5
- package/dist/core/tasks/task-reference-archive.js +3 -3
- package/dist/core/tasks/task-reference-identity.js +3 -3
- package/dist/core/tasks/task-reference-stream.impl.js +3 -3
- package/dist/core/tasks/task-reference-stream.js +3 -3
- package/dist/core/tasks/task-unsaved-answer.impl.js +3 -3
- package/dist/core/tasks/task-unsaved-answer.js +3 -3
- package/dist/core/tasks/task-view-source.code.js +1 -1
- package/dist/core/tasks/task-view-source.impl.js +3 -3
- package/dist/core/tasks/task-view-source.js +3 -3
- package/dist/core/tools/bash.d.ts +8 -4
- package/dist/core/tools/history-session.d.ts +7 -0
- package/dist/core/tools/history-tasks.d.ts +123 -0
- package/dist/core/tools/kill.d.ts +5 -2
- package/dist/core/tools/powershell.d.ts +2 -2
- package/dist/core/tools/read-url.code.js +3 -3
- package/dist/core/tools/read-url.impl.js +3 -3
- package/dist/core/tools/read-url.js +3 -3
- package/dist/core/tools/read.d.ts +12 -2
- package/dist/core/tools/resource-selectors.d.ts +2 -0
- package/dist/core/tools/search.d.ts +12 -2
- package/dist/core/worktree-snapshot/blob-store.d.ts +45 -2
- package/dist/core/worktree-snapshot/blob-store.js +228 -60
- package/dist/core/worktree-snapshot/blob-store.js.map +1 -1
- package/dist/core/worktree-snapshot/errors.code.js +3 -3
- package/dist/core/worktree-snapshot/errors.impl.js +3 -3
- package/dist/core/worktree-snapshot/errors.js +3 -3
- package/dist/core/worktree-snapshot/fork-snapshot-index.js +121 -0
- package/dist/core/worktree-snapshot/fork-snapshot-index.js.map +1 -0
- package/dist/core/worktree-snapshot/session-index-reset.impl.js +3 -3
- package/dist/core/worktree-snapshot/session-index-reset.js +3 -3
- package/dist/extensions/codemode/execute.code.js +3 -3
- package/dist/extensions/codemode/execute.impl.js +3 -3
- package/dist/extensions/codemode/execute.js +3 -3
- package/dist/extensions/codemode/renderer.code.js +2 -2
- package/dist/extensions/codemode/renderer.impl.js +3 -3
- package/dist/extensions/codemode/renderer.js +3 -3
- package/dist/extensions/mcp/cli.code.js +3 -3
- package/dist/extensions/mcp/cli.impl.js +3 -3
- package/dist/extensions/mcp/cli.js +3 -3
- package/dist/extensions/mcp/cli.lazy.code.js +2 -2
- package/dist/extensions/mcp/cli.lazy.impl.js +3 -3
- package/dist/extensions/mcp/cli.lazy.js +3 -3
- package/dist/extensions/mcp/runtime.code.js +1 -1
- package/dist/extensions/mcp/runtime.impl.js +3 -3
- package/dist/extensions/mcp/runtime.js +3 -3
- package/dist/index.js +8 -8
- package/dist/main-first-time-setup.code.js +2 -2
- package/dist/main-first-time-setup.impl.js +3 -3
- package/dist/main-first-time-setup.js +3 -3
- package/dist/main.js +1 -1
- package/dist/modes/interactive/components/agent-panel.d.ts +1 -0
- package/dist/modes/interactive/components/stored-tree-view.code.js +3 -3
- package/dist/modes/interactive/components/stored-tree-view.impl.js +3 -3
- package/dist/modes/interactive/components/stored-tree-view.js +3 -3
- package/dist/modes/interactive/components/task-inspector.d.ts +2 -0
- package/dist/modes/interactive/components/user-message-selector-archive.code.js +1 -1
- package/dist/modes/interactive/components/user-message-selector-archive.impl.js +3 -3
- package/dist/modes/interactive/components/user-message-selector-archive.js +3 -3
- package/dist/modes/interactive/interactive-mode-helpers.d.ts +2 -2
- package/dist/modes/print-mode.js +1 -1
- package/dist/modes/rpc/agent-panel-bridge.d.ts +5 -0
- package/dist/package-manager-cli.code.js +7 -7
- package/dist/package-manager-cli.impl.js +3 -3
- package/dist/package-manager-cli.js +3 -3
- package/dist/rpc-entry.js +1 -1
- package/dist/startup-files.json +1 -1
- package/dist/startup-stages/0.js +1 -1
- package/dist/startup-stages/1.js +1 -1
- package/dist/startup-stages/10.js +1 -1
- package/dist/startup-stages/12.js +1 -1
- package/dist/startup-stages/2.js +9 -1
- package/dist/startup-stages/3.js +1 -6
- package/dist/startup-stages/5.js +1 -1
- package/dist/startup-stages/7.js +1 -1
- package/dist/startup-stages/8.js +2 -2
- package/dist/utils/startup-database-spare.code.js +3 -3
- package/dist/utils/startup-database-spare.impl.js +3 -3
- package/dist/utils/startup-database-spare.js +3 -3
- package/dist/utils/tools-manager.code.js +1 -1
- package/dist/utils/tools-manager.impl.js +3 -3
- package/dist/utils/tools-manager.js +3 -3
- package/docs/background-tasks.md +123 -23
- package/docs/compaction.md +18 -0
- package/docs/docs.json +2 -0
- package/docs/environment-variables.md +1 -1
- package/docs/getting-started/installation.md +9 -2
- package/docs/guides/postgres-pgbouncer.md +346 -0
- package/docs/guides/postgres-tuning.md +311 -0
- package/docs/guides/resume-on-any-machine.md +2 -2
- package/docs/guides.md +2 -0
- package/docs/index.md +1 -1
- package/docs/libraries/agent-core.md +1 -1
- package/docs/libraries/ai.md +2 -2
- package/docs/libraries/codemode.md +1 -1
- package/docs/libraries/storage-libsql.md +6 -1
- package/docs/libraries/storage-postgres.md +11 -6
- package/docs/libraries/tui.md +1 -1
- package/docs/libraries.md +2 -2
- package/docs/programmatic.md +1 -1
- package/docs/quickstart.md +1 -1
- package/docs/sdk/storage.md +1 -1
- package/docs/sdk/web-server.md +1 -3
- package/docs/sdk.md +1 -7
- package/docs/sessions.md +67 -2
- package/docs/settings.md +20 -1
- package/docs/skills/authoring.md +1 -1
- package/docs/skills.md +79 -6
- package/docs/storage.md +305 -14
- package/docs/subagents/reference.md +2 -2
- package/docs/subagents.md +4 -3
- package/docs/tools.md +44 -10
- package/docs/windows.md +1 -1
- package/package.json +9 -9
- package/dist/_shared/sdk-RRLVN7ER.js.map +0 -1
- package/dist/_shared/settings-startup-4QCVCI53.js.map +0 -1
- package/dist/_shared/startup-0-0-4VG2G44V.js.map +0 -1
- package/dist/_shared/startup-0-1-XTIL65D4.js.map +0 -1
- package/dist/_shared/startup-0-2-27OWFHV6.js.map +0 -1
- package/dist/_shared/startup-0-3-T4DVFYWX.js.map +0 -1
- package/dist/_shared/startup-0-5-FD2P735I.js.map +0 -1
- package/dist/_shared/startup-8-1-4KANEHRA.js.map +0 -1
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "../../../_shared/rolldown-runtime-BGM3D5V3.js";
|
|
2
|
-
import { ChildCatalog } from "../../../_shared/startup-0-1-
|
|
2
|
+
import { ChildCatalog } from "../../../_shared/startup-0-1-7T2IAE7J.js";
|
|
3
3
|
import { SessionConflictError } from "./errors.js";
|
|
4
4
|
import { historyChunks, historyPages, readSessionRange } from "../../../_shared/startup-8-0-34CBHPZH.js";
|
|
5
5
|
import { treeOutlinePages } from "../../../_shared/tree-outline-MUEPK5B7.js";
|
|
6
|
-
import "../../../_shared/settings-startup-
|
|
6
|
+
import "../../../_shared/settings-startup-HXQLSUWM.js";
|
|
7
7
|
// dist/core/storage/session/child-reader.js
|
|
8
8
|
async function* headings(store, id, epoch, through, seqs, signal) {
|
|
9
9
|
for (let at = 0; at < seqs.length;) {
|
|
@@ -99,7 +99,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
99
99
|
return (async () => {
|
|
100
100
|
const root = new URL("../../../", import.meta.url);
|
|
101
101
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
102
|
-
const key = `${root.href}#0.10.
|
|
102
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
103
103
|
let release = releases.get(key);
|
|
104
104
|
if (release === undefined) {
|
|
105
105
|
const current = (async () => {
|
|
@@ -127,7 +127,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
127
127
|
} catch {
|
|
128
128
|
// No installation to read, as in a bundle of the package: the release the process runs decides.
|
|
129
129
|
}
|
|
130
|
-
const updatedTo = typeof installed === "string" && installed !== "0.10.
|
|
130
|
+
const updatedTo = typeof installed === "string" && installed !== "0.10.11-alpha.2" ? installed : running !== undefined && running.version !== "0.10.11-alpha.2" ? "0.10.11-alpha.2" : undefined;
|
|
131
131
|
if (updatedTo === undefined) throw error;
|
|
132
132
|
const application = typeof running?.name === "string" ? running.name : "atomic";
|
|
133
133
|
const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import "../../../_shared/rolldown-runtime-BGM3D5V3.js";
|
|
2
|
-
export { chunkedAnswerContent, chunkedAnswerHeader, chunkedBranchState, chunkedChildHeading, chunkedEntryHasId, chunkedForkLink, chunkedPrefixFields, chunkedResumeProjection, chunkedTaskDetailFields, chunkedTreeOutline, forkSeedFields, messageHeadIn, messageRoleIn, projectForkMetadata, read, readChunkedWorkflowRunId, readValue, skip, stringValue } from "../../../_shared/startup-0-5-
|
|
2
|
+
export { chunkedAnswerContent, chunkedAnswerHeader, chunkedBranchState, chunkedChildHeading, chunkedEntryHasId, chunkedForkLink, chunkedPrefixFields, chunkedResumeProjection, chunkedTaskDetailFields, chunkedTreeOutline, forkSeedFields, messageHeadIn, messageRoleIn, projectForkMetadata, read, readChunkedWorkflowRunId, readValue, skip, stringValue } from "../../../_shared/startup-0-5-YDW47QX6.js";
|
|
3
3
|
//# sourceMappingURL=chunked-resume-projection.code.js.map
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "../../../_shared/rolldown-runtime-BGM3D5V3.js";
|
|
2
|
-
import "../../../_shared/settings-startup-
|
|
2
|
+
import "../../../_shared/settings-startup-HXQLSUWM.js";
|
|
3
3
|
// dist/core/storage/session/errors.js
|
|
4
4
|
var SessionFormatVersionError = class extends Error {
|
|
5
5
|
path;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { __name } from "../../../_shared/rolldown-runtime-BGM3D5V3.js";
|
|
2
|
-
import { read, skip, stringValue } from "../../../_shared/startup-0-5-
|
|
2
|
+
import { read, skip, stringValue } from "../../../_shared/startup-0-5-YDW47QX6.js";
|
|
3
3
|
import { SessionConflictError } from "./errors.js";
|
|
4
4
|
import { historyChunks } from "../../../_shared/startup-8-0-34CBHPZH.js";
|
|
5
|
-
import { SESSION_HISTORY_CHUNK_BYTES, yieldSessionTurn } from "../../../_shared/settings-startup-
|
|
5
|
+
import { SESSION_HISTORY_CHUNK_BYTES, yieldSessionTurn } from "../../../_shared/settings-startup-HXQLSUWM.js";
|
|
6
6
|
// dist/core/storage/session/card-message-projection.js
|
|
7
7
|
function* object(first, fields) {
|
|
8
8
|
if (first.name !== "startObject") {
|
|
@@ -643,7 +643,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
643
643
|
return (async () => {
|
|
644
644
|
const root = new URL("../../../", import.meta.url);
|
|
645
645
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
646
|
-
const key = `${root.href}#0.10.
|
|
646
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
647
647
|
let release = releases.get(key);
|
|
648
648
|
if (release === undefined) {
|
|
649
649
|
const current = (async () => {
|
|
@@ -671,7 +671,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
671
671
|
} catch {
|
|
672
672
|
// No installation to read, as in a bundle of the package: the release the process runs decides.
|
|
673
673
|
}
|
|
674
|
-
const updatedTo = typeof installed === "string" && installed !== "0.10.
|
|
674
|
+
const updatedTo = typeof installed === "string" && installed !== "0.10.11-alpha.2" ? installed : running !== undefined && running.version !== "0.10.11-alpha.2" ? "0.10.11-alpha.2" : undefined;
|
|
675
675
|
if (updatedTo === undefined) throw error;
|
|
676
676
|
const application = typeof running?.name === "string" ? running.name : "atomic";
|
|
677
677
|
const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Detaching lazy forks from a session (Neon's detach_ancestor). A fork in a SQL store reads the rows it inherited
|
|
3
|
+
* through segments that point at the sessions owning them, which keep those rows while any segment points at them. To
|
|
4
|
+
* really delete or rewrite such a session, every fork still pointing at it first gets its own copy of those rows:
|
|
5
|
+
*
|
|
6
|
+
* 1. Block: the segments pin the parent's rows, and a progress row records the detach and the child's original map.
|
|
7
|
+
* 2. Copy: a page of the parent's rows moves into the child at the global seqs the segment gave them, and in the same
|
|
8
|
+
* transaction the segment shrinks past them, so every seq is covered by a segment or by a row of the child's own,
|
|
9
|
+
* never both, and the child reads the same at every commit.
|
|
10
|
+
* 3. Publish: each page commits; the segments are the progress, so a crash resumes with the segments that remain.
|
|
11
|
+
* 4-6. The last page also removes the child's last segment on the parent, re-points at the child's copy each other
|
|
12
|
+
* fork of the parent that reads only rows the child's prefix holds (its cut-off at or below the child's), and
|
|
13
|
+
* removes the progress row, in one transaction.
|
|
14
|
+
*
|
|
15
|
+
* A detach locks the sessions whose segments it changes for update, in ID order, and never the parent. The store's
|
|
16
|
+
* delete and replace lock a session for update before they list the references to it, and a fork locks every session
|
|
17
|
+
* its segments name for key share, so neither misses a reference another transaction is adding. Re-pointing a fork at
|
|
18
|
+
* the child adds a reference to the child, which the detach already holds for update. Locking the parent instead
|
|
19
|
+
* would deadlock against the parent's replace, which holds the parent's row while it waits for its forks' rows.
|
|
20
|
+
*/
|
|
21
|
+
import type { SqliteExecutor } from "../database.js";
|
|
22
|
+
import { type ForkSegment } from "./fork-segments.js";
|
|
23
|
+
export declare function setForkCopyRefusalNote(note: (fields: Readonly<Record<string, string | number>>) => void): void;
|
|
24
|
+
/** Notes `error` once when it is a refused copy of shared rows; resolves nothing and never throws. */
|
|
25
|
+
export declare function noteForkCopyRefusal(error: unknown, operation: string): void;
|
|
26
|
+
/** Rows a detach copies in one transaction, which bounds how long it holds the write lock. */
|
|
27
|
+
export declare const FORK_DETACH_PAGE_ROWS = 2000;
|
|
28
|
+
/** The tables a session's stored rows are in, and the tombstones of deleted sessions forks still read. */
|
|
29
|
+
export interface ForkPinTables {
|
|
30
|
+
readonly entries: string;
|
|
31
|
+
readonly entryChunks: string;
|
|
32
|
+
readonly searchTexts: string;
|
|
33
|
+
readonly blobs: string;
|
|
34
|
+
readonly blobChunks: string;
|
|
35
|
+
readonly tombstones: string;
|
|
36
|
+
readonly forkSegments: string;
|
|
37
|
+
readonly forkLineage: string;
|
|
38
|
+
}
|
|
39
|
+
/** What a SQL session store gives detach: its fork segments, and transactions to change them in. */
|
|
40
|
+
export interface ForkDetachHost {
|
|
41
|
+
readonly pinTables: ForkPinTables;
|
|
42
|
+
/** `<prefix>session_fork_detach`, created with the other fork tables: detaches in progress. */
|
|
43
|
+
readonly forkDetachTable: string;
|
|
44
|
+
/** Runs `body` in one write transaction of the store. */
|
|
45
|
+
forkTransaction<T>(body: (tx: SqliteExecutor) => Promise<T>): Promise<T>;
|
|
46
|
+
/** The session's segments, ordered by `baseSeq`. */
|
|
47
|
+
forkSegments(tx: SqliteExecutor, sessionId: string): Promise<readonly ForkSegment[]>;
|
|
48
|
+
/** The sessions with a segment pointing at `sourceId`, ordered by ID. */
|
|
49
|
+
forkChildren(tx: SqliteExecutor, sourceId: string): Promise<readonly string[]>;
|
|
50
|
+
/**
|
|
51
|
+
* Copies the rows `pieces` map, in seq order with their chunks, search texts and blobs, into the child at the seqs of
|
|
52
|
+
* its view they cover, then removes them from the child's segments. Each piece lies within one of the child's
|
|
53
|
+
* segments, so the child's view is the same before and after.
|
|
54
|
+
*/
|
|
55
|
+
materializeForkSegments(tx: SqliteExecutor, childId: string, pieces: readonly ForkSegment[]): Promise<void>;
|
|
56
|
+
/** Replaces the session's segments with `segments`, and moves its fork generation on. */
|
|
57
|
+
writeForkSegments(tx: SqliteExecutor, sessionId: string, segments: readonly ForkSegment[]): Promise<void>;
|
|
58
|
+
/**
|
|
59
|
+
* Locks the sessions `ids` in ID order: `key-share` to add a reference to them (which leaves their appends free),
|
|
60
|
+
* `update` to drop one they hold or to delete them.
|
|
61
|
+
*/
|
|
62
|
+
lockForkSources(tx: SqliteExecutor, ids: readonly string[], mode: "key-share" | "update"): Promise<void>;
|
|
63
|
+
/** The clause that locks the rows a read selects, for update or for key share; none where writers run one at a time. */
|
|
64
|
+
lockClause(mode: "key-share" | "update"): string;
|
|
65
|
+
/** The session's rewrite epoch, which a replace or a truncation changes and an append does not. */
|
|
66
|
+
forkRewriteEpoch(tx: SqliteExecutor, sessionId: string): Promise<string | undefined>;
|
|
67
|
+
}
|
|
68
|
+
export interface ForkDetachOptions {
|
|
69
|
+
/** Re-point the parent's other forks at the child's copy of the rows it holds. Default true. */
|
|
70
|
+
readonly reparent?: boolean;
|
|
71
|
+
/** Rows copied a transaction. Default {@link FORK_DETACH_PAGE_ROWS}. */
|
|
72
|
+
readonly pageRows?: number;
|
|
73
|
+
}
|
|
74
|
+
export interface ForkDetachReport {
|
|
75
|
+
/** Forks that copied the parent's rows they read. */
|
|
76
|
+
readonly detached: readonly string[];
|
|
77
|
+
/** Forks re-pointed at a detached fork's copy instead. */
|
|
78
|
+
readonly reparented: readonly string[];
|
|
79
|
+
}
|
|
80
|
+
interface DetachProgress {
|
|
81
|
+
readonly reparent: boolean;
|
|
82
|
+
/** The child's segments on the parent when the detach started: where its copy of each parent row is. */
|
|
83
|
+
readonly original: readonly ForkSegment[];
|
|
84
|
+
/**
|
|
85
|
+
* The parent's and the child's rewrite epochs when the detach started. `original` describes the child's rows only
|
|
86
|
+
* while neither was rewritten: a rewritten parent's seq is another row, a rewritten child's row is another row.
|
|
87
|
+
*/
|
|
88
|
+
readonly epochs: readonly [string | undefined, string | undefined];
|
|
89
|
+
}
|
|
90
|
+
/** The forks whose segments name `sessionId`, after locking it for update. */
|
|
91
|
+
export declare function lockedReferrers(host: ForkDetachHost, tx: SqliteExecutor, sessionId: string): Promise<readonly string[]>;
|
|
92
|
+
/** Removes the rows a session stores and its tombstone: nothing names them, and the session is gone or replaced. */
|
|
93
|
+
export declare function removeStoredRows(host: ForkDetachHost, tx: SqliteExecutor, sessionId: string): Promise<void>;
|
|
94
|
+
export declare function isTombstoned(host: ForkDetachHost, tx: SqliteExecutor, sessionId: string): Promise<boolean>;
|
|
95
|
+
/**
|
|
96
|
+
* Within `tx`, copies every row of `parentId` the child reads into the child and removes its segments on the parent,
|
|
97
|
+
* as a caller about to rewrite the parent in the same transaction needs. With `reparent`, the parent's other forks are
|
|
98
|
+
* re-pointed at the child's copy when it holds every row they read of the parent at the same seqs. `started` is how a detach a page at a time found
|
|
99
|
+
* the child when it started; its map of the child's rows holds only while neither session was rewritten since, so
|
|
100
|
+
* a rewrite of either skips the re-pointing, and the other forks keep reading the parent. Resolves with the forks
|
|
101
|
+
* re-pointed.
|
|
102
|
+
*/
|
|
103
|
+
export declare function detachForkWithin(host: ForkDetachHost, tx: SqliteExecutor, parentId: string, childId: string, reparent: boolean, started?: Pick<DetachProgress, "original" | "epochs">): Promise<string[]>;
|
|
104
|
+
/**
|
|
105
|
+
* Detaches `childId` from `parentId` a page at a time, each page its own transaction; see the module comment. A detach
|
|
106
|
+
* a crash stopped resumes where it stopped when it runs again, with the options it started with.
|
|
107
|
+
*/
|
|
108
|
+
export declare function detachFork(host: ForkDetachHost, parentId: string, childId: string, options?: ForkDetachOptions): Promise<ForkDetachReport>;
|
|
109
|
+
/**
|
|
110
|
+
* Detaches every fork still pointing at `parentId`, so the parent's rows can go: first the fork that holds most of the
|
|
111
|
+
* parent's rows, re-pointing the others at its copy when it holds all they read, then any fork that still reads
|
|
112
|
+
* rows only the parent has. Detaches a crash stopped are finished first.
|
|
113
|
+
*/
|
|
114
|
+
export declare function detachForkChildren(host: ForkDetachHost, parentId: string, options?: ForkDetachOptions): Promise<ForkDetachReport>;
|
|
115
|
+
/** Finishes every detach a crash stopped, as each started. */
|
|
116
|
+
export declare function resumeForkDetaches(host: ForkDetachHost): Promise<ForkDetachReport>;
|
|
117
|
+
export {};
|
|
118
|
+
//# sourceMappingURL=fork-detach.d.ts.map
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ try {
|
|
|
6
6
|
} catch (error) {
|
|
7
7
|
const root = new URL("../../../", import.meta.url);
|
|
8
8
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
9
|
-
const key = `${root.href}#0.10.
|
|
9
|
+
const key = `${root.href}#0.10.11-alpha.2`;
|
|
10
10
|
let release = releases.get(key);
|
|
11
11
|
if (release === undefined) {
|
|
12
12
|
const current = (async () => {
|
|
@@ -27,8 +27,8 @@ try {
|
|
|
27
27
|
release = current;
|
|
28
28
|
}
|
|
29
29
|
const running = await release;
|
|
30
|
-
if (running === undefined || running.version === "0.10.
|
|
31
|
-
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.
|
|
30
|
+
if (running === undefined || running.version === "0.10.11-alpha.2") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.11-alpha.2 while this session was running; restart it to keep using session storage.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { renderStorageIdentifiers } from "../prefix.js";
|
|
2
|
+
/**
|
|
3
|
+
* The tables of forks that share their parent's history instead of copying it (#6560): `<prefix>session_fork_segments`,
|
|
4
|
+
* which maps a fork's inherited seqs onto the rows its sources store, and `<prefix>session_fork_lineage`, one row per
|
|
5
|
+
* such fork; `<prefix>session_fork_tombstones`, one row per deleted session whose rows forks still read, which those
|
|
6
|
+
* forks and the sweep that removes the rows lock; and `<prefix>session_fork_detach`, the progress of a fork copying
|
|
7
|
+
* the rows it read from a source into its own. They exist only in a store whose sessions schema was raised to version 3
|
|
8
|
+
* by the switch a store's open or `atomic storage migrate` makes once no older build runs a session there, in the same
|
|
9
|
+
* transaction; a store that was not switched keeps only the tables every older build reads.
|
|
10
|
+
*/
|
|
11
|
+
export const SESSION_FORK_TABLES = Object.freeze({
|
|
12
|
+
forkSegments: "fork_segments",
|
|
13
|
+
forkLineage: "fork_lineage",
|
|
14
|
+
forkTombstones: "fork_tombstones",
|
|
15
|
+
forkDetach: "fork_detach",
|
|
16
|
+
});
|
|
17
|
+
/** The fork tables under `prefix`. */
|
|
18
|
+
export function sessionForkTables(prefix) {
|
|
19
|
+
return renderStorageIdentifiers("sessions", SESSION_FORK_TABLES, prefix);
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The statements that create the fork tables, idempotently: in the transaction that raises the sessions schema to the
|
|
23
|
+
* version that turns shared-history forks on, or in the one that creates a new database's sessions schema at that
|
|
24
|
+
* version. `generation` is a token that changes with every change to a fork's segments and never repeats for an id, so
|
|
25
|
+
* a reader's cached segments are keyed by it.
|
|
26
|
+
*/
|
|
27
|
+
export function sharedHistoryTablesScript(dialect, tables) {
|
|
28
|
+
const { int, text } = dialect.types;
|
|
29
|
+
return `
|
|
30
|
+
CREATE TABLE IF NOT EXISTS ${tables.forkSegments} (
|
|
31
|
+
session_id ${text} NOT NULL, idx ${int} NOT NULL, source_id ${text} NOT NULL,
|
|
32
|
+
from_seq ${int} NOT NULL, to_seq ${int} NOT NULL, base_seq ${int} NOT NULL,
|
|
33
|
+
PRIMARY KEY(session_id, idx)
|
|
34
|
+
)${dialect.tableOptions};
|
|
35
|
+
CREATE INDEX IF NOT EXISTS ${tables.forkSegments}_source ON ${tables.forkSegments} (source_id);
|
|
36
|
+
CREATE TABLE IF NOT EXISTS ${tables.forkLineage} (
|
|
37
|
+
session_id ${text} NOT NULL PRIMARY KEY, parent_id ${text}, cut_seq ${int}, generation ${text} NOT NULL
|
|
38
|
+
)${dialect.tableOptions};
|
|
39
|
+
CREATE TABLE IF NOT EXISTS ${tables.forkTombstones} (
|
|
40
|
+
session_id ${text} NOT NULL PRIMARY KEY, deleted_at ${text} NOT NULL
|
|
41
|
+
)${dialect.tableOptions};
|
|
42
|
+
CREATE TABLE IF NOT EXISTS ${tables.forkDetach} (
|
|
43
|
+
parent_id ${text} NOT NULL, child_id ${text} NOT NULL, reparent ${int} NOT NULL,
|
|
44
|
+
original_segments ${text} NOT NULL, parent_epoch ${text}, child_epoch ${text},
|
|
45
|
+
PRIMARY KEY(parent_id, child_id)
|
|
46
|
+
)${dialect.tableOptions};
|
|
47
|
+
`;
|
|
48
|
+
}
|
|
49
|
+
/** Creates the fork tables in `tx`: see {@link sharedHistoryTablesScript}. */
|
|
50
|
+
export async function createSharedHistoryTables(tx, dialect, tables) {
|
|
51
|
+
await tx.exec(sharedHistoryTablesScript(dialect, tables));
|
|
52
|
+
}
|
|
53
|
+
//# sourceMappingURL=fork-schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fork-schema.js","sourceRoot":"","sources":["../../../../src/core/storage/session/fork-schema.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AAExD;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC,MAAM,CAAC;IAChD,YAAY,EAAE,eAAe;IAC7B,WAAW,EAAE,cAAc;IAC3B,cAAc,EAAE,iBAAiB;IACjC,UAAU,EAAE,aAAa;CACzB,CAAC,CAAC;AAIH,sCAAsC;AACtC,MAAM,UAAU,iBAAiB,CAAC,MAAe;IAChD,OAAO,wBAAwB,CAAC,UAAU,EAAE,mBAAmB,EAAE,MAAM,CAAC,CAAC;AAC1E,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,yBAAyB,CAAC,OAAuB,EAAE,MAAyB;IAC3F,MAAM,EAAE,GAAG,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,KAAK,CAAC;IACpC,OAAO;+BACuB,MAAM,CAAC,YAAY;gBAClC,IAAI,kBAAkB,GAAG,wBAAwB,IAAI;cACvD,GAAG,qBAAqB,GAAG,uBAAuB,GAAG;;KAE9D,OAAO,CAAC,YAAY;+BACM,MAAM,CAAC,YAAY,cAAc,MAAM,CAAC,YAAY;+BACpD,MAAM,CAAC,WAAW;gBACjC,IAAI,oCAAoC,IAAI,aAAa,GAAG,gBAAgB,IAAI;KAC3F,OAAO,CAAC,YAAY;+BACM,MAAM,CAAC,cAAc;gBACpC,IAAI,qCAAqC,IAAI;KACxD,OAAO,CAAC,YAAY;+BACM,MAAM,CAAC,UAAU;eACjC,IAAI,uBAAuB,IAAI,uBAAuB,GAAG;uBACjD,IAAI,2BAA2B,IAAI,iBAAiB,IAAI;;KAE1E,OAAO,CAAC,YAAY;EACvB,CAAC;AACH,CAAC;AAED,8EAA8E;AAC9E,MAAM,CAAC,KAAK,UAAU,yBAAyB,CAC9C,EAAkB,EAClB,OAAuB,EACvB,MAAyB;IAEzB,MAAM,EAAE,CAAC,IAAI,CAAC,yBAAyB,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC;AAC3D,CAAC","sourcesContent":["import type { SqliteExecutor } from \"../database.js\";\nimport type { StorageDialect } from \"../dialect.js\";\nimport { renderStorageIdentifiers } from \"../prefix.js\";\n\n/**\n * The tables of forks that share their parent's history instead of copying it (#6560): `<prefix>session_fork_segments`,\n * which maps a fork's inherited seqs onto the rows its sources store, and `<prefix>session_fork_lineage`, one row per\n * such fork; `<prefix>session_fork_tombstones`, one row per deleted session whose rows forks still read, which those\n * forks and the sweep that removes the rows lock; and `<prefix>session_fork_detach`, the progress of a fork copying\n * the rows it read from a source into its own. They exist only in a store whose sessions schema was raised to version 3\n * by the switch a store's open or `atomic storage migrate` makes once no older build runs a session there, in the same\n * transaction; a store that was not switched keeps only the tables every older build reads.\n */\nexport const SESSION_FORK_TABLES = Object.freeze({\n\tforkSegments: \"fork_segments\",\n\tforkLineage: \"fork_lineage\",\n\tforkTombstones: \"fork_tombstones\",\n\tforkDetach: \"fork_detach\",\n});\n\nexport type SessionForkTables = Readonly<Record<keyof typeof SESSION_FORK_TABLES, string>>;\n\n/** The fork tables under `prefix`. */\nexport function sessionForkTables(prefix?: string): SessionForkTables {\n\treturn renderStorageIdentifiers(\"sessions\", SESSION_FORK_TABLES, prefix);\n}\n\n/**\n * The statements that create the fork tables, idempotently: in the transaction that raises the sessions schema to the\n * version that turns shared-history forks on, or in the one that creates a new database's sessions schema at that\n * version. `generation` is a token that changes with every change to a fork's segments and never repeats for an id, so\n * a reader's cached segments are keyed by it.\n */\nexport function sharedHistoryTablesScript(dialect: StorageDialect, tables: SessionForkTables): string {\n\tconst { int, text } = dialect.types;\n\treturn `\n\t\tCREATE TABLE IF NOT EXISTS ${tables.forkSegments} (\n\t\t\tsession_id ${text} NOT NULL, idx ${int} NOT NULL, source_id ${text} NOT NULL,\n\t\t\tfrom_seq ${int} NOT NULL, to_seq ${int} NOT NULL, base_seq ${int} NOT NULL,\n\t\t\tPRIMARY KEY(session_id, idx)\n\t\t)${dialect.tableOptions};\n\t\tCREATE INDEX IF NOT EXISTS ${tables.forkSegments}_source ON ${tables.forkSegments} (source_id);\n\t\tCREATE TABLE IF NOT EXISTS ${tables.forkLineage} (\n\t\t\tsession_id ${text} NOT NULL PRIMARY KEY, parent_id ${text}, cut_seq ${int}, generation ${text} NOT NULL\n\t\t)${dialect.tableOptions};\n\t\tCREATE TABLE IF NOT EXISTS ${tables.forkTombstones} (\n\t\t\tsession_id ${text} NOT NULL PRIMARY KEY, deleted_at ${text} NOT NULL\n\t\t)${dialect.tableOptions};\n\t\tCREATE TABLE IF NOT EXISTS ${tables.forkDetach} (\n\t\t\tparent_id ${text} NOT NULL, child_id ${text} NOT NULL, reparent ${int} NOT NULL,\n\t\t\toriginal_segments ${text} NOT NULL, parent_epoch ${text}, child_epoch ${text},\n\t\t\tPRIMARY KEY(parent_id, child_id)\n\t\t)${dialect.tableOptions};\n\t`;\n}\n\n/** Creates the fork tables in `tx`: see {@link sharedHistoryTablesScript}. */\nexport async function createSharedHistoryTables(\n\ttx: SqliteExecutor,\n\tdialect: StorageDialect,\n\ttables: SessionForkTables,\n): Promise<void> {\n\tawait tx.exec(sharedHistoryTablesScript(dialect, tables));\n}\n"]}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Where a forked session's inherited entries live, when a fork shares its parent's stored history instead of copying it
|
|
3
|
+
* (#6560). Seqs are 1-based and dense in every session's view. A segment says that the view's seqs `baseSeq + 1` through
|
|
4
|
+
* `baseSeq + (toSeq - fromSeq + 1)` are the rows `fromSeq` through `toSeq`, inclusive, that session `sourceId` stores
|
|
5
|
+
* under its own id. Every seq of a view that no segment covers is a row the session stores itself, under that same seq.
|
|
6
|
+
*
|
|
7
|
+
* Segments are composed when a fork is made, so a source always stores the rows a segment names itself: reading a
|
|
8
|
+
* session never walks a chain of ancestors, whatever the depth of its forks.
|
|
9
|
+
*/
|
|
10
|
+
export interface ForkSegment {
|
|
11
|
+
readonly sourceId: string;
|
|
12
|
+
readonly fromSeq: number;
|
|
13
|
+
readonly toSeq: number;
|
|
14
|
+
readonly baseSeq: number;
|
|
15
|
+
}
|
|
16
|
+
/** A run of a session's view in one place: view seqs `firstSeq` on are `sessionId`'s stored seqs `fromSeq` to `toSeq`. */
|
|
17
|
+
export interface ForkPiece {
|
|
18
|
+
readonly sessionId: string;
|
|
19
|
+
readonly fromSeq: number;
|
|
20
|
+
readonly toSeq: number;
|
|
21
|
+
readonly firstSeq: number;
|
|
22
|
+
}
|
|
23
|
+
export declare function segmentLength(segment: ForkSegment): number;
|
|
24
|
+
/**
|
|
25
|
+
* Throws unless `segments` are well formed for the view of session `sessionId`, of `length` seqs: each non-empty, within
|
|
26
|
+
* the view, of another session, with its source rows from seq 1 on, in view order and disjoint, and each source's rows
|
|
27
|
+
* in increasing order, so no stored row is read at two seqs of the view.
|
|
28
|
+
*/
|
|
29
|
+
export declare function assertForkSegments(sessionId: string, segments: readonly ForkSegment[], length: number): void;
|
|
30
|
+
/** Where view seq `seq` of session `sessionId` is stored. */
|
|
31
|
+
export declare function locateForkSeq(sessionId: string, segments: readonly ForkSegment[], seq: number): {
|
|
32
|
+
readonly sessionId: string;
|
|
33
|
+
readonly seq: number;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* The view seqs `fromSeq` through `toSeq` of session `sessionId` as runs stored in one place each, in view order: what a
|
|
37
|
+
* read of that range reads, one statement a piece.
|
|
38
|
+
*/
|
|
39
|
+
export declare function forkPieces(sessionId: string, segments: readonly ForkSegment[], fromSeq: number, toSeq: number): ForkPiece[];
|
|
40
|
+
/**
|
|
41
|
+
* The segments a fork of session `parentId`, whose view has `parentLength` seqs and inherits `parent`, keeps when it
|
|
42
|
+
* takes the parent's view seqs `fromSeq` through `toSeq` as its own view seqs from `baseSeq + 1` on: the parent's own rows
|
|
43
|
+
* as segments of the parent, and its inherited rows as segments of their sources, so no source of the result inherits
|
|
44
|
+
* the rows it names. Throws when the range is not in the parent's view.
|
|
45
|
+
*/
|
|
46
|
+
export declare function forkRunSegments(parentId: string, parent: readonly ForkSegment[], parentLength: number, run: {
|
|
47
|
+
readonly fromSeq: number;
|
|
48
|
+
readonly toSeq: number;
|
|
49
|
+
readonly baseSeq: number;
|
|
50
|
+
}): ForkSegment[];
|
|
51
|
+
/**
|
|
52
|
+
* `segments` with each segment that continues the one before it in both its source and its view joined to it: the same
|
|
53
|
+
* view in fewer segments.
|
|
54
|
+
*/
|
|
55
|
+
export declare function joinForkSegments(segments: readonly ForkSegment[]): ForkSegment[];
|
|
56
|
+
/** The segments of a fork that keeps the first `cut` seqs of a parent's view, as a prefix of its own view. */
|
|
57
|
+
export declare function prefixForkSegments(parentId: string, parent: readonly ForkSegment[], parentLength: number, cut: number): ForkSegment[];
|
|
58
|
+
//# sourceMappingURL=fork-segments.d.ts.map
|