crosscheck-mcp 0.2.26 → 0.2.28
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/README.md +4 -20
- package/dist/browser-ext.cjs +372 -381
- package/dist/browser-ext.cjs.map +1 -1
- package/dist/browser-ext.js +357 -366
- package/dist/browser-ext.js.map +1 -1
- package/dist/embed.cjs +374 -387
- package/dist/embed.cjs.map +1 -1
- package/dist/embed.d.cts +58 -1
- package/dist/embed.d.ts +58 -1
- package/dist/embed.js +352 -368
- package/dist/embed.js.map +1 -1
- package/dist/node-stdio.cjs +398 -483
- package/dist/node-stdio.cjs.map +1 -1
- package/dist/node-stdio.d.cts +11 -47
- package/dist/node-stdio.d.ts +11 -47
- package/dist/node-stdio.js +369 -454
- package/dist/node-stdio.js.map +1 -1
- package/dist/pricing.json +90 -22
- package/dist/self-check.cjs.map +1 -1
- package/dist/self-check.js.map +1 -1
- package/package.json +7 -2
package/dist/embed.d.cts
CHANGED
|
@@ -1,3 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A record of which engine processes are alive, and what they are RUNNING.
|
|
3
|
+
*
|
|
4
|
+
* WHY
|
|
5
|
+
* An engine process started weeks earlier was found still serving a pre-fix
|
|
6
|
+
* build while reporting the version on disk — so `crosscheck doctor` said
|
|
7
|
+
* "up to date" and the user kept hitting a bug that had already been fixed.
|
|
8
|
+
* Thirty-six such processes were once killed across twelve trees. Nothing
|
|
9
|
+
* reaps them and nothing notices them.
|
|
10
|
+
*
|
|
11
|
+
* The version a process REPORTS must be the one it LOADED, not the one
|
|
12
|
+
* currently installed. That is the whole point of writing it down at boot: a
|
|
13
|
+
* long-lived process cannot tell you what it is running if it re-reads the
|
|
14
|
+
* answer from disk every time you ask.
|
|
15
|
+
*
|
|
16
|
+
* WHY IT ONLY REPORTS
|
|
17
|
+
* It would be easy to kill anything older than N hours on startup. That is
|
|
18
|
+
* exactly what not to do here:
|
|
19
|
+
* - the CLI and the desktop app share this directory, so "ours" is not a
|
|
20
|
+
* safe inference from a name or a path;
|
|
21
|
+
* - a long-running process may be mid-panel, and panels cost real money;
|
|
22
|
+
* - a pid is reused after a process dies, so killing by a recorded pid can
|
|
23
|
+
* kill something unrelated that happens to have inherited the number.
|
|
24
|
+
* So this module writes, reads, and prunes records of processes that are
|
|
25
|
+
* already gone. Deciding to kill a live one is the operator's, with the
|
|
26
|
+
* command printed for them.
|
|
27
|
+
*/
|
|
28
|
+
interface ProcRecord {
|
|
29
|
+
pid: number;
|
|
30
|
+
/** The engine version this process LOADED — not what is on disk now. */
|
|
31
|
+
version: string;
|
|
32
|
+
/** Epoch ms at boot. */
|
|
33
|
+
startedAt: number;
|
|
34
|
+
/** Parent pid at boot: the host that spawned us (Claude Code, a shell). */
|
|
35
|
+
ppid: number;
|
|
36
|
+
/** This process's session id, so a stale process can be tied to its rows. */
|
|
37
|
+
sessionId: string;
|
|
38
|
+
}
|
|
39
|
+
interface ProcStatus extends ProcRecord {
|
|
40
|
+
alive: boolean;
|
|
41
|
+
/** True when alive and running a version other than the one installed. */
|
|
42
|
+
outdated: boolean;
|
|
43
|
+
ageMs: number;
|
|
44
|
+
}
|
|
45
|
+
/** Is a pid still running? `kill(pid, 0)` signals nothing and throws ESRCH
|
|
46
|
+
* when the process is gone — EPERM means alive but owned by someone else,
|
|
47
|
+
* which still counts as alive. */
|
|
48
|
+
declare function isAlive(pid: number): boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Every recorded process, with liveness. Records for dead pids are PRUNED as
|
|
51
|
+
* a side effect — they are the safe half of cleanup: the process is already
|
|
52
|
+
* gone, so deleting its note cannot hurt anything.
|
|
53
|
+
*/
|
|
54
|
+
declare function listProcesses(installedVersion: string, env?: NodeJS.ProcessEnv, now?: number): ProcStatus[];
|
|
55
|
+
/** Directory path, for messages that tell an operator where to look. */
|
|
56
|
+
declare function processRegistryPath(env?: NodeJS.ProcessEnv): string;
|
|
57
|
+
|
|
1
58
|
/** Default model per provider — matches Python's `build_providers()`. */
|
|
2
59
|
declare const DEFAULT_MODELS: Readonly<Record<string, string>>;
|
|
3
60
|
/**
|
|
@@ -202,4 +259,4 @@ declare const __test_internals: {
|
|
|
202
259
|
vaultId: typeof vaultId;
|
|
203
260
|
};
|
|
204
261
|
|
|
205
|
-
export { DEFAULT_EXCLUDED_PROVIDERS, DEFAULT_FALLBACKS, DEFAULT_MODELS, type EmbeddedEngine, type EmbeddedEngineOptions, type EngineEvent, type EngineEventSink, type EventUsage, KEY_ENV as __KEY_ENV, MODEL_ENV as __MODEL_ENV, __test_internals, createEmbeddedEngine };
|
|
262
|
+
export { DEFAULT_EXCLUDED_PROVIDERS, DEFAULT_FALLBACKS, DEFAULT_MODELS, type EmbeddedEngine, type EmbeddedEngineOptions, type EngineEvent, type EngineEventSink, type EventUsage, type ProcRecord, type ProcStatus, KEY_ENV as __KEY_ENV, MODEL_ENV as __MODEL_ENV, __test_internals, createEmbeddedEngine, isAlive, listProcesses, processRegistryPath };
|
package/dist/embed.d.ts
CHANGED
|
@@ -1,3 +1,60 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A record of which engine processes are alive, and what they are RUNNING.
|
|
3
|
+
*
|
|
4
|
+
* WHY
|
|
5
|
+
* An engine process started weeks earlier was found still serving a pre-fix
|
|
6
|
+
* build while reporting the version on disk — so `crosscheck doctor` said
|
|
7
|
+
* "up to date" and the user kept hitting a bug that had already been fixed.
|
|
8
|
+
* Thirty-six such processes were once killed across twelve trees. Nothing
|
|
9
|
+
* reaps them and nothing notices them.
|
|
10
|
+
*
|
|
11
|
+
* The version a process REPORTS must be the one it LOADED, not the one
|
|
12
|
+
* currently installed. That is the whole point of writing it down at boot: a
|
|
13
|
+
* long-lived process cannot tell you what it is running if it re-reads the
|
|
14
|
+
* answer from disk every time you ask.
|
|
15
|
+
*
|
|
16
|
+
* WHY IT ONLY REPORTS
|
|
17
|
+
* It would be easy to kill anything older than N hours on startup. That is
|
|
18
|
+
* exactly what not to do here:
|
|
19
|
+
* - the CLI and the desktop app share this directory, so "ours" is not a
|
|
20
|
+
* safe inference from a name or a path;
|
|
21
|
+
* - a long-running process may be mid-panel, and panels cost real money;
|
|
22
|
+
* - a pid is reused after a process dies, so killing by a recorded pid can
|
|
23
|
+
* kill something unrelated that happens to have inherited the number.
|
|
24
|
+
* So this module writes, reads, and prunes records of processes that are
|
|
25
|
+
* already gone. Deciding to kill a live one is the operator's, with the
|
|
26
|
+
* command printed for them.
|
|
27
|
+
*/
|
|
28
|
+
interface ProcRecord {
|
|
29
|
+
pid: number;
|
|
30
|
+
/** The engine version this process LOADED — not what is on disk now. */
|
|
31
|
+
version: string;
|
|
32
|
+
/** Epoch ms at boot. */
|
|
33
|
+
startedAt: number;
|
|
34
|
+
/** Parent pid at boot: the host that spawned us (Claude Code, a shell). */
|
|
35
|
+
ppid: number;
|
|
36
|
+
/** This process's session id, so a stale process can be tied to its rows. */
|
|
37
|
+
sessionId: string;
|
|
38
|
+
}
|
|
39
|
+
interface ProcStatus extends ProcRecord {
|
|
40
|
+
alive: boolean;
|
|
41
|
+
/** True when alive and running a version other than the one installed. */
|
|
42
|
+
outdated: boolean;
|
|
43
|
+
ageMs: number;
|
|
44
|
+
}
|
|
45
|
+
/** Is a pid still running? `kill(pid, 0)` signals nothing and throws ESRCH
|
|
46
|
+
* when the process is gone — EPERM means alive but owned by someone else,
|
|
47
|
+
* which still counts as alive. */
|
|
48
|
+
declare function isAlive(pid: number): boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Every recorded process, with liveness. Records for dead pids are PRUNED as
|
|
51
|
+
* a side effect — they are the safe half of cleanup: the process is already
|
|
52
|
+
* gone, so deleting its note cannot hurt anything.
|
|
53
|
+
*/
|
|
54
|
+
declare function listProcesses(installedVersion: string, env?: NodeJS.ProcessEnv, now?: number): ProcStatus[];
|
|
55
|
+
/** Directory path, for messages that tell an operator where to look. */
|
|
56
|
+
declare function processRegistryPath(env?: NodeJS.ProcessEnv): string;
|
|
57
|
+
|
|
1
58
|
/** Default model per provider — matches Python's `build_providers()`. */
|
|
2
59
|
declare const DEFAULT_MODELS: Readonly<Record<string, string>>;
|
|
3
60
|
/**
|
|
@@ -202,4 +259,4 @@ declare const __test_internals: {
|
|
|
202
259
|
vaultId: typeof vaultId;
|
|
203
260
|
};
|
|
204
261
|
|
|
205
|
-
export { DEFAULT_EXCLUDED_PROVIDERS, DEFAULT_FALLBACKS, DEFAULT_MODELS, type EmbeddedEngine, type EmbeddedEngineOptions, type EngineEvent, type EngineEventSink, type EventUsage, KEY_ENV as __KEY_ENV, MODEL_ENV as __MODEL_ENV, __test_internals, createEmbeddedEngine };
|
|
262
|
+
export { DEFAULT_EXCLUDED_PROVIDERS, DEFAULT_FALLBACKS, DEFAULT_MODELS, type EmbeddedEngine, type EmbeddedEngineOptions, type EngineEvent, type EngineEventSink, type EventUsage, type ProcRecord, type ProcStatus, KEY_ENV as __KEY_ENV, MODEL_ENV as __MODEL_ENV, __test_internals, createEmbeddedEngine, isAlive, listProcesses, processRegistryPath };
|