@bastani/atomic 0.10.13 → 0.10.14
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 +24 -0
- 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 +3 -3
- package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js +3 -3
- package/dist/_shared/mode-shared-2QJSCUM6.js +3 -3
- package/dist/_shared/p1a-prewarm-XIU57JHF.js +3 -3
- package/dist/_shared/runtime-O4KCSG4C.js +1 -1
- package/dist/_shared/sdk-B5LEWGGI.js +3 -3
- package/dist/_shared/session-data-AHTU7IS6.js +2 -2
- package/dist/_shared/session-manager-list-2BLEEZVG.js +1 -1
- package/dist/_shared/{startup-0-0-DZAYBBTI.js → startup-0-0-Q3MWKUK4.js} +83 -4
- package/dist/_shared/startup-0-0-Q3MWKUK4.js.map +1 -0
- package/dist/_shared/startup-0-1-M6OWAYHH.js +3 -3
- package/dist/_shared/startup-0-2-5QHPCEON.js +3 -3
- package/dist/_shared/startup-0-3-4ZYBYQNM.js +3 -3
- package/dist/_shared/startup-0-4-ZMJV547D.js +3 -3
- package/dist/_shared/startup-0-5-YDW47QX6.js +13 -10
- package/dist/_shared/startup-0-5-YDW47QX6.js.map +1 -1
- package/dist/_shared/startup-10-0-TDQNBDDL.js +3 -3
- package/dist/_shared/startup-12-0-55AAXBJZ.js +1 -1
- package/dist/_shared/startup-14-0-MLX36RBG.js +1 -1
- package/dist/_shared/startup-15-0-YUKGAC63.js +1 -1
- package/dist/_shared/startup-15-1-4S7FLMNG.js +3 -3
- package/dist/_shared/startup-8-0-34CBHPZH.js +3 -3
- package/dist/_shared/startup-8-1-LZFXSD3Z.js +61 -48
- package/dist/_shared/startup-8-1-LZFXSD3Z.js.map +1 -1
- package/dist/_shared/storage-command-7MGXLJGZ.js +3 -3
- package/dist/_shared/storage-status-K7PX2RXA.js +2 -2
- package/dist/_shared/task-unsaved-answer-VJ2KTB4V.js +2 -2
- package/dist/_shared/team-DOQKICG2.js +1 -1
- package/dist/_shared/tree-outline-MUEPK5B7.js +2 -2
- package/dist/builtin/intercom/index.bundle.mjs +1 -1
- 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/package.json +1 -1
- package/dist/builtin/subagents/src/extension/index.bundle.mjs +1 -1
- package/dist/builtin/web-access/index.bundle.mjs +1 -1
- package/dist/builtin/web-access/package.json +1 -1
- package/dist/cli/args.js +1 -1
- package/dist/cli/auth-cli.code.js +1 -1
- package/dist/cli/auth-cli.impl.js +3 -3
- package/dist/cli/auth-cli.js +3 -3
- package/dist/cli/blueprint-command.impl.js +3 -3
- package/dist/cli/blueprint-command.js +3 -3
- package/dist/cli/intercom-command.code.js +2 -2
- package/dist/cli/intercom-command.impl.js +3 -3
- package/dist/cli/intercom-command.js +3 -3
- package/dist/cli/list-models.code.js +1 -1
- package/dist/cli/list-models.impl.js +3 -3
- package/dist/cli/list-models.js +3 -3
- package/dist/cli/session-picker.code.js +1 -1
- package/dist/cli/session-picker.impl.js +3 -3
- package/dist/cli/session-picker.js +3 -3
- package/dist/cli/startup-ui.code.js +1 -1
- 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 +1 -1
- 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 +1 -1
- 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/debug.impl.js +3 -3
- package/dist/core/debug.js +3 -3
- 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.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.impl.js +3 -3
- package/dist/core/extensions/loader-host-modules.js +3 -3
- 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/package-manager-storage-adapters.impl.js +3 -3
- package/dist/core/package-manager-storage-adapters.js +3 -3
- package/dist/core/sdk.code.js +1 -1
- package/dist/core/sdk.impl.js +3 -3
- package/dist/core/sdk.js +3 -3
- package/dist/core/session-manager-core.js +3 -3
- 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 +1 -1
- package/dist/core/session-manager.impl.js +3 -3
- package/dist/core/session-manager.js +3 -3
- package/dist/core/session-storage.impl.js +3 -3
- package/dist/core/session-storage.js +3 -3
- package/dist/core/storage/index.js +2 -2
- package/dist/core/storage/node-sqlite-thread.js +2 -2
- package/dist/core/storage/node-sqlite.js +2 -2
- 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/provider.js +2 -2
- package/dist/core/storage/selection.js +2 -2
- package/dist/core/storage/session/branch-fork-source.code.js +2 -2
- 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 +2 -2
- 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.impl.js +3 -3
- package/dist/core/storage/session/chunked-resume-projection.js +3 -3
- package/dist/core/storage/session/expanded-child-details.code.js +2 -2
- 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-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-staging.code.js +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-window.code.js +2 -2
- 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.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 +1 -1
- 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.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/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 +2 -2
- 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-session-store.impl.js +3 -3
- package/dist/core/storage/session/sql-session-store.js +3 -3
- 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.impl.js +3 -3
- package/dist/core/storage/session/tree-presentation.js +3 -3
- package/dist/core/storage/storage-status.impl.js +3 -3
- package/dist/core/storage/storage-status.js +3 -3
- package/dist/core/storage/team.impl.js +3 -3
- package/dist/core/storage/team.js +3 -3
- 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.impl.js +3 -3
- package/dist/core/tasks/task-completion-entry.js +3 -3
- package/dist/core/tasks/task-file-history.code.js +3 -3
- 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 +3 -3
- 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.impl.js +3 -3
- package/dist/core/tasks/task-view-source.js +3 -3
- package/dist/core/tools/bash-pty-native.d.ts +1 -1
- package/dist/core/tools/bash.d.ts +1 -0
- package/dist/core/tools/history-tasks.d.ts +5 -4
- package/dist/core/tools/read-url.code.js +1 -1
- package/dist/core/tools/read-url.impl.js +3 -3
- package/dist/core/tools/read-url.js +3 -3
- package/dist/core/worktree-snapshot/blob-store.d.ts +3 -2
- package/dist/core/worktree-snapshot/blob-store.js +11 -6
- package/dist/core/worktree-snapshot/blob-store.js.map +1 -1
- package/dist/core/worktree-snapshot/errors.code.js +1 -1
- package/dist/core/worktree-snapshot/errors.impl.js +3 -3
- package/dist/core/worktree-snapshot/errors.js +3 -3
- 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 +1 -1
- package/dist/extensions/codemode/execute.impl.js +3 -3
- package/dist/extensions/codemode/execute.js +3 -3
- package/dist/extensions/codemode/renderer.code.js +1 -1
- package/dist/extensions/codemode/renderer.impl.js +3 -3
- package/dist/extensions/codemode/renderer.js +3 -3
- package/dist/extensions/mcp/cli.code.js +1 -1
- 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.impl.js +3 -3
- package/dist/extensions/mcp/runtime.js +3 -3
- package/dist/index.js +1 -1
- package/dist/main-first-time-setup.code.js +1 -1
- package/dist/main-first-time-setup.impl.js +3 -3
- package/dist/main-first-time-setup.js +3 -3
- package/dist/modes/interactive/components/stored-tree-view.code.js +2 -2
- 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/user-message-selector-archive.impl.js +3 -3
- package/dist/modes/interactive/components/user-message-selector-archive.js +3 -3
- package/dist/package-manager-cli.code.js +3 -3
- package/dist/package-manager-cli.impl.js +3 -3
- package/dist/package-manager-cli.js +3 -3
- package/dist/startup-files.json +1 -1
- package/dist/startup-stages/3.js +1 -1
- package/dist/utils/startup-database-spare.code.js +1 -1
- package/dist/utils/startup-database-spare.impl.js +3 -3
- package/dist/utils/startup-database-spare.js +3 -3
- package/dist/utils/tools-manager.impl.js +3 -3
- package/dist/utils/tools-manager.js +3 -3
- package/docs/background-tasks.md +28 -15
- package/docs/changelog.mdx +10 -1
- package/docs/sessions.md +73 -25
- package/docs/tools.md +46 -4
- package/package.json +8 -8
- package/dist/_shared/startup-0-0-DZAYBBTI.js.map +0 -1
|
@@ -8,7 +8,7 @@ import { require_turndown_cjs } from "../../_shared/turndown.cjs-7Z43JOED.js";
|
|
|
8
8
|
import { require_undici } from "../../_shared/http-undici-FVPTZA4G.js";
|
|
9
9
|
import { findAsciiCaseInsensitive, isAsciiWordCode } from "../../_shared/p1b-elig-TVB5CBLL.js";
|
|
10
10
|
import { applyReadLineSelection, decodeReadableUrl, extractDocumentMarkdown, getArtifactManager, isDocumentPath } from "../../_shared/startup-8-1-LZFXSD3Z.js";
|
|
11
|
-
import { isReadableUrlPath, repairCollapsedScheme } from "../../_shared/startup-0-0-
|
|
11
|
+
import { isReadableUrlPath, repairCollapsedScheme } from "../../_shared/startup-0-0-Q3MWKUK4.js";
|
|
12
12
|
import { isIP } from "node:net";
|
|
13
13
|
// ../../node_modules/lru-cache/dist/esm/node/index.min.js
|
|
14
14
|
var S = channel("lru-cache:metrics");
|
|
@@ -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.14`;
|
|
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.14") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.14 while this session was running; restart it to keep using this feature.", {
|
|
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.14`;
|
|
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.14") throw error;
|
|
31
|
+
throw new Error((typeof running.name === "string" ? running.name : "atomic") + " was updated to 0.10.14 while this session was running; restart it to keep using this feature.", {
|
|
32
32
|
cause: error,
|
|
33
33
|
});
|
|
34
34
|
}
|
|
@@ -554,8 +554,9 @@ export declare class SqlSnapshotBlobStore implements SnapshotBlobStore {
|
|
|
554
554
|
private betweenBatches;
|
|
555
555
|
/**
|
|
556
556
|
* Runs `body` in a write transaction. With `pace`, the transaction never waits for a write lock another connection
|
|
557
|
-
* holds: it is refused at once
|
|
558
|
-
*
|
|
557
|
+
* holds: it is refused at once (SQLite `StorageWriteLockTimeoutError` or PostgreSQL not-applied `lock-conflict`) and
|
|
558
|
+
* tried again after a wait on `pace` that doubles each time, so the process can exit meanwhile; once the waits add
|
|
559
|
+
* up to {@link SNAPSHOT_COLLECTION_LEASE_SECONDS}, it rejects with the refusal.
|
|
559
560
|
*/
|
|
560
561
|
private write;
|
|
561
562
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { storageSchemaCurrent, transactionFinisher } from "../storage/added-exports.js";
|
|
2
2
|
import { MAX_SEQUENCE_REQUEST_STATEMENTS, noteStorageSchemaTables } from "../storage/added-exports-0-10-11.js";
|
|
3
3
|
import { dialectOf } from "../storage/dialect.js";
|
|
4
|
-
import { StorageWriteLockTimeoutError } from "../storage/errors.js";
|
|
4
|
+
import { StorageTransientError, StorageWriteLockTimeoutError } from "../storage/errors.js";
|
|
5
5
|
import { applyStorageMigrations, ensureStorageSchema, withShortSchemaLockWaits } from "../storage/migrations.js";
|
|
6
6
|
import { renderStorageIdentifiers, storageMigrationTable, validateStoragePrefix } from "../storage/prefix.js";
|
|
7
7
|
import { schemaCatalogOf, withStorageSchemaCatalog } from "../storage/schema-catalog.js";
|
|
@@ -2655,8 +2655,9 @@ export class SqlSnapshotBlobStore {
|
|
|
2655
2655
|
}
|
|
2656
2656
|
/**
|
|
2657
2657
|
* Runs `body` in a write transaction. With `pace`, the transaction never waits for a write lock another connection
|
|
2658
|
-
* holds: it is refused at once
|
|
2659
|
-
*
|
|
2658
|
+
* holds: it is refused at once (SQLite `StorageWriteLockTimeoutError` or PostgreSQL not-applied `lock-conflict`) and
|
|
2659
|
+
* tried again after a wait on `pace` that doubles each time, so the process can exit meanwhile; once the waits add
|
|
2660
|
+
* up to {@link SNAPSHOT_COLLECTION_LEASE_SECONDS}, it rejects with the refusal.
|
|
2660
2661
|
*/
|
|
2661
2662
|
async write(pace, body) {
|
|
2662
2663
|
if (pace === undefined)
|
|
@@ -2667,7 +2668,11 @@ export class SqlSnapshotBlobStore {
|
|
|
2667
2668
|
return await this.database.transaction(body, { lockWaitMs: 0 });
|
|
2668
2669
|
}
|
|
2669
2670
|
catch (error) {
|
|
2670
|
-
|
|
2671
|
+
const lockRefused = error instanceof StorageWriteLockTimeoutError ||
|
|
2672
|
+
(error instanceof StorageTransientError &&
|
|
2673
|
+
error.code === "lock-conflict" &&
|
|
2674
|
+
error.outcome === "not-applied");
|
|
2675
|
+
if (!lockRefused || waited >= SNAPSHOT_COLLECTION_LEASE_SECONDS * 1_000)
|
|
2671
2676
|
throw error;
|
|
2672
2677
|
}
|
|
2673
2678
|
await pace.wait(delay);
|
|
@@ -2684,7 +2689,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
2684
2689
|
return (async () => {
|
|
2685
2690
|
const root = new URL("../../", import.meta.url);
|
|
2686
2691
|
const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
|
|
2687
|
-
const key = `${root.href}#0.10.
|
|
2692
|
+
const key = `${root.href}#0.10.14`;
|
|
2688
2693
|
let release = releases.get(key);
|
|
2689
2694
|
if (release === undefined) {
|
|
2690
2695
|
const current = (async () => {
|
|
@@ -2712,7 +2717,7 @@ function __atomicOnDemandFailed(error, feature) {
|
|
|
2712
2717
|
} catch {
|
|
2713
2718
|
// No installation to read, as in a bundle of the package: the release the process runs decides.
|
|
2714
2719
|
}
|
|
2715
|
-
const updatedTo = typeof installed === "string" && installed !== "0.10.
|
|
2720
|
+
const updatedTo = typeof installed === "string" && installed !== "0.10.14" ? installed : running !== undefined && running.version !== "0.10.14" ? "0.10.14" : undefined;
|
|
2716
2721
|
if (updatedTo === undefined) throw error;
|
|
2717
2722
|
const application = typeof running?.name === "string" ? running.name : "atomic";
|
|
2718
2723
|
const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {
|