@intentic/extension-api 1.307.0 → 1.308.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/README.md +26 -12
- package/dist/api.d.ts +1 -0
- package/dist/api.d.ts.map +1 -1
- package/dist/scope.d.ts +2 -1
- package/dist/scope.d.ts.map +1 -1
- package/dist/scope.js +5 -13
- package/dist/scope.js.map +1 -1
- package/dist/server.d.ts +3 -0
- package/dist/server.d.ts.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.d.ts.map +1 -1
- package/dist/version.js +1 -1
- package/dist/version.js.map +1 -1
- package/package.json +2 -2
- package/src/api.ts +6 -2
- package/src/scope.ts +17 -18
- package/src/server.ts +7 -0
- package/src/surface.json +323 -0
- package/src/version.ts +12 -1
package/README.md
CHANGED
|
@@ -7,8 +7,8 @@ One of the packages an extension may depend on, with `@intentic/extension-manife
|
|
|
7
7
|
internals. See the extension system in [ARCHITECTURE.md](../../ARCHITECTURE.md) for how the host loads and
|
|
8
8
|
gates extensions.
|
|
9
9
|
|
|
10
|
-
It **does** name `@intentic/sandbox-contract` types, and that is deliberate: `api.sandbox.rpc`
|
|
11
|
-
own contract as a typed client, which is the whole reason an extension no longer has to build a URL to reach
|
|
10
|
+
It **does** name `@intentic/sandbox-contract` types, and that is deliberate: `api.sandbox.rpc` (and the backend's
|
|
11
|
+
`api.daemon.rpc`) is the daemon's own contract as a typed client, which is the whole reason an extension no longer has to build a URL to reach
|
|
12
12
|
it. The dependency is type-only, so nothing of the contract lands in an extension's runtime. This used to be
|
|
13
13
|
forbidden: the contract imported the manifest schema from here, so depending back would have closed a cycle.
|
|
14
14
|
`@intentic/extension-manifest` exists to break exactly that, and its README has the reasoning.
|
|
@@ -43,7 +43,7 @@ forbidden: the contract imported the manifest schema from here, so depending bac
|
|
|
43
43
|
- **[server.ts](src/server.ts)**: `ExtensionServerApi`, the BACKEND half's surface. A manifest `server`
|
|
44
44
|
bundle exports `activateServer(api, context)` and runs in the daemon's backend host (one separate
|
|
45
45
|
supervised process shared by every enabled backend); `api.routes.mount` serves the extension's own
|
|
46
|
-
`/x/<id>/…` namespace, `api.daemon.
|
|
46
|
+
`/x/<id>/…` namespace, `api.daemon.rpc` reaches the daemon's routes under the manifest's
|
|
47
47
|
`permissions.daemon` allowlist, and workspace files are plain `node:fs` under `api.workspaceRoot`: full
|
|
48
48
|
trust, so paths rather than a file service. The extension's own namespace needs no `permissions.sandbox`
|
|
49
49
|
entry on the UI side: its backend is its own.
|
|
@@ -56,9 +56,9 @@ packages, which is exactly the case a per-repo `detect()` cannot express. An off
|
|
|
56
56
|
directory rather than an affordance every directory of its kind has says so (`evidence: true`), and the tree
|
|
57
57
|
keeps its icon on the row instead of revealing it on hover: the difference between a reader seeing which
|
|
58
58
|
packages have a page and a reader having to go looking for one.
|
|
59
|
-
- **[scope.ts](src/scope.ts)**, `sandboxRef`
|
|
60
|
-
belongs to ONE sandbox. See "Where state lives" below;
|
|
61
|
-
getting it wrong looks fine until somebody switches sandbox.
|
|
59
|
+
- **[scope.ts](src/scope.ts)**, `sandboxRef` (with `sandboxShallowRef` and `sandboxValue`) and
|
|
60
|
+
`sandboxScopeGuard`: how an extension keeps state that belongs to ONE sandbox. See "Where state lives" below;
|
|
61
|
+
this is the rule most easily got wrong, because getting it wrong looks fine until somebody switches sandbox.
|
|
62
62
|
- **[background.ts](src/background.ts)**, `sandboxPoll` and `sandboxLedger`: the work an extension does while
|
|
63
63
|
none of it is on screen. A tile that badges has to be filled by something, and what has already been seen has
|
|
64
64
|
to be written down somewhere; both were hand-written in six extensions before they were here.
|
|
@@ -72,11 +72,24 @@ no backend.
|
|
|
72
72
|
|
|
73
73
|
## The data plane
|
|
74
74
|
|
|
75
|
-
An extension talks to the daemon
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
75
|
+
An extension talks to the daemon through `api.sandbox.rpc`, the daemon's own contract as a typed client: a call
|
|
76
|
+
names a procedure (`api.sandbox.rpc.ci.runs()`), its input is checked at build time, and its answer arrives parsed
|
|
77
|
+
by the procedure's output schema, so there is no path to spell and no parse to write. Auth is injected host-side;
|
|
78
|
+
the bundle never sees a token. **Its reach is not unrestricted:** the host resolves each call to the method and
|
|
79
|
+
path it will send and matches that against the manifest's `permissions.sandbox` allowlist, the same gate
|
|
80
|
+
`request`/`json` pass through, and an undeclared route throws before anything is sent.
|
|
81
|
+
|
|
82
|
+
`request(path)` stays for what the contract does not carry: bytes (`/workspace/raw`), uploads, an extension's own
|
|
83
|
+
`/x/<id>/` backend. `json(path)` stays in the published surface for extensions built against it; every extension
|
|
84
|
+
in this repository calls a contract route through `rpc` (the `contract-paths` check holds them to it).
|
|
85
|
+
|
|
86
|
+
A backend reaches the daemon the same way, through `api.daemon.rpc`: the same typed client, built by the daemon's
|
|
87
|
+
backend host and handed to `activateServer`, so a server bundle carries no client of its own. It presents the
|
|
88
|
+
extension's minted grant, and the host refuses a call before sending it unless the manifest's `permissions.daemon`
|
|
89
|
+
covers the method and path it resolves to: the verdict the daemon's grant reaches for the same call through
|
|
90
|
+
`api.daemon.request`, which stays for bytes (`/workspace/raw`), as `json` does for backends built against it.
|
|
91
|
+
|
|
92
|
+
The in-repo, compiled-together design means a wire change is a compiler error fixed atomically, so there is no
|
|
80
93
|
separate "stable data API" to promote. `facts.ts` stays the stable surface only for *detection*.
|
|
81
94
|
|
|
82
95
|
## Where state lives
|
|
@@ -94,7 +107,8 @@ Everything an extension holds is about one workspace, so a switch has to leave n
|
|
|
94
107
|
the view being unmounted, because a badge you only see after opening the view is pointless. Declare it with
|
|
95
108
|
`sandboxRef(() => initial)` and the host empties it on every switch. There is no subscription to remember
|
|
96
109
|
and no teardown to write; `dispose` is there for state that owns an object URL or anything else the garbage
|
|
97
|
-
collector will not take back.
|
|
110
|
+
collector will not take back. A value replaced whole rather than edited in place (a map, an object with its
|
|
111
|
+
own methods) goes in `sandboxShallowRef` instead, the same lifetime without the deep proxy.
|
|
98
112
|
|
|
99
113
|
For anything asynchronous in that third tier, take a `sandboxScopeGuard()` **before** the await and ask it
|
|
100
114
|
**after**: a poll issued against the last sandbox otherwise resolves a moment later and writes its answer
|
package/dist/api.d.ts
CHANGED
|
@@ -115,6 +115,7 @@ export interface IntenticApi {
|
|
|
115
115
|
onDidChangeProject(listener: (project: string | undefined) => void): Disposable;
|
|
116
116
|
inProject(path: string): boolean;
|
|
117
117
|
onDidChangeRefs(listener: (repos: readonly string[]) => void): Disposable;
|
|
118
|
+
onDidChangeRepos(listener: (repos: readonly string[]) => void): Disposable;
|
|
118
119
|
onDidChangeFiles(listener: (paths: readonly string[]) => void): Disposable;
|
|
119
120
|
openDiff(payload: DiffPayload): void;
|
|
120
121
|
fillDiff(payload: DiffPayload): void;
|
package/dist/api.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,KAAK,CAAC;AACrC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAC7C,OAAO,KAAK,EAAE,eAAe,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAK7D,MAAM,WAAW,UAAU;IACvB,OAAO,IAAI,IAAI,CAAC;CACnB;AAID,MAAM,WAAW,UAAU;IAEvB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IAEvB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAGnC,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAEvC,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,SA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sandboxRef: <T>(initial: () => T, dispose?: (previous: T) => void) => Ref<T>;
|
|
3
|
+
export declare const sandboxShallowRef: <T>(initial: () => T, dispose?: (previous: T) => void) => ShallowRef<T>;
|
|
3
4
|
export interface SandboxValue<T> {
|
|
4
5
|
value: T;
|
|
5
6
|
}
|
package/dist/scope.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scope.d.ts","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,GAAG,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"scope.d.ts","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,GAAG,EAAc,KAAK,UAAU,EAAE,MAAM,KAAK,CAAC;AA2BjE,eAAO,MAAM,UAAU,GAAI,CAAC,WAAW,MAAM,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC,KAAK,IAAI,KAAG,GAAG,CAAC,CAAC,CAAuD,CAAC;AAI/I,eAAO,MAAM,iBAAiB,GAAI,CAAC,WAAW,MAAM,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC,KAAK,IAAI,KAAG,UAAU,CAAC,CAAC,CAClD,CAAC;AAIpD,MAAM,WAAW,YAAY,CAAC,CAAC;IAC3B,KAAK,EAAE,CAAC,CAAC;CACZ;AAID,eAAO,MAAM,YAAY,GAAI,CAAC,WAAW,MAAM,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC,KAAK,IAAI,KAAG,YAAY,CAAC,CAAC,CAC5B,CAAC;AAIvE,eAAO,MAAM,iBAAiB,QAAO,CAAC,MAAM,OAAO,CAGlD,CAAC;AAGF,eAAO,MAAM,iBAAiB,QAAO,IAKpC,CAAC"}
|
package/dist/scope.js
CHANGED
|
@@ -1,18 +1,7 @@
|
|
|
1
|
-
import { ref } from "vue";
|
|
1
|
+
import { ref, shallowRef } from "vue";
|
|
2
2
|
const registered = [];
|
|
3
3
|
let generation = 0;
|
|
4
|
-
|
|
5
|
-
const state = ref(initial());
|
|
6
|
-
registered.push({
|
|
7
|
-
clear: () => {
|
|
8
|
-
dispose?.(state.value);
|
|
9
|
-
state.value = initial();
|
|
10
|
-
},
|
|
11
|
-
});
|
|
12
|
-
return state;
|
|
13
|
-
};
|
|
14
|
-
export const sandboxValue = (initial, dispose) => {
|
|
15
|
-
const box = { value: initial() };
|
|
4
|
+
const scoped = (box, initial, dispose) => {
|
|
16
5
|
registered.push({
|
|
17
6
|
clear: () => {
|
|
18
7
|
dispose?.(box.value);
|
|
@@ -21,6 +10,9 @@ export const sandboxValue = (initial, dispose) => {
|
|
|
21
10
|
});
|
|
22
11
|
return box;
|
|
23
12
|
};
|
|
13
|
+
export const sandboxRef = (initial, dispose) => scoped(ref(initial()), initial, dispose);
|
|
14
|
+
export const sandboxShallowRef = (initial, dispose) => scoped(shallowRef(initial()), initial, dispose);
|
|
15
|
+
export const sandboxValue = (initial, dispose) => scoped({ value: initial() }, initial, dispose);
|
|
24
16
|
export const sandboxScopeGuard = () => {
|
|
25
17
|
const taken = generation;
|
|
26
18
|
return () => taken === generation;
|
package/dist/scope.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scope.js","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAY,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"scope.js","sourceRoot":"","sources":["../src/scope.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAY,UAAU,EAAmB,MAAM,KAAK,CAAC;AASjE,MAAM,UAAU,GAAiB,EAAE,CAAC;AAGpC,IAAI,UAAU,GAAG,CAAC,CAAC;AAGnB,MAAM,MAAM,GAAG,CAA4B,GAAM,EAAE,OAAgB,EAAE,OAA+B,EAAK,EAAE;IACvG,UAAU,CAAC,IAAI,CAAC;QACZ,KAAK,EAAE,GAAG,EAAE;YACR,OAAO,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;YACrB,GAAG,CAAC,KAAK,GAAG,OAAO,EAAE,CAAC;QAC1B,CAAC;KACJ,CAAC,CAAC;IACH,OAAO,GAAG,CAAC;AACf,CAAC,CAAC;AAIF,MAAM,CAAC,MAAM,UAAU,GAAG,CAAI,OAAgB,EAAE,OAA+B,EAAU,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,OAAO,EAAE,CAAW,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;AAI/I,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAI,OAAgB,EAAE,OAA+B,EAAiB,EAAE,CACrG,MAAM,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;AAUpD,MAAM,CAAC,MAAM,YAAY,GAAG,CAAI,OAAgB,EAAE,OAA+B,EAAmB,EAAE,CAClG,MAAM,CAAqB,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;AAIvE,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAoB,EAAE;IACnD,MAAM,KAAK,GAAG,UAAU,CAAC;IACzB,OAAO,GAAG,EAAE,CAAC,KAAK,KAAK,UAAU,CAAC;AACtC,CAAC,CAAC;AAGF,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAS,EAAE;IACxC,UAAU,IAAI,CAAC,CAAC;IAChB,KAAK,MAAM,KAAK,IAAI,UAAU,EAAE,CAAC;QAC7B,KAAK,CAAC,KAAK,EAAE,CAAC;IAClB,CAAC;AACL,CAAC,CAAC"}
|
package/dist/server.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import type { sandboxContract } from "@intentic/sandbox-contract";
|
|
2
|
+
import type { ContractRouterClient } from "@orpc/contract";
|
|
1
3
|
export type BackendRouteHandler = (request: Request) => Promise<Response | undefined>;
|
|
2
4
|
export interface ExtensionServerApi {
|
|
3
5
|
readonly apiVersion: string;
|
|
@@ -8,6 +10,7 @@ export interface ExtensionServerApi {
|
|
|
8
10
|
mount(handler: BackendRouteHandler): void;
|
|
9
11
|
};
|
|
10
12
|
readonly daemon: {
|
|
13
|
+
readonly rpc: ContractRouterClient<typeof sandboxContract>;
|
|
11
14
|
request(path: string, init?: RequestInit): Promise<Response>;
|
|
12
15
|
json<T>(path: string, init?: RequestInit): Promise<T>;
|
|
13
16
|
};
|
package/dist/server.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAQ3D,MAAM,MAAM,mBAAmB,GAAG,CAAC,OAAO,EAAE,OAAO,KAAK,OAAO,CAAC,QAAQ,GAAG,SAAS,CAAC,CAAC;AAEtF,MAAM,WAAW,kBAAkB;IAE/B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAE5B,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAE/B,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAE9B,QAAQ,CAAC,GAAG,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,QAAQ,CAAC,MAAM,EAAE;QAGb,KAAK,CAAC,OAAO,EAAE,mBAAmB,GAAG,IAAI,CAAC;KAC7C,CAAC;IAGF,QAAQ,CAAC,MAAM,EAAE;QAGb,QAAQ,CAAC,GAAG,EAAE,oBAAoB,CAAC,OAAO,eAAe,CAAC,CAAC;QAE3D,OAAO,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;QAC7D,IAAI,CAAC,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC;KACzD,CAAC;CACL;AAED,MAAM,WAAW,sBAAsB;IAEnC,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;CAChC;AAID,MAAM,WAAW,qBAAqB;IAClC,cAAc,CAAC,GAAG,EAAE,kBAAkB,EAAE,OAAO,EAAE,sBAAsB,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAClG"}
|
package/dist/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const extensionApiVersion = "2.
|
|
1
|
+
export declare const extensionApiVersion = "2.18.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/dist/version.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AA+GA,eAAO,MAAM,mBAAmB,WAAW,CAAC"}
|
package/dist/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const extensionApiVersion = "2.
|
|
1
|
+
export const extensionApiVersion = "2.18.0";
|
|
2
2
|
//# sourceMappingURL=version.js.map
|
package/dist/version.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"version.js","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"version.js","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AA+GA,MAAM,CAAC,MAAM,mBAAmB,GAAG,QAAQ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@intentic/extension-api",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.308.2",
|
|
4
4
|
"description": "The versioned public API intentic extensions compile against, manifest schema, detection facts and the host API",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
}
|
|
43
43
|
},
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@intentic/sandbox-contract": "1.
|
|
45
|
+
"@intentic/sandbox-contract": "1.308.2",
|
|
46
46
|
"@orpc/contract": "1.14.13",
|
|
47
47
|
"tslib": "2.8.1"
|
|
48
48
|
},
|
package/src/api.ts
CHANGED
|
@@ -184,9 +184,10 @@ export interface IntenticApi {
|
|
|
184
184
|
// The authenticated transport to the sandbox daemon; auth is injected host-side. Every door is gated
|
|
185
185
|
// by the manifest's `permissions.sandbox` allowlist.
|
|
186
186
|
readonly sandbox: {
|
|
187
|
-
// The daemon's contract, typed: a call names a procedure
|
|
188
|
-
//
|
|
187
|
+
// The daemon's contract, typed: a call names a procedure, checked at build time, and its answer arrives parsed
|
|
188
|
+
// by the procedure's output schema. Gated like `request`/`json`, on the method and path the call resolves to.
|
|
189
189
|
readonly rpc: ContractRouterClient<typeof sandboxContract>;
|
|
190
|
+
// For what the contract does not carry: bytes, uploads, and an extension's own `/x/<id>/` backend.
|
|
190
191
|
request(path: string, init?: RequestInit): Promise<Response>;
|
|
191
192
|
json<T>(path: string, init?: RequestInit): Promise<T>;
|
|
192
193
|
// Reads through the host's cache from outside a component (e.g. a module-level badge timer);
|
|
@@ -225,6 +226,9 @@ export interface IntenticApi {
|
|
|
225
226
|
// Fires when a ref moves in a repo (commit, branch, checkout, rebase) — a change `.git` watching can't
|
|
226
227
|
// see as a file path. `repos` are root-relative ids.
|
|
227
228
|
onDidChangeRefs(listener: (repos: readonly string[]) => void): Disposable;
|
|
229
|
+
// Fires when a repository appears or goes (a clone, a scaffold, a delete); `repos` is every root-relative id, not
|
|
230
|
+
// narrowed to the open project.
|
|
231
|
+
onDidChangeRepos(listener: (repos: readonly string[]) => void): Disposable;
|
|
228
232
|
// Fires for a write under your declared `contributes.files` prefixes; `paths` are the matching ones.
|
|
229
233
|
// Fires with your whole declaration when the host can't say what moved.
|
|
230
234
|
onDidChangeFiles(listener: (paths: readonly string[]) => void): Disposable;
|
package/src/scope.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref, type Ref } from "vue";
|
|
1
|
+
import { ref, type Ref, shallowRef, type ShallowRef } from "vue";
|
|
2
2
|
|
|
3
3
|
// Module state scoped to one sandbox (badge counts, poll results) that must survive a component unmount. Declare it
|
|
4
4
|
// through `sandboxRef`; the host clears it on every sandbox switch, so there is no subscription or teardown to write.
|
|
@@ -12,19 +12,26 @@ const registered: Registered[] = [];
|
|
|
12
12
|
// Sandbox scope counter; this package can't see sandbox ids, only whether the scope changed since a value was captured.
|
|
13
13
|
let generation = 0;
|
|
14
14
|
|
|
15
|
-
//
|
|
16
|
-
|
|
17
|
-
export const sandboxRef = <T>(initial: () => T, dispose?: (previous: T) => void): Ref<T> => {
|
|
18
|
-
const state = ref(initial()) as Ref<T>;
|
|
15
|
+
// Enrols a box in the scope: every switch hands its outgoing value to `dispose`, then refills it from `initial()`.
|
|
16
|
+
const scoped = <T, B extends { value: T }>(box: B, initial: () => T, dispose?: (previous: T) => void): B => {
|
|
19
17
|
registered.push({
|
|
20
18
|
clear: () => {
|
|
21
|
-
dispose?.(
|
|
22
|
-
|
|
19
|
+
dispose?.(box.value);
|
|
20
|
+
box.value = initial();
|
|
23
21
|
},
|
|
24
22
|
});
|
|
25
|
-
return
|
|
23
|
+
return box;
|
|
26
24
|
};
|
|
27
25
|
|
|
26
|
+
// Module state scoped to one sandbox: resets to a fresh `initial()` on every switch. `dispose`, if given, runs once on
|
|
27
|
+
// the outgoing value, for state that owns something the garbage collector won't reclaim.
|
|
28
|
+
export const sandboxRef = <T>(initial: () => T, dispose?: (previous: T) => void): Ref<T> => scoped(ref(initial()) as Ref<T>, initial, dispose);
|
|
29
|
+
|
|
30
|
+
// `sandboxRef`'s lifetime with `shallowRef`'s reactivity, for a value replaced whole rather than edited in place (a
|
|
31
|
+
// map, an object with its own methods), which deep reactivity would proxy for nothing and hand back as another object.
|
|
32
|
+
export const sandboxShallowRef = <T>(initial: () => T, dispose?: (previous: T) => void): ShallowRef<T> =>
|
|
33
|
+
scoped(shallowRef(initial()), initial, dispose);
|
|
34
|
+
|
|
28
35
|
// A sandbox-scoped box that nothing observes; same `.value` shape as a `Ref` so state can move between the two without
|
|
29
36
|
// changing call sites.
|
|
30
37
|
export interface SandboxValue<T> {
|
|
@@ -33,16 +40,8 @@ export interface SandboxValue<T> {
|
|
|
33
40
|
|
|
34
41
|
// Like `sandboxRef` but not reactive: safe to write from inside `detect()`/`badge()`, which run inside the host's own
|
|
35
42
|
// render computed, where writing a `Ref` would re-trigger it recursively.
|
|
36
|
-
export const sandboxValue = <T>(initial: () => T, dispose?: (previous: T) => void): SandboxValue<T> =>
|
|
37
|
-
|
|
38
|
-
registered.push({
|
|
39
|
-
clear: () => {
|
|
40
|
-
dispose?.(box.value);
|
|
41
|
-
box.value = initial();
|
|
42
|
-
},
|
|
43
|
-
});
|
|
44
|
-
return box;
|
|
45
|
-
};
|
|
43
|
+
export const sandboxValue = <T>(initial: () => T, dispose?: (previous: T) => void): SandboxValue<T> =>
|
|
44
|
+
scoped<T, SandboxValue<T>>({ value: initial() }, initial, dispose);
|
|
46
45
|
|
|
47
46
|
// Snapshot the current scope before an await; call the result after to check the scope hasn't switched meanwhile.
|
|
48
47
|
// Needed because emptying the refs doesn't stop an in-flight request from writing its answer into the new scope.
|
package/src/server.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import type { sandboxContract } from "@intentic/sandbox-contract";
|
|
2
|
+
import type { ContractRouterClient } from "@orpc/contract";
|
|
3
|
+
|
|
1
4
|
// Backend counterpart to `IntenticApi` (api.ts); a manifest `server` bundle's `activateServer` runs in a node process
|
|
2
5
|
// shared by every enabled extension, separate from the daemon. Mediates only the extension's route namespace (mount)
|
|
3
6
|
// and its reach into daemon routes (`daemon.*`, gated by `permissions.daemon`).
|
|
@@ -23,6 +26,10 @@ export interface ExtensionServerApi {
|
|
|
23
26
|
// Authenticated transport to the daemon's own routes; every call is checked against the manifest's
|
|
24
27
|
// `permissions.daemon` allowlist.
|
|
25
28
|
readonly daemon: {
|
|
29
|
+
// The daemon's contract, typed: a call names a procedure and its answer arrives parsed by the procedure's output
|
|
30
|
+
// schema. Refused before anything is sent unless `permissions.daemon` covers the method and path it resolves to.
|
|
31
|
+
readonly rpc: ContractRouterClient<typeof sandboxContract>;
|
|
32
|
+
// For what the contract does not carry: bytes (`/workspace/raw`) and the daemon's hand-written routes.
|
|
26
33
|
request(path: string, init?: RequestInit): Promise<Response>;
|
|
27
34
|
json<T>(path: string, init?: RequestInit): Promise<T>;
|
|
28
35
|
};
|
package/src/surface.json
CHANGED
|
@@ -1286,5 +1286,328 @@
|
|
|
1286
1286
|
"openAgent",
|
|
1287
1287
|
"openSession"
|
|
1288
1288
|
]
|
|
1289
|
+
},
|
|
1290
|
+
"2.16.0": {
|
|
1291
|
+
"manifest": [
|
|
1292
|
+
"$schema",
|
|
1293
|
+
"art",
|
|
1294
|
+
"category",
|
|
1295
|
+
"contributes",
|
|
1296
|
+
"engines",
|
|
1297
|
+
"entry",
|
|
1298
|
+
"icon",
|
|
1299
|
+
"logo",
|
|
1300
|
+
"name",
|
|
1301
|
+
"permissions",
|
|
1302
|
+
"publisher",
|
|
1303
|
+
"server",
|
|
1304
|
+
"version"
|
|
1305
|
+
],
|
|
1306
|
+
"contributes": [
|
|
1307
|
+
"agent",
|
|
1308
|
+
"automationTemplates",
|
|
1309
|
+
"bin",
|
|
1310
|
+
"capabilities",
|
|
1311
|
+
"commands",
|
|
1312
|
+
"documents",
|
|
1313
|
+
"environment",
|
|
1314
|
+
"files",
|
|
1315
|
+
"listener",
|
|
1316
|
+
"processes",
|
|
1317
|
+
"settings",
|
|
1318
|
+
"viewers",
|
|
1319
|
+
"views"
|
|
1320
|
+
],
|
|
1321
|
+
"api": [
|
|
1322
|
+
"apiVersion",
|
|
1323
|
+
"audience",
|
|
1324
|
+
"chat",
|
|
1325
|
+
"commands",
|
|
1326
|
+
"documents",
|
|
1327
|
+
"href",
|
|
1328
|
+
"models",
|
|
1329
|
+
"navigate",
|
|
1330
|
+
"processes",
|
|
1331
|
+
"route",
|
|
1332
|
+
"sandbox",
|
|
1333
|
+
"settings",
|
|
1334
|
+
"terminal",
|
|
1335
|
+
"theme",
|
|
1336
|
+
"viewers",
|
|
1337
|
+
"views",
|
|
1338
|
+
"workspace"
|
|
1339
|
+
],
|
|
1340
|
+
"listener": [
|
|
1341
|
+
"automation",
|
|
1342
|
+
"events",
|
|
1343
|
+
"provider"
|
|
1344
|
+
],
|
|
1345
|
+
"sandboxApi": [
|
|
1346
|
+
"fetch",
|
|
1347
|
+
"json",
|
|
1348
|
+
"key",
|
|
1349
|
+
"origin",
|
|
1350
|
+
"previewAddress",
|
|
1351
|
+
"reachable",
|
|
1352
|
+
"request",
|
|
1353
|
+
"role",
|
|
1354
|
+
"rpc"
|
|
1355
|
+
],
|
|
1356
|
+
"moduleExports": [
|
|
1357
|
+
"extensionApiVersion",
|
|
1358
|
+
"flattenQuery",
|
|
1359
|
+
"hostSlot",
|
|
1360
|
+
"mergeQuery",
|
|
1361
|
+
"readDaemonStream",
|
|
1362
|
+
"resetSandboxScope",
|
|
1363
|
+
"sandboxLedger",
|
|
1364
|
+
"sandboxPoll",
|
|
1365
|
+
"sandboxRef",
|
|
1366
|
+
"sandboxScopeGuard",
|
|
1367
|
+
"sandboxShallowRef",
|
|
1368
|
+
"sandboxValue",
|
|
1369
|
+
"satisfiesEngines"
|
|
1370
|
+
],
|
|
1371
|
+
"workspaceApi": [
|
|
1372
|
+
"capabilities",
|
|
1373
|
+
"file",
|
|
1374
|
+
"fillDiff",
|
|
1375
|
+
"inProject",
|
|
1376
|
+
"onDidChange",
|
|
1377
|
+
"onDidChangeFiles",
|
|
1378
|
+
"onDidChangeProject",
|
|
1379
|
+
"onDidChangeRefs",
|
|
1380
|
+
"openDiff",
|
|
1381
|
+
"project",
|
|
1382
|
+
"readJson",
|
|
1383
|
+
"repos",
|
|
1384
|
+
"setProject",
|
|
1385
|
+
"write"
|
|
1386
|
+
],
|
|
1387
|
+
"chatApi": [
|
|
1388
|
+
"composeLoop",
|
|
1389
|
+
"composeWorkflow",
|
|
1390
|
+
"openAgent",
|
|
1391
|
+
"openSession"
|
|
1392
|
+
]
|
|
1393
|
+
},
|
|
1394
|
+
"2.17.0": {
|
|
1395
|
+
"manifest": [
|
|
1396
|
+
"$schema",
|
|
1397
|
+
"art",
|
|
1398
|
+
"category",
|
|
1399
|
+
"contributes",
|
|
1400
|
+
"engines",
|
|
1401
|
+
"entry",
|
|
1402
|
+
"icon",
|
|
1403
|
+
"logo",
|
|
1404
|
+
"name",
|
|
1405
|
+
"permissions",
|
|
1406
|
+
"publisher",
|
|
1407
|
+
"server",
|
|
1408
|
+
"version"
|
|
1409
|
+
],
|
|
1410
|
+
"contributes": [
|
|
1411
|
+
"agent",
|
|
1412
|
+
"automationTemplates",
|
|
1413
|
+
"bin",
|
|
1414
|
+
"capabilities",
|
|
1415
|
+
"commands",
|
|
1416
|
+
"documents",
|
|
1417
|
+
"environment",
|
|
1418
|
+
"files",
|
|
1419
|
+
"listener",
|
|
1420
|
+
"processes",
|
|
1421
|
+
"settings",
|
|
1422
|
+
"viewers",
|
|
1423
|
+
"views"
|
|
1424
|
+
],
|
|
1425
|
+
"api": [
|
|
1426
|
+
"apiVersion",
|
|
1427
|
+
"audience",
|
|
1428
|
+
"chat",
|
|
1429
|
+
"commands",
|
|
1430
|
+
"documents",
|
|
1431
|
+
"href",
|
|
1432
|
+
"models",
|
|
1433
|
+
"navigate",
|
|
1434
|
+
"processes",
|
|
1435
|
+
"route",
|
|
1436
|
+
"sandbox",
|
|
1437
|
+
"settings",
|
|
1438
|
+
"terminal",
|
|
1439
|
+
"theme",
|
|
1440
|
+
"viewers",
|
|
1441
|
+
"views",
|
|
1442
|
+
"workspace"
|
|
1443
|
+
],
|
|
1444
|
+
"listener": [
|
|
1445
|
+
"automation",
|
|
1446
|
+
"events",
|
|
1447
|
+
"provider"
|
|
1448
|
+
],
|
|
1449
|
+
"sandboxApi": [
|
|
1450
|
+
"fetch",
|
|
1451
|
+
"json",
|
|
1452
|
+
"key",
|
|
1453
|
+
"origin",
|
|
1454
|
+
"previewAddress",
|
|
1455
|
+
"reachable",
|
|
1456
|
+
"request",
|
|
1457
|
+
"role",
|
|
1458
|
+
"rpc"
|
|
1459
|
+
],
|
|
1460
|
+
"moduleExports": [
|
|
1461
|
+
"extensionApiVersion",
|
|
1462
|
+
"flattenQuery",
|
|
1463
|
+
"hostSlot",
|
|
1464
|
+
"mergeQuery",
|
|
1465
|
+
"readDaemonStream",
|
|
1466
|
+
"resetSandboxScope",
|
|
1467
|
+
"sandboxLedger",
|
|
1468
|
+
"sandboxPoll",
|
|
1469
|
+
"sandboxRef",
|
|
1470
|
+
"sandboxScopeGuard",
|
|
1471
|
+
"sandboxShallowRef",
|
|
1472
|
+
"sandboxValue",
|
|
1473
|
+
"satisfiesEngines"
|
|
1474
|
+
],
|
|
1475
|
+
"workspaceApi": [
|
|
1476
|
+
"capabilities",
|
|
1477
|
+
"file",
|
|
1478
|
+
"fillDiff",
|
|
1479
|
+
"inProject",
|
|
1480
|
+
"onDidChange",
|
|
1481
|
+
"onDidChangeFiles",
|
|
1482
|
+
"onDidChangeProject",
|
|
1483
|
+
"onDidChangeRefs",
|
|
1484
|
+
"openDiff",
|
|
1485
|
+
"project",
|
|
1486
|
+
"readJson",
|
|
1487
|
+
"repos",
|
|
1488
|
+
"setProject",
|
|
1489
|
+
"write"
|
|
1490
|
+
],
|
|
1491
|
+
"chatApi": [
|
|
1492
|
+
"composeLoop",
|
|
1493
|
+
"composeWorkflow",
|
|
1494
|
+
"openAgent",
|
|
1495
|
+
"openSession"
|
|
1496
|
+
],
|
|
1497
|
+
"daemonApi": [
|
|
1498
|
+
"json",
|
|
1499
|
+
"request",
|
|
1500
|
+
"rpc"
|
|
1501
|
+
]
|
|
1502
|
+
},
|
|
1503
|
+
"2.18.0": {
|
|
1504
|
+
"manifest": [
|
|
1505
|
+
"$schema",
|
|
1506
|
+
"art",
|
|
1507
|
+
"category",
|
|
1508
|
+
"contributes",
|
|
1509
|
+
"engines",
|
|
1510
|
+
"entry",
|
|
1511
|
+
"icon",
|
|
1512
|
+
"logo",
|
|
1513
|
+
"name",
|
|
1514
|
+
"permissions",
|
|
1515
|
+
"publisher",
|
|
1516
|
+
"server",
|
|
1517
|
+
"version"
|
|
1518
|
+
],
|
|
1519
|
+
"contributes": [
|
|
1520
|
+
"agent",
|
|
1521
|
+
"automationTemplates",
|
|
1522
|
+
"bin",
|
|
1523
|
+
"capabilities",
|
|
1524
|
+
"commands",
|
|
1525
|
+
"documents",
|
|
1526
|
+
"environment",
|
|
1527
|
+
"files",
|
|
1528
|
+
"listener",
|
|
1529
|
+
"processes",
|
|
1530
|
+
"settings",
|
|
1531
|
+
"viewers",
|
|
1532
|
+
"views"
|
|
1533
|
+
],
|
|
1534
|
+
"api": [
|
|
1535
|
+
"apiVersion",
|
|
1536
|
+
"audience",
|
|
1537
|
+
"chat",
|
|
1538
|
+
"commands",
|
|
1539
|
+
"documents",
|
|
1540
|
+
"href",
|
|
1541
|
+
"models",
|
|
1542
|
+
"navigate",
|
|
1543
|
+
"processes",
|
|
1544
|
+
"route",
|
|
1545
|
+
"sandbox",
|
|
1546
|
+
"settings",
|
|
1547
|
+
"terminal",
|
|
1548
|
+
"theme",
|
|
1549
|
+
"viewers",
|
|
1550
|
+
"views",
|
|
1551
|
+
"workspace"
|
|
1552
|
+
],
|
|
1553
|
+
"listener": [
|
|
1554
|
+
"automation",
|
|
1555
|
+
"events",
|
|
1556
|
+
"provider"
|
|
1557
|
+
],
|
|
1558
|
+
"sandboxApi": [
|
|
1559
|
+
"fetch",
|
|
1560
|
+
"json",
|
|
1561
|
+
"key",
|
|
1562
|
+
"origin",
|
|
1563
|
+
"previewAddress",
|
|
1564
|
+
"reachable",
|
|
1565
|
+
"request",
|
|
1566
|
+
"role",
|
|
1567
|
+
"rpc"
|
|
1568
|
+
],
|
|
1569
|
+
"moduleExports": [
|
|
1570
|
+
"extensionApiVersion",
|
|
1571
|
+
"flattenQuery",
|
|
1572
|
+
"hostSlot",
|
|
1573
|
+
"mergeQuery",
|
|
1574
|
+
"readDaemonStream",
|
|
1575
|
+
"resetSandboxScope",
|
|
1576
|
+
"sandboxLedger",
|
|
1577
|
+
"sandboxPoll",
|
|
1578
|
+
"sandboxRef",
|
|
1579
|
+
"sandboxScopeGuard",
|
|
1580
|
+
"sandboxShallowRef",
|
|
1581
|
+
"sandboxValue",
|
|
1582
|
+
"satisfiesEngines"
|
|
1583
|
+
],
|
|
1584
|
+
"workspaceApi": [
|
|
1585
|
+
"capabilities",
|
|
1586
|
+
"file",
|
|
1587
|
+
"fillDiff",
|
|
1588
|
+
"inProject",
|
|
1589
|
+
"onDidChange",
|
|
1590
|
+
"onDidChangeFiles",
|
|
1591
|
+
"onDidChangeProject",
|
|
1592
|
+
"onDidChangeRefs",
|
|
1593
|
+
"onDidChangeRepos",
|
|
1594
|
+
"openDiff",
|
|
1595
|
+
"project",
|
|
1596
|
+
"readJson",
|
|
1597
|
+
"repos",
|
|
1598
|
+
"setProject",
|
|
1599
|
+
"write"
|
|
1600
|
+
],
|
|
1601
|
+
"chatApi": [
|
|
1602
|
+
"composeLoop",
|
|
1603
|
+
"composeWorkflow",
|
|
1604
|
+
"openAgent",
|
|
1605
|
+
"openSession"
|
|
1606
|
+
],
|
|
1607
|
+
"daemonApi": [
|
|
1608
|
+
"json",
|
|
1609
|
+
"request",
|
|
1610
|
+
"rpc"
|
|
1611
|
+
]
|
|
1289
1612
|
}
|
|
1290
1613
|
}
|
package/src/version.ts
CHANGED
|
@@ -98,4 +98,15 @@
|
|
|
98
98
|
// areas it was granted and ships none of them. No member was added, so the recorded surface has no entry for it. A
|
|
99
99
|
// view that gates a WRITE affordance on `maintainer` now hides it from somebody the daemon would admit, which is the
|
|
100
100
|
// one drift worth knowing about: gate on `writer` and up instead.
|
|
101
|
-
|
|
101
|
+
// 2.16.0 adds `sandboxShallowRef`: `sandboxRef`'s lifetime with `shallowRef`'s reactivity. The editor now keeps its own
|
|
102
|
+
// per-sandbox state (open chats, the fleet roster, the push flow) in the scope an extension's badge lives in, so one
|
|
103
|
+
// switch empties both; a value that is a map or an object with its own methods (a conversation, a run watcher) must
|
|
104
|
+
// not be deep-proxied, which is what `sandboxRef` does. Additive: `sandboxRef` and `sandboxValue` are unchanged.
|
|
105
|
+
// 2.17.0 gives the backend half the typed daemon client its browser half has: `api.daemon.rpc`, created by the daemon's
|
|
106
|
+
// backend host and handed to `activateServer`, so a server bundle carries no client of its own. It is gated like
|
|
107
|
+
// `request`/`json`, by `permissions.daemon` on the method and path a call resolves to, and refused before anything is
|
|
108
|
+
// sent. Additive, and the recorded surface grows a `daemonApi` member list (`api.daemon`'s own members, read from
|
|
109
|
+
// server.ts): the backend half was the one surface no recorded grain could see.
|
|
110
|
+
// 2.18.0 adds `api.workspace.onDidChangeRepos`: the repository set moving (a clone, a scaffold, a delete). `repos()` is
|
|
111
|
+
// narrowed to the open project, so a view listing every repository (the Projects dashboard) could only poll. Additive.
|
|
112
|
+
export const extensionApiVersion = "2.18.0";
|