History

misc fixes

Rhys Sullivan committed 8 months ago

Commit e604ea61 parent 54d7a4225 files · +414 −256Browse files

Unified · Split

25 files
  1. apps/executor/package.json +0 −2
  2. apps/executor/src/cli/dev.ts +3 −3
  3. apps/executor/src/server/index.ts +3 −5
  4. bun.lock +103 −3
  5. knip.json +38 −0
  6. package.json +3 −1
  7. packages/codemode-mcp/src/mcp-elicitation-bridge.ts +1 −1
  8. packages/control-plane/src/api/api.ts +0 −50
  9. packages/control-plane/src/api/executions/http.ts +4 −4
  10. packages/control-plane/src/api/http.ts +2 −2
  11. packages/control-plane/src/api/index.ts +15 −2
  12. packages/control-plane/src/api/local/http.ts +3 −3
  13. packages/control-plane/src/api/memberships/http.ts +5 −5
  14. packages/control-plane/src/api/organizations/http.ts +6 −6
  15. packages/control-plane/src/api/policies/http.ts +6 −6
  16. packages/control-plane/src/api/service.ts +56 −4
  17. packages/control-plane/src/api/sources/http.ts +6 −6
  18. packages/control-plane/src/api/workspaces/http.ts +6 −6
  19. packages/control-plane/src/runtime/control-plane-runtime.test.ts +1 −6
  20. packages/control-plane/src/runtime/execution-service.ts +5 −18
  21. packages/control-plane/src/runtime/index.ts +75 −14
  22. packages/control-plane/src/runtime/services.ts +71 −86
  23. packages/control-plane/src/runtime/slug.ts +0 −18
  24. packages/control-plane/src/runtime/test-http-client.ts +2 −4
  25. packages/kitchen-sink/package.json +0 −1
apps/executor/package.json+0−2
@@ -16,8 +16,6 @@ · 15 unmodified lines
1616 "@effect/platform": "catalog:",
1717 "@effect/platform-node": "catalog:",
1818 "@executor-v3/codemode-core": "workspace:*",
19− "@executor-v3/codemode-mcp": "workspace:*",
20− "@executor-v3/codemode-openapi": "workspace:*",
2119 "@executor-v3/control-plane": "workspace:*",
2220 "@executor-v3/runtime-local-inproc": "workspace:*",
2321 "effect": "catalog:"
apps/executor/src/cli/dev.ts+3−3
@@ -4,7 +4,7 @@ import { · 3 unmodified lines
44 } from "@executor-v3/control-plane";
55 import * as Effect from "effect/Effect";
66
7−export type SeedDemoMcpSourceInput = {
7+type SeedDemoMcpSourceInput = {
88 client: ControlPlaneClient;
99 workspaceId: string;
1010 endpoint: string;
@@ -12,7 +12,7 @@ export type SeedDemoMcpSourceInput = { · 1 unmodified line
1212 namespace: string;
1313 };
1414
15−export type SeedDemoMcpSourceResult =
15+type SeedDemoMcpSourceResult =
1616 | {
1717 action: "noop";
1818 sourceId: string;
@@ -26,7 +26,7 @@ export type SeedDemoMcpSourceResult = · 7 unmodified lines
2626 endpoint: string;
2727 };
2828
29−export type SeedGithubOpenApiSourceInput = {
29+type SeedGithubOpenApiSourceInput = {
3030 client: ControlPlaneClient;
3131 workspaceId: string;
3232 endpoint: string;
apps/executor/src/server/index.ts+3−5
@@ -6,7 +6,6 @@ import { HttpApiBuilder, HttpServer } from "@effect/platform"; · 5 unmodified lines
66 import { NodeHttpServer } from "@effect/platform-node";
77 import {
88 ControlPlaneActorResolver,
9− ControlPlaneService,
109 createControlPlaneApiLayer,
1110 createSqlControlPlaneRuntime,
1211 type ResolveExecutionEnvironment,
@@ -24,14 +23,14 @@ import { · 11 unmodified lines
2423 DEFAULT_SERVER_PORT,
2524 } from "./config";
2625
27−export type LocalExecutorServer = {
26+type LocalExecutorServer = {
2827 readonly runtime: SqlControlPlaneRuntime;
2928 readonly port: number;
3029 readonly host: string;
3130 readonly baseUrl: string;
3231 };
3332
34−export type StartLocalExecutorServerOptions = {
33+type StartLocalExecutorServerOptions = {
3534 readonly port?: number;
3635 readonly host?: string;
3736 readonly localDataDir?: string;
@@ -47,12 +46,11 @@ const createControlPlaneServerLayer = (input: { · 9 unmodified lines
4746 host: string;
4847 port: number;
4948 }) => {
50− const serviceLayer = Layer.succeed(ControlPlaneService, input.runtime.service);
5149 const actorResolverLayer = Layer.succeed(
5250 ControlPlaneActorResolver,
5351 input.runtime.actorResolver,
5452 );
55− const apiLayer = createControlPlaneApiLayer(serviceLayer, actorResolverLayer);
53+ const apiLayer = createControlPlaneApiLayer(input.runtime.serviceLayer, actorResolverLayer);
5654
5755 return HttpApiBuilder.serve().pipe(
5856 Layer.provide(apiLayer),
bun.lock+103−3
@@ -5,6 +5,7 @@ · 4 unmodified lines
55 "": {
66 "name": "executor-v3",
77 "devDependencies": {
8+ "knip": "^5.85.0",
89 "typescript": "^5.9.3",
910 },
1011 },
@@ -18,8 +19,6 @@ · 7 unmodified lines
1819 "@effect/platform": "catalog:",
1920 "@effect/platform-node": "catalog:",
2021 "@executor-v3/codemode-core": "workspace:*",
21− "@executor-v3/codemode-mcp": "workspace:*",
22− "@executor-v3/codemode-openapi": "workspace:*",
2322 "@executor-v3/control-plane": "workspace:*",
2423 "@executor-v3/runtime-local-inproc": "workspace:*",
2524 "effect": "catalog:",
@@ -136,7 +135,6 @@ · 110 unmodified lines
136135 "@executor-v3/ai-sdk-adapter": "workspace:*",
137136 "@executor-v3/codemode-core": "workspace:*",
138137 "@executor-v3/codemode-openapi": "workspace:*",
139− "@executor-v3/control-plane": "workspace:*",
140138 "@executor-v3/runtime-local-inproc": "workspace:*",
141139 "effect": "catalog:",
142140 },
@@ -241,6 +239,12 @@ · 98 unmodified lines
241239
242240 "@electric-sql/pglite": ["@electric-sql/pglite@0.3.15", "", {}, "sha512-Cj++n1Mekf9ETfdc16TlDi+cDDQF0W7EcbyRHYOAeZdsAe8M/FJg18itDTSwyHfar2WIezawM9o0EKaRGVKygQ=="],
243241
242+ "@emnapi/core": ["@emnapi/core@1.8.1", "", { "dependencies": { "@emnapi/wasi-threads": "1.1.0", "tslib": "^2.4.0" } }, "sha512-AvT9QFpxK0Zd8J0jopedNm+w/2fIzvtPKPjqyw9jwvBaReTTqPBk9Hixaz7KbjimP+QNz605/XnjFcDAL2pqBg=="],
243+
244+ "@emnapi/runtime": ["@emnapi/runtime@1.8.1", "", { "dependencies": { "tslib": "^2.4.0" } }, "sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg=="],
245+
246+ "@emnapi/wasi-threads": ["@emnapi/wasi-threads@1.1.0", "", { "dependencies": { "tslib": "^2.4.0" } }, "sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ=="],
247+
244248 "@esbuild/aix-ppc64": ["@esbuild/aix-ppc64@0.25.12", "", { "os": "aix", "cpu": "ppc64" }, "sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA=="],
245249
246250 "@esbuild/android-arm": ["@esbuild/android-arm@0.25.12", "", { "os": "android", "cpu": "arm" }, "sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg=="],
@@ -331,8 +335,56 @@ · 84 unmodified lines
331335
332336 "@msgpackr-extract/msgpackr-extract-win32-x64": ["@msgpackr-extract/msgpackr-extract-win32-x64@3.0.3", "", { "os": "win32", "cpu": "x64" }, "sha512-x0fWaQtYp4E6sktbsdAqnehxDgEc/VwM7uLsRCYWaiGu0ykYdZPiS8zCWdnjHwyiumousxfBm4SO31eXqwEZhQ=="],
333337
338+ "@napi-rs/wasm-runtime": ["@napi-rs/wasm-runtime@1.1.1", "", { "dependencies": { "@emnapi/core": "^1.7.1", "@emnapi/runtime": "^1.7.1", "@tybys/wasm-util": "^0.10.1" } }, "sha512-p64ah1M1ld8xjWv3qbvFwHiFVWrq1yFvV4f7w+mzaqiR4IlSgkqhcRdHwsGgomwzBH51sRY4NEowLxnaBjcW/A=="],
339+
340+ "@nodelib/fs.scandir": ["@nodelib/fs.scandir@2.1.5", "", { "dependencies": { "@nodelib/fs.stat": "2.0.5", "run-parallel": "^1.1.9" } }, "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g=="],
341+
342+ "@nodelib/fs.stat": ["@nodelib/fs.stat@2.0.5", "", {}, "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A=="],
343+
344+ "@nodelib/fs.walk": ["@nodelib/fs.walk@1.2.8", "", { "dependencies": { "@nodelib/fs.scandir": "2.1.5", "fastq": "^1.6.0" } }, "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg=="],
345+
334346 "@opentelemetry/api": ["@opentelemetry/api@1.9.0", "", {}, "sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg=="],
335347
348+ "@oxc-resolver/binding-android-arm-eabi": ["@oxc-resolver/binding-android-arm-eabi@11.19.1", "", { "os": "android", "cpu": "arm" }, "sha512-aUs47y+xyXHUKlbhqHUjBABjvycq6YSD7bpxSW7vplUmdzAlJ93yXY6ZR0c1o1x5A/QKbENCvs3+NlY8IpIVzg=="],
349+
350+ "@oxc-resolver/binding-android-arm64": ["@oxc-resolver/binding-android-arm64@11.19.1", "", { "os": "android", "cpu": "arm64" }, "sha512-oolbkRX+m7Pq2LNjr/kKgYeC7bRDMVTWPgxBGMjSpZi/+UskVo4jsMU3MLheZV55jL6c3rNelPl4oD60ggYmqA=="],
351+
352+ "@oxc-resolver/binding-darwin-arm64": ["@oxc-resolver/binding-darwin-arm64@11.19.1", "", { "os": "darwin", "cpu": "arm64" }, "sha512-nUC6d2i3R5B12sUW4O646qD5cnMXf2oBGPLIIeaRfU9doJRORAbE2SGv4eW6rMqhD+G7nf2Y8TTJTLiiO3Q/dQ=="],
353+
354+ "@oxc-resolver/binding-darwin-x64": ["@oxc-resolver/binding-darwin-x64@11.19.1", "", { "os": "darwin", "cpu": "x64" }, "sha512-cV50vE5+uAgNcFa3QY1JOeKDSkM/9ReIcc/9wn4TavhW/itkDGrXhw9jaKnkQnGbjJ198Yh5nbX/Gr2mr4Z5jQ=="],
355+
356+ "@oxc-resolver/binding-freebsd-x64": ["@oxc-resolver/binding-freebsd-x64@11.19.1", "", { "os": "freebsd", "cpu": "x64" }, "sha512-xZOQiYGFxtk48PBKff+Zwoym7ScPAIVp4c14lfLxizO2LTTTJe5sx9vQNGrBymrf/vatSPNMD4FgsaaRigPkqw=="],
357+
358+ "@oxc-resolver/binding-linux-arm-gnueabihf": ["@oxc-resolver/binding-linux-arm-gnueabihf@11.19.1", "", { "os": "linux", "cpu": "arm" }, "sha512-lXZYWAC6kaGe/ky2su94e9jN9t6M0/6c+GrSlCqL//XO1cxi5lpAhnJYdyrKfm0ZEr/c7RNyAx3P7FSBcBd5+A=="],
359+
360+ "@oxc-resolver/binding-linux-arm-musleabihf": ["@oxc-resolver/binding-linux-arm-musleabihf@11.19.1", "", { "os": "linux", "cpu": "arm" }, "sha512-veG1kKsuK5+t2IsO9q0DErYVSw2azvCVvWHnfTOS73WE0STdLLB7Q1bB9WR+yHPQM76ASkFyRbogWo1GR1+WbQ=="],
361+
362+ "@oxc-resolver/binding-linux-arm64-gnu": ["@oxc-resolver/binding-linux-arm64-gnu@11.19.1", "", { "os": "linux", "cpu": "arm64" }, "sha512-heV2+jmXyYnUrpUXSPugqWDRpnsQcDm2AX4wzTuvgdlZfoNYO0O3W2AVpJYaDn9AG4JdM6Kxom8+foE7/BcSig=="],
363+
364+ "@oxc-resolver/binding-linux-arm64-musl": ["@oxc-resolver/binding-linux-arm64-musl@11.19.1", "", { "os": "linux", "cpu": "arm64" }, "sha512-jvo2Pjs1c9KPxMuMPIeQsgu0mOJF9rEb3y3TdpsrqwxRM+AN6/nDDwv45n5ZrUnQMsdBy5gIabioMKnQfWo9ew=="],
365+
366+ "@oxc-resolver/binding-linux-ppc64-gnu": ["@oxc-resolver/binding-linux-ppc64-gnu@11.19.1", "", { "os": "linux", "cpu": "ppc64" }, "sha512-vLmdNxWCdN7Uo5suays6A/+ywBby2PWBBPXctWPg5V0+eVuzsJxgAn6MMB4mPlshskYbppjpN2Zg83ArHze9gQ=="],
367+
368+ "@oxc-resolver/binding-linux-riscv64-gnu": ["@oxc-resolver/binding-linux-riscv64-gnu@11.19.1", "", { "os": "linux", "cpu": "none" }, "sha512-/b+WgR+VTSBxzgOhDO7TlMXC1ufPIMR6Vj1zN+/x+MnyXGW7prTLzU9eW85Aj7Th7CCEG9ArCbTeqxCzFWdg2w=="],
369+
370+ "@oxc-resolver/binding-linux-riscv64-musl": ["@oxc-resolver/binding-linux-riscv64-musl@11.19.1", "", { "os": "linux", "cpu": "none" }, "sha512-YlRdeWb9j42p29ROh+h4eg/OQ3dTJlpHSa+84pUM9+p6i3djtPz1q55yLJhgW9XfDch7FN1pQ/Vd6YP+xfRIuw=="],
371+
372+ "@oxc-resolver/binding-linux-s390x-gnu": ["@oxc-resolver/binding-linux-s390x-gnu@11.19.1", "", { "os": "linux", "cpu": "s390x" }, "sha512-EDpafVOQWF8/MJynsjOGFThcqhRHy417sRyLfQmeiamJ8qVhSKAn2Dn2VVKUGCjVB9C46VGjhNo7nOPUi1x6uA=="],
373+
374+ "@oxc-resolver/binding-linux-x64-gnu": ["@oxc-resolver/binding-linux-x64-gnu@11.19.1", "", { "os": "linux", "cpu": "x64" }, "sha512-NxjZe+rqWhr+RT8/Ik+5ptA3oz7tUw361Wa5RWQXKnfqwSSHdHyrw6IdcTfYuml9dM856AlKWZIUXDmA9kkiBQ=="],
375+
376+ "@oxc-resolver/binding-linux-x64-musl": ["@oxc-resolver/binding-linux-x64-musl@11.19.1", "", { "os": "linux", "cpu": "x64" }, "sha512-cM/hQwsO3ReJg5kR+SpI69DMfvNCp+A/eVR4b4YClE5bVZwz8rh2Nh05InhwI5HR/9cArbEkzMjcKgTHS6UaNw=="],
377+
378+ "@oxc-resolver/binding-openharmony-arm64": ["@oxc-resolver/binding-openharmony-arm64@11.19.1", "", { "os": "none", "cpu": "arm64" }, "sha512-QF080IowFB0+9Rh6RcD19bdgh49BpQHUW5TajG1qvWHvmrQznTZZjYlgE2ltLXyKY+qs4F/v5xuX1XS7Is+3qA=="],
379+
380+ "@oxc-resolver/binding-wasm32-wasi": ["@oxc-resolver/binding-wasm32-wasi@11.19.1", "", { "dependencies": { "@napi-rs/wasm-runtime": "^1.1.1" }, "cpu": "none" }, "sha512-w8UCKhX826cP/ZLokXDS6+milN8y4X7zidsAttEdWlVoamTNf6lhBJldaWr3ukTDiye7s4HRcuPEPOXNC432Vg=="],
381+
382+ "@oxc-resolver/binding-win32-arm64-msvc": ["@oxc-resolver/binding-win32-arm64-msvc@11.19.1", "", { "os": "win32", "cpu": "arm64" }, "sha512-nJ4AsUVZrVKwnU/QRdzPCCrO0TrabBqgJ8pJhXITdZGYOV28TIYystV1VFLbQ7DtAcaBHpocT5/ZJnF78YJPtQ=="],
383+
384+ "@oxc-resolver/binding-win32-ia32-msvc": ["@oxc-resolver/binding-win32-ia32-msvc@11.19.1", "", { "os": "win32", "cpu": "ia32" }, "sha512-EW+ND5q2Tl+a3pH81l1QbfgbF3HmqgwLfDfVithRFheac8OTcnbXt/JxqD2GbDkb7xYEqy1zNaVFRr3oeG8npA=="],
385+
386+ "@oxc-resolver/binding-win32-x64-msvc": ["@oxc-resolver/binding-win32-x64-msvc@11.19.1", "", { "os": "win32", "cpu": "x64" }, "sha512-6hIU3RQu45B+VNTY4Ru8ppFwjVS/S5qwYyGhBotmjxfEKk41I2DlGtRfGJndZ5+6lneE2pwloqunlOyZuX/XAw=="],
387+
336388 "@parcel/watcher": ["@parcel/watcher@2.5.6", "", { "dependencies": { "detect-libc": "^2.0.3", "is-glob": "^4.0.3", "node-addon-api": "^7.0.0", "picomatch": "^4.0.3" }, "optionalDependencies": { "@parcel/watcher-android-arm64": "2.5.6", "@parcel/watcher-darwin-arm64": "2.5.6", "@parcel/watcher-darwin-x64": "2.5.6", "@parcel/watcher-freebsd-x64": "2.5.6", "@parcel/watcher-linux-arm-glibc": "2.5.6", "@parcel/watcher-linux-arm-musl": "2.5.6", "@parcel/watcher-linux-arm64-glibc": "2.5.6", "@parcel/watcher-linux-arm64-musl": "2.5.6", "@parcel/watcher-linux-x64-glibc": "2.5.6", "@parcel/watcher-linux-x64-musl": "2.5.6", "@parcel/watcher-win32-arm64": "2.5.6", "@parcel/watcher-win32-ia32": "2.5.6", "@parcel/watcher-win32-x64": "2.5.6" } }, "sha512-tmmZ3lQxAe/k/+rNnXQRawJ4NjxO2hqiOLTHvWchtGZULp4RyFeh6aU4XdOYBFe2KE1oShQTv4AblOs2iOrNnQ=="],
337389
338390 "@parcel/watcher-android-arm64": ["@parcel/watcher-android-arm64@2.5.6", "", { "os": "android", "cpu": "arm64" }, "sha512-YQxSS34tPF/6ZG7r/Ih9xy+kP/WwediEUsqmtf0cuCV5TPPKw/PQHRhueUo6JdeFJaqV3pyjm0GdYjZotbRt/A=="],
@@ -415,6 +467,8 @@ · 76 unmodified lines
415467
416468 "@tediousjs/connection-string": ["@tediousjs/connection-string@0.5.0", "", {}, "sha512-7qSgZbincDDDFyRweCIEvZULFAw5iz/DeunhvuxpL31nfntX3P4Yd4HkHBRg9H8CdqY1e5WFN1PZIz/REL9MVQ=="],
417469
470+ "@tybys/wasm-util": ["@tybys/wasm-util@0.10.1", "", { "dependencies": { "tslib": "^2.4.0" } }, "sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg=="],
471+
418472 "@types/chai": ["@types/chai@5.2.3", "", { "dependencies": { "@types/deep-eql": "*", "assertion-error": "^2.0.1" } }, "sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA=="],
419473
420474 "@types/deep-eql": ["@types/deep-eql@4.0.2", "", {}, "sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw=="],
@@ -457,6 +511,8 @@ · 36 unmodified lines
457511
458512 "ajv-formats": ["ajv-formats@3.0.1", "", { "dependencies": { "ajv": "^8.0.0" } }, "sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ=="],
459513
514+ "argparse": ["argparse@2.0.1", "", {}, "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q=="],
515+
460516 "assertion-error": ["assertion-error@2.0.1", "", {}, "sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA=="],
461517
462518 "base64-js": ["base64-js@1.5.1", "", {}, "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA=="],
@@ -465,6 +521,8 @@ · 2 unmodified lines
465521
466522 "body-parser": ["body-parser@2.2.2", "", { "dependencies": { "bytes": "^3.1.2", "content-type": "^1.0.5", "debug": "^4.4.3", "http-errors": "^2.0.0", "iconv-lite": "^0.7.0", "on-finished": "^2.4.1", "qs": "^6.14.1", "raw-body": "^3.0.1", "type-is": "^2.0.1" } }, "sha512-oP5VkATKlNwcgvxi0vM0p/D3n2C3EReYVX+DNYs5TjZFn/oQt2j+4sVJtSMr18pdRr8wjTcBl6LoV+FUwzPmNA=="],
467523
524+ "braces": ["braces@3.0.3", "", { "dependencies": { "fill-range": "^7.1.1" } }, "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA=="],
525+
468526 "buffer": ["buffer@6.0.3", "", { "dependencies": { "base64-js": "^1.3.1", "ieee754": "^1.2.1" } }, "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA=="],
469527
470528 "buffer-equal-constant-time": ["buffer-equal-constant-time@1.0.1", "", {}, "sha512-zRpUiDwd/xk6ADqPMATG8vc9VPrkck7T07OIx0gnjmJAnHnTVXNQG3vfvWNuiZIkwu9KrKdA1iJKfsfTVxE6NA=="],
@@ -563,14 +621,24 @@ · 92 unmodified lines
563621
564622 "fast-deep-equal": ["fast-deep-equal@3.1.3", "", {}, "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q=="],
565623
624+ "fast-glob": ["fast-glob@3.3.3", "", { "dependencies": { "@nodelib/fs.stat": "^2.0.2", "@nodelib/fs.walk": "^1.2.3", "glob-parent": "^5.1.2", "merge2": "^1.3.0", "micromatch": "^4.0.8" } }, "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg=="],
625+
566626 "fast-uri": ["fast-uri@3.1.0", "", {}, "sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA=="],
567627
628+ "fastq": ["fastq@1.20.1", "", { "dependencies": { "reusify": "^1.0.4" } }, "sha512-GGToxJ/w1x32s/D2EKND7kTil4n8OVk/9mycTc4VDza13lOvpUZTGX3mFSCtV9ksdGBVzvsyAVLM6mHFThxXxw=="],
629+
630+ "fd-package-json": ["fd-package-json@2.0.0", "", { "dependencies": { "walk-up-path": "^4.0.0" } }, "sha512-jKmm9YtsNXN789RS/0mSzOC1NUq9mkVd65vbSSVsKdjGvYXBuE4oWe2QOEoFeRmJg+lPuZxpmrfFclNhoRMneQ=="],
631+
568632 "fdir": ["fdir@6.5.0", "", { "peerDependencies": { "picomatch": "^3 || ^4" }, "optionalPeers": ["picomatch"] }, "sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg=="],
569633
634+ "fill-range": ["fill-range@7.1.1", "", { "dependencies": { "to-regex-range": "^5.0.1" } }, "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg=="],
635+
570636 "finalhandler": ["finalhandler@2.1.1", "", { "dependencies": { "debug": "^4.4.0", "encodeurl": "^2.0.0", "escape-html": "^1.0.3", "on-finished": "^2.4.1", "parseurl": "^1.3.3", "statuses": "^2.0.1" } }, "sha512-S8KoZgRZN+a5rNwqTxlZZePjT/4cnm0ROV70LedRHZ0p8u9fRID0hJUZQpkKLzro8LfmC8sx23bY6tVNxv8pQA=="],
571637
572638 "find-my-way-ts": ["find-my-way-ts@0.1.6", "", {}, "sha512-a85L9ZoXtNAey3Y6Z+eBWW658kO/MwR7zIafkIUPUMf3isZG0NCs2pjW2wtjxAKuJPxMAsHUIP4ZPGv0o5gyTA=="],
573639
640+ "formatly": ["formatly@0.3.0", "", { "dependencies": { "fd-package-json": "^2.0.0" }, "bin": { "formatly": "bin/index.mjs" } }, "sha512-9XNj/o4wrRFyhSMJOvsuyMwy8aUfBaZ1VrqHVfohyXf0Sw0e+yfKG+xZaY3arGCOMdwFsqObtzVOc1gU9KiT9w=="],
641+
574642 "forwarded": ["forwarded@0.2.0", "", {}, "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow=="],
575643
576644 "fresh": ["fresh@2.0.0", "", {}, "sha512-Rx/WycZ60HOaqLKAi6cHRKKI7zxWbJ31MhntmtwMoaTeF7XFH9hhBp8vITaMidfljRQ6eYWCKkaTK+ykVJHP2A=="],
@@ -583,6 +651,8 @@ · 6 unmodified lines
583651
584652 "get-proto": ["get-proto@1.0.1", "", { "dependencies": { "dunder-proto": "^1.0.1", "es-object-atoms": "^1.0.0" } }, "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g=="],
585653
654+ "glob-parent": ["glob-parent@5.1.2", "", { "dependencies": { "is-glob": "^4.0.1" } }, "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow=="],
655+
586656 "gopd": ["gopd@1.2.0", "", {}, "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg=="],
587657
588658 "has-symbols": ["has-symbols@1.1.0", "", {}, "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ=="],
@@ -617,6 +687,8 @@ · 28 unmodified lines
617687
618688 "is-inside-container": ["is-inside-container@1.0.0", "", { "dependencies": { "is-docker": "^3.0.0" }, "bin": { "is-inside-container": "cli.js" } }, "sha512-KIYLCCJghfHZxqjYBE7rEy0OBuTd5xCHS7tHVgvCLkx7StIoaxwNW3hCALgEUjFfeRk+MG/Qxmp/vtETEF3tRA=="],
619689
690+ "is-number": ["is-number@7.0.0", "", {}, "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng=="],
691+
620692 "is-promise": ["is-promise@4.0.0", "", {}, "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ=="],
621693
622694 "is-wsl": ["is-wsl@3.1.1", "", { "dependencies": { "is-inside-container": "^1.0.0" } }, "sha512-e6rvdUCiQCAuumZslxRJWR/Doq4VpPR82kqclvcS0efgt430SlGIk05vdCN58+VrzgtIcfNODjozVielycD4Sw=="],
@@ -631,6 +703,8 @@ · 8 unmodified lines
631703
632704 "js-tokens": ["js-tokens@9.0.1", "", {}, "sha512-mxa9E9ITFOt0ban3j6L5MpjwegGz6lBQmM1IJkWeBZGcMxto50+eWdjC/52xDbS2vy0k7vIMK0Fe2wfL9OQSpQ=="],
633705
706+ "js-yaml": ["js-yaml@4.1.1", "", { "dependencies": { "argparse": "^2.0.1" }, "bin": { "js-yaml": "bin/js-yaml.js" } }, "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA=="],
707+
634708 "jsbi": ["jsbi@4.3.2", "", {}, "sha512-9fqMSQbhJykSeii05nxKl4m6Eqn2P6rOlYiS+C5Dr/HPIU/7yZxu5qzbs40tgaFORiw2Amd0mirjxatXYMkIew=="],
635709
636710 "json-schema": ["json-schema@0.4.0", "", {}, "sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA=="],
@@ -645,6 +719,8 @@ · 8 unmodified lines
645719
646720 "jws": ["jws@4.0.1", "", { "dependencies": { "jwa": "^2.0.1", "safe-buffer": "^5.0.1" } }, "sha512-EKI/M/yqPncGUUh44xz0PxSidXFr/+r0pA70+gIYhjv+et7yxM+s29Y+VGDkovRofQem0fs7Uvf4+YmAdyRduA=="],
647721
722+ "knip": ["knip@5.85.0", "", { "dependencies": { "@nodelib/fs.walk": "^1.2.3", "fast-glob": "^3.3.3", "formatly": "^0.3.0", "jiti": "^2.6.0", "js-yaml": "^4.1.1", "minimist": "^1.2.8", "oxc-resolver": "^11.15.0", "picocolors": "^1.1.1", "picomatch": "^4.0.1", "smol-toml": "^1.5.2", "strip-json-comments": "5.0.3", "zod": "^4.1.11" }, "peerDependencies": { "@types/node": ">=18", "typescript": ">=5.0.4 <7" }, "bin": { "knip": "bin/knip.js", "knip-bun": "bin/knip-bun.js" } }, "sha512-V2kyON+DZiYdNNdY6GALseiNCwX7dYdpz9Pv85AUn69Gk0UKCts+glOKWfe5KmaMByRjM9q17Mzj/KinTVOyxg=="],
723+
648724 "kubernetes-types": ["kubernetes-types@1.30.0", "", {}, "sha512-Dew1okvhM/SQcIa2rcgujNndZwU8VnSapDgdxlYoB84ZlpAD43U6KLAFqYo17ykSFGHNPrg0qry0bP+GJd9v7Q=="],
649725
650726 "lodash.includes": ["lodash.includes@4.3.0", "", {}, "sha512-W3Bx6mdkRTGtlJISOvVD/lbqjTlPPUDTMnlXZFnVwi9NKJ6tiAk6LVdlhZMm17VZisqhKcgzpO5Wz91PCt5b0w=="],
@@ -671,12 +747,18 @@ · 20 unmodified lines
671747
672748 "merge-descriptors": ["merge-descriptors@2.0.0", "", {}, "sha512-Snk314V5ayFLhp3fkUREub6WtjBfPdCPY1Ln8/8munuLuiYhsABgBVWsozAG+MWMbVEvcdcpbi9R7ww22l9Q3g=="],
673749
750+ "merge2": ["merge2@1.4.1", "", {}, "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg=="],
751+
752+ "micromatch": ["micromatch@4.0.8", "", { "dependencies": { "braces": "^3.0.3", "picomatch": "^2.3.1" } }, "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA=="],
753+
674754 "mime": ["mime@3.0.0", "", { "bin": { "mime": "cli.js" } }, "sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A=="],
675755
676756 "mime-db": ["mime-db@1.54.0", "", {}, "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ=="],
677757
678758 "mime-types": ["mime-types@3.0.2", "", { "dependencies": { "mime-db": "^1.54.0" } }, "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A=="],
679759
760+ "minimist": ["minimist@1.2.8", "", {}, "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA=="],
761+
680762 "ms": ["ms@2.1.3", "", {}, "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA=="],
681763
682764 "msgpackr": ["msgpackr@1.11.8", "", { "optionalDependencies": { "msgpackr-extract": "^3.0.2" } }, "sha512-bC4UGzHhVvgDNS7kn9tV8fAucIYUBuGojcaLiz7v+P63Lmtm0Xeji8B/8tYKddALXxJLpwIeBmUN3u64C4YkRA=="],
@@ -707,6 +789,8 @@ · 24 unmodified lines
707789
708790 "open": ["open@10.2.0", "", { "dependencies": { "default-browser": "^5.2.1", "define-lazy-prop": "^3.0.0", "is-inside-container": "^1.0.0", "wsl-utils": "^0.1.0" } }, "sha512-YgBpdJHPyQ2UE5x+hlSXcnejzAvD0b22U2OuAP+8OnlJT+PjWPxtgmGqKKc+RgTM63U9gN0YzrYc71R2WT/hTA=="],
709791
792+ "oxc-resolver": ["oxc-resolver@11.19.1", "", { "optionalDependencies": { "@oxc-resolver/binding-android-arm-eabi": "11.19.1", "@oxc-resolver/binding-android-arm64": "11.19.1", "@oxc-resolver/binding-darwin-arm64": "11.19.1", "@oxc-resolver/binding-darwin-x64": "11.19.1", "@oxc-resolver/binding-freebsd-x64": "11.19.1", "@oxc-resolver/binding-linux-arm-gnueabihf": "11.19.1", "@oxc-resolver/binding-linux-arm-musleabihf": "11.19.1", "@oxc-resolver/binding-linux-arm64-gnu": "11.19.1", "@oxc-resolver/binding-linux-arm64-musl": "11.19.1", "@oxc-resolver/binding-linux-ppc64-gnu": "11.19.1", "@oxc-resolver/binding-linux-riscv64-gnu": "11.19.1", "@oxc-resolver/binding-linux-riscv64-musl": "11.19.1", "@oxc-resolver/binding-linux-s390x-gnu": "11.19.1", "@oxc-resolver/binding-linux-x64-gnu": "11.19.1", "@oxc-resolver/binding-linux-x64-musl": "11.19.1", "@oxc-resolver/binding-openharmony-arm64": "11.19.1", "@oxc-resolver/binding-wasm32-wasi": "11.19.1", "@oxc-resolver/binding-win32-arm64-msvc": "11.19.1", "@oxc-resolver/binding-win32-ia32-msvc": "11.19.1", "@oxc-resolver/binding-win32-x64-msvc": "11.19.1" } }, "sha512-qE/CIg/spwrTBFt5aKmwe3ifeDdLfA2NESN30E42X/lII5ClF8V7Wt6WIJhcGZjp0/Q+nQ+9vgxGk//xZNX2hg=="],
793+
710794 "parseurl": ["parseurl@1.3.3", "", {}, "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ=="],
711795
712796 "path-key": ["path-key@3.1.1", "", {}, "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q=="],
@@ -735,6 +819,8 @@ · 22 unmodified lines
735819
736820 "qs": ["qs@6.15.0", "", { "dependencies": { "side-channel": "^1.1.0" } }, "sha512-mAZTtNCeetKMH+pSjrb76NAM8V9a05I9aBZOHztWy/UqcJdQYNsf59vrRKWnojAT9Y+GbIvoTBC++CPHqpDBhQ=="],
737821
822+ "queue-microtask": ["queue-microtask@1.2.3", "", {}, "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A=="],
823+
738824 "range-parser": ["range-parser@1.2.1", "", {}, "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg=="],
739825
740826 "raw-body": ["raw-body@3.0.2", "", { "dependencies": { "bytes": "~3.1.2", "http-errors": "~2.0.1", "iconv-lite": "~0.7.0", "unpipe": "~1.0.0" } }, "sha512-K5zQjDllxWkf7Z5xJdV0/B0WTNqx6vxG70zJE4N0kBs4LovmEYWJzQGxC9bS9RAKu3bgM40lrd5zoLJ12MQ5BA=="],
@@ -743,6 +829,8 @@ · 2 unmodified lines
743829
744830 "require-from-string": ["require-from-string@2.0.2", "", {}, "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw=="],
745831
832+ "reusify": ["reusify@1.1.0", "", {}, "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw=="],
833+
746834 "rfdc": ["rfdc@1.4.1", "", {}, "sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA=="],
747835
748836 "rollup": ["rollup@4.59.0", "", { "dependencies": { "@types/estree": "1.0.8" }, "optionalDependencies": { "@rollup/rollup-android-arm-eabi": "4.59.0", "@rollup/rollup-android-arm64": "4.59.0", "@rollup/rollup-darwin-arm64": "4.59.0", "@rollup/rollup-darwin-x64": "4.59.0", "@rollup/rollup-freebsd-arm64": "4.59.0", "@rollup/rollup-freebsd-x64": "4.59.0", "@rollup/rollup-linux-arm-gnueabihf": "4.59.0", "@rollup/rollup-linux-arm-musleabihf": "4.59.0", "@rollup/rollup-linux-arm64-gnu": "4.59.0", "@rollup/rollup-linux-arm64-musl": "4.59.0", "@rollup/rollup-linux-loong64-gnu": "4.59.0", "@rollup/rollup-linux-loong64-musl": "4.59.0", "@rollup/rollup-linux-ppc64-gnu": "4.59.0", "@rollup/rollup-linux-ppc64-musl": "4.59.0", "@rollup/rollup-linux-riscv64-gnu": "4.59.0", "@rollup/rollup-linux-riscv64-musl": "4.59.0", "@rollup/rollup-linux-s390x-gnu": "4.59.0", "@rollup/rollup-linux-x64-gnu": "4.59.0", "@rollup/rollup-linux-x64-musl": "4.59.0", "@rollup/rollup-openbsd-x64": "4.59.0", "@rollup/rollup-openharmony-arm64": "4.59.0", "@rollup/rollup-win32-arm64-msvc": "4.59.0", "@rollup/rollup-win32-ia32-msvc": "4.59.0", "@rollup/rollup-win32-x64-gnu": "4.59.0", "@rollup/rollup-win32-x64-msvc": "4.59.0", "fsevents": "~2.3.2" }, "bin": { "rollup": "dist/bin/rollup" } }, "sha512-2oMpl67a3zCH9H79LeMcbDhXW/UmWG/y2zuqnF2jQq5uq9TbM9TVyXvA4+t+ne2IIkBdrLpAaRQAvo7YI/Yyeg=="],
@@ -751,6 +839,8 @@ · 2 unmodified lines
751839
752840 "run-applescript": ["run-applescript@7.1.0", "", {}, "sha512-DPe5pVFaAsinSaV6QjQ6gdiedWDcRCbUuiQfQa2wmWV7+xC9bGulGI8+TdRmoFkAPaBXk8CrAbnlY2ISniJ47Q=="],
753841
842+ "run-parallel": ["run-parallel@1.2.0", "", { "dependencies": { "queue-microtask": "^1.2.2" } }, "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA=="],
843+
754844 "safe-buffer": ["safe-buffer@5.2.1", "", {}, "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ=="],
755845
756846 "safer-buffer": ["safer-buffer@2.1.2", "", {}, "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="],
@@ -777,6 +867,8 @@ · 20 unmodified lines
777867
778868 "siginfo": ["siginfo@2.0.0", "", {}, "sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g=="],
779869
870+ "smol-toml": ["smol-toml@1.6.0", "", {}, "sha512-4zemZi0HvTnYwLfrpk/CF9LOd9Lt87kAt50GnqhMpyF9U3poDAP2+iukq2bZsO/ufegbYehBkqINbsWxj4l4cw=="],
871+
780872 "source-map-js": ["source-map-js@1.2.1", "", {}, "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA=="],
781873
782874 "sprintf-js": ["sprintf-js@1.1.3", "", {}, "sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA=="],
@@ -789,6 +881,8 @@ · 6 unmodified lines
789881
790882 "string_decoder": ["string_decoder@1.3.0", "", { "dependencies": { "safe-buffer": "~5.2.0" } }, "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA=="],
791883
884+ "strip-json-comments": ["strip-json-comments@5.0.3", "", {}, "sha512-1tB5mhVo7U+ETBKNf92xT4hrQa3pm0MZ0PQvuDnWgAAGHDsfp4lPSpiS6psrSiet87wyGPh9ft6wmhOMQ0hDiw=="],
885+
792886 "strip-literal": ["strip-literal@3.1.0", "", { "dependencies": { "js-tokens": "^9.0.1" } }, "sha512-8r3mkIM/2+PpjHoOtiAW8Rg3jJLHaV7xPwG+YRGrv6FP0wwk/toTpATxWYOW0BKdWwl82VT2tFYi5DlROa0Mxg=="],
793887
794888 "tarn": ["tarn@3.0.2", "", {}, "sha512-51LAVKUSZSVfI05vjPESNc5vwqqZpbXCsU+/+wxlOrUjk2SnFTt97v9ZgQrD4YmxYW1Px6w2KjaDitCfkvgxMQ=="],
@@ -807,6 +901,8 @@ · 12 unmodified lines
807901
808902 "tinyspy": ["tinyspy@4.0.4", "", {}, "sha512-azl+t0z7pw/z958Gy9svOTuzqIk6xq+NSheJzn5MMWtWTFywIacg2wUlzKFGtt3cthx0r2SxMK0yzJOR0IES7Q=="],
809903
904+ "to-regex-range": ["to-regex-range@5.0.1", "", { "dependencies": { "is-number": "^7.0.0" } }, "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ=="],
905+
810906 "toidentifier": ["toidentifier@1.0.1", "", {}, "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA=="],
811907
812908 "toml": ["toml@3.0.0", "", {}, "sha512-y/mWCZinnvxjTKYhJ+pYxwD0mRLVvOtdS2Awbgxln6iEnt4rk0yBxeSBHkGJcPucRiG0e55mwWp+g/05rsrd6w=="],
@@ -833,6 +929,8 @@ · 20 unmodified lines
833929
834930 "vitest": ["vitest@3.2.4", "", { "dependencies": { "@types/chai": "^5.2.2", "@vitest/expect": "3.2.4", "@vitest/mocker": "3.2.4", "@vitest/pretty-format": "^3.2.4", "@vitest/runner": "3.2.4", "@vitest/snapshot": "3.2.4", "@vitest/spy": "3.2.4", "@vitest/utils": "3.2.4", "chai": "^5.2.0", "debug": "^4.4.1", "expect-type": "^1.2.1", "magic-string": "^0.30.17", "pathe": "^2.0.3", "picomatch": "^4.0.2", "std-env": "^3.9.0", "tinybench": "^2.9.0", "tinyexec": "^0.3.2", "tinyglobby": "^0.2.14", "tinypool": "^1.1.1", "tinyrainbow": "^2.0.0", "vite": "^5.0.0 || ^6.0.0 || ^7.0.0-0", "vite-node": "3.2.4", "why-is-node-running": "^2.3.0" }, "peerDependencies": { "@edge-runtime/vm": "*", "@types/debug": "^4.1.12", "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", "@vitest/browser": "3.2.4", "@vitest/ui": "3.2.4", "happy-dom": "*", "jsdom": "*" }, "optionalPeers": ["@edge-runtime/vm", "@types/debug", "@types/node", "@vitest/browser", "@vitest/ui", "happy-dom", "jsdom"], "bin": { "vitest": "vitest.mjs" } }, "sha512-LUCP5ev3GURDysTWiP47wRRUpLKMOfPh+yKTx3kVIEiu5KOMeqzpnYNsKyOoVrULivR8tLcks4+lga33Whn90A=="],
835931
932+ "walk-up-path": ["walk-up-path@4.0.0", "", {}, "sha512-3hu+tD8YzSLGuFYtPRb48vdhKMi0KQV5sn+uWr8+7dMEq/2G/dtLrdDinkLjqq5TIbIBjYJ4Ax/n3YiaW7QM8A=="],
933+
836934 "which": ["which@2.0.2", "", { "dependencies": { "isexe": "^2.0.0" }, "bin": { "node-which": "./bin/node-which" } }, "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA=="],
837935
838936 "why-is-node-running": ["why-is-node-running@2.3.0", "", { "dependencies": { "siginfo": "^2.0.0", "stackback": "0.0.2" }, "bin": { "why-is-node-running": "cli.js" } }, "sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w=="],
@@ -851,6 +949,8 @@ · 12 unmodified lines
851949
852950 "@azure/msal-node/uuid": ["uuid@8.3.2", "", { "bin": { "uuid": "dist/bin/uuid" } }, "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg=="],
853951
952+ "micromatch/picomatch": ["picomatch@2.3.1", "", {}, "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA=="],
953+
854954 "tedious/iconv-lite": ["iconv-lite@0.6.3", "", { "dependencies": { "safer-buffer": ">= 2.1.2 < 3.0.0" } }, "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw=="],
855955
856956 "vite/esbuild": ["esbuild@0.27.3", "", { "optionalDependencies": { "@esbuild/aix-ppc64": "0.27.3", "@esbuild/android-arm": "0.27.3", "@esbuild/android-arm64": "0.27.3", "@esbuild/android-x64": "0.27.3", "@esbuild/darwin-arm64": "0.27.3", "@esbuild/darwin-x64": "0.27.3", "@esbuild/freebsd-arm64": "0.27.3", "@esbuild/freebsd-x64": "0.27.3", "@esbuild/linux-arm": "0.27.3", "@esbuild/linux-arm64": "0.27.3", "@esbuild/linux-ia32": "0.27.3", "@esbuild/linux-loong64": "0.27.3", "@esbuild/linux-mips64el": "0.27.3", "@esbuild/linux-ppc64": "0.27.3", "@esbuild/linux-riscv64": "0.27.3", "@esbuild/linux-s390x": "0.27.3", "@esbuild/linux-x64": "0.27.3", "@esbuild/netbsd-arm64": "0.27.3", "@esbuild/netbsd-x64": "0.27.3", "@esbuild/openbsd-arm64": "0.27.3", "@esbuild/openbsd-x64": "0.27.3", "@esbuild/openharmony-arm64": "0.27.3", "@esbuild/sunos-x64": "0.27.3", "@esbuild/win32-arm64": "0.27.3", "@esbuild/win32-ia32": "0.27.3", "@esbuild/win32-x64": "0.27.3" }, "bin": { "esbuild": "bin/esbuild" } }, "sha512-8VwMnyGCONIs6cWue2IdpHxHnAjzxnw2Zr7MkVxB2vjmQ2ivqGFb4LEG3SMnv0Gb2F/G/2yA8zUaiL1gywDCCg=="],
knip.json+38−0
@@ -0,0 +1,38 @@
1+{
2+ "$schema": "https://unpkg.com/knip@5/schema.json",
3+ "exclude": [
4+ "duplicates"
5+ ],
6+ "ignoreIssues": {
7+ "packages/codemode-openapi/src/openapi-extractor-wasm/openapi_extractor.js": [
8+ "exports"
9+ ]
10+ },
11+ "workspaces": {
12+ ".": {
13+ "entry": [],
14+ "project": []
15+ },
16+ "apps/*": {
17+ "entry": [
18+ "src/index.ts",
19+ "src/main.ts",
20+ "src/server.ts",
21+ "src/cli/main.ts"
22+ ],
23+ "project": [
24+ "src/**/*.{js,mjs,cjs,jsx,ts,tsx,mts,cts}"
25+ ]
26+ },
27+ "packages/*": {
28+ "entry": [
29+ "src/index.ts",
30+ "src/main.ts",
31+ "src/playground.ts"
32+ ],
33+ "project": [
34+ "src/**/*.{js,mjs,cjs,jsx,ts,tsx,mts,cts}"
35+ ]
36+ }
37+ }
38+}
package.json+3−1
@@ -19,9 +19,11 @@ · 18 unmodified lines
1919 "zod": "^4.3.6"
2020 },
2121 "scripts": {
22− "typecheck": "bun run --filter='*' typecheck"
22+ "typecheck": "bun run --filter='*' typecheck",
23+ "knip": "knip"
2324 },
2425 "devDependencies": {
26+ "knip": "^5.85.0",
2527 "typescript": "^5.9.3"
2628 }
2729 }
packages/codemode-mcp/src/mcp-elicitation-bridge.ts+1−1
@@ -76,7 +76,7 @@ export const toMcpElicitationResponse = ( · 75 unmodified lines
7676 }
7777 : { action: response.action };
7878
79−export type McpClientWithElicitationHandler = {
79+type McpClientWithElicitationHandler = {
8080 setRequestHandler: (
8181 schema: typeof ElicitRequestSchema,
8282 handler: (request: { params: unknown }) => Promise<unknown>,
packages/control-plane/src/api/api.ts+0−50
@@ -8,56 +8,6 @@ import { PoliciesApi } from "./policies/api"; · 7 unmodified lines
88 import { SourcesApi } from "./sources/api";
99 import { WorkspacesApi } from "./workspaces/api";
1010
11−export {
12− ControlPlaneBadRequestError,
13− ControlPlaneForbiddenError,
14− ControlPlaneNotFoundError,
15− ControlPlaneStorageError,
16− ControlPlaneUnauthorizedError,
17−} from "./errors";
18−
19−export {
20− CreateExecutionPayloadSchema,
21− ResumeExecutionPayloadSchema,
22− type CreateExecutionPayload,
23− type ResumeExecutionPayload,
24−} from "./executions/api";
25−
26−export {
27− CreateOrganizationPayloadSchema,
28− UpdateOrganizationPayloadSchema,
29− type CreateOrganizationPayload,
30− type UpdateOrganizationPayload,
31−} from "./organizations/api";
32−
33−export {
34− CreateMembershipPayloadSchema,
35− UpdateMembershipPayloadSchema,
36− type CreateMembershipPayload,
37− type UpdateMembershipPayload,
38−} from "./memberships/api";
39−
40−export {
41− CreateWorkspacePayloadSchema,
42− UpdateWorkspacePayloadSchema,
43− type CreateWorkspacePayload,
44− type UpdateWorkspacePayload,
45−} from "./workspaces/api";
46−
47−export {
48− CreateSourcePayloadSchema,
49− UpdateSourcePayloadSchema,
50− type CreateSourcePayload,
51− type UpdateSourcePayload,
52−} from "./sources/api";
53−
54−export {
55− CreatePolicyPayloadSchema,
56− UpdatePolicyPayloadSchema,
57− type CreatePolicyPayload,
58− type UpdatePolicyPayload,
59−} from "./policies/api";
60−
6111 export class ControlPlaneApi extends HttpApi.make("controlPlane")
6212 .add(LocalApi)
6313 .add(OrganizationsApi)
packages/control-plane/src/api/executions/http.ts+4−4
@@ -16,7 +16,7 @@ import { · 15 unmodified lines
1616 ControlPlaneForbiddenError,
1717 ControlPlaneUnauthorizedError,
1818 } from "../errors";
19−import { ControlPlaneService } from "../service";
19+import { ControlPlaneExecutionsService } from "../service";
2020
2121 const toForbiddenError = (
2222 operation: string,
@@ -59,7 +59,7 @@ export const ControlPlaneExecutionsLive = HttpApiBuilder.group( · 36 unmodified lines
5959 handlers
6060 .handle("create", ({ path, payload }) =>
6161 Effect.gen(function* () {
62− const service = yield* ControlPlaneService;
62+ const service = yield* ControlPlaneExecutionsService;
6363 const actor = yield* resolveWorkspaceActor(path.workspaceId);
6464
6565 return yield* withPolicy(requireExecuteWorkspace(path.workspaceId))(
@@ -80,7 +80,7 @@ export const ControlPlaneExecutionsLive = HttpApiBuilder.group( · 14 unmodified lines
8080 )
8181 .handle("get", ({ path }) =>
8282 Effect.gen(function* () {
83− const service = yield* ControlPlaneService;
83+ const service = yield* ControlPlaneExecutionsService;
8484 const actor = yield* resolveWorkspaceActor(path.workspaceId);
8585
8686 return yield* withPolicy(requireExecuteWorkspace(path.workspaceId))(
@@ -100,7 +100,7 @@ export const ControlPlaneExecutionsLive = HttpApiBuilder.group( · 13 unmodified lines
100100 )
101101 .handle("resume", ({ path, payload }) =>
102102 Effect.gen(function* () {
103− const service = yield* ControlPlaneService;
103+ const service = yield* ControlPlaneExecutionsService;
104104 const actor = yield* resolveWorkspaceActor(path.workspaceId);
105105
106106 return yield* withPolicy(requireExecuteWorkspace(path.workspaceId))(
packages/control-plane/src/api/http.ts+2−2
@@ -11,7 +11,7 @@ import { ControlPlaneLocalLive } from "./local/http"; · 10 unmodified lines
1111 import { ControlPlaneMembershipsLive } from "./memberships/http";
1212 import { ControlPlaneOrganizationsLive } from "./organizations/http";
1313 import { ControlPlanePoliciesLive } from "./policies/http";
14−import { ControlPlaneService } from "./service";
14+import { type ControlPlaneApiServiceContext } from "./service";
1515 import { ControlPlaneSourcesLive } from "./sources/http";
1616 import { ControlPlaneWorkspacesLive } from "./workspaces/http";
1717
@@ -26,7 +26,7 @@ export const ControlPlaneApiLive = HttpApiBuilder.api(ControlPlaneApi).pipe( · 8 unmodified lines
2626 );
2727
2828 export const createControlPlaneApiLayer = <EService, EResolver>(
29− serviceLayer: Layer.Layer<ControlPlaneService, EService, never>,
29+ serviceLayer: Layer.Layer<ControlPlaneApiServiceContext, EService, never>,
3030 actorResolverLayer: Layer.Layer<ControlPlaneActorResolver, EResolver, never>,
3131 ) =>
3232 ControlPlaneApiLive.pipe(
packages/control-plane/src/api/index.ts+15−2
@@ -14,8 +14,21 @@ export { · 13 unmodified lines
1414 } from "./errors";
1515
1616 export {
17− ControlPlaneService,
18− type ControlPlaneServiceShape,
17+ ControlPlaneOrganizationsService,
18+ type ControlPlaneOrganizationsServiceShape,
19+ ControlPlaneMembershipsService,
20+ type ControlPlaneMembershipsServiceShape,
21+ ControlPlaneWorkspacesService,
22+ type ControlPlaneWorkspacesServiceShape,
23+ ControlPlaneSourcesService,
24+ type ControlPlaneSourcesServiceShape,
25+ ControlPlaneExecutionsService,
26+ type ControlPlaneExecutionsServiceShape,
27+ ControlPlaneLocalService,
28+ type ControlPlaneLocalServiceShape,
29+ ControlPlanePoliciesService,
30+ type ControlPlanePoliciesServiceShape,
31+ type ControlPlaneApiServiceContext,
1932 type CreateOrganizationInput,
2033 type UpdateOrganizationInput,
2134 type RemoveOrganizationInput,
packages/control-plane/src/api/local/http.ts+3−3
@@ -2,7 +2,7 @@ import { HttpApiBuilder, HttpServerRequest } from "@effect/platform"; · 1 unmodified line
22 import * as Effect from "effect/Effect";
33
44 import { ControlPlaneApi } from "../api";
5−import { ControlPlaneService } from "../service";
5+import { ControlPlaneLocalService } from "../service";
66
77 export const ControlPlaneLocalLive = HttpApiBuilder.group(
88 ControlPlaneApi,
@@ -11,13 +11,13 @@ export const ControlPlaneLocalLive = HttpApiBuilder.group( · 2 unmodified lines
1111 handlers
1212 .handle("installation", () =>
1313 Effect.gen(function* () {
14− const service = yield* ControlPlaneService;
14+ const service = yield* ControlPlaneLocalService;
1515 return yield* service.getLocalInstallation();
1616 }),
1717 )
1818 .handle("oauthCallback", () =>
1919 Effect.gen(function* () {
20− const service = yield* ControlPlaneService;
20+ const service = yield* ControlPlaneLocalService;
2121 const request = yield* HttpServerRequest.HttpServerRequest;
2222 const requestUrl = new URL(request.url, "http://127.0.0.1");
2323
packages/control-plane/src/api/memberships/http.ts+5−5
@@ -16,7 +16,7 @@ import { · 15 unmodified lines
1616 ControlPlaneForbiddenError,
1717 ControlPlaneUnauthorizedError,
1818 } from "../errors";
19−import { ControlPlaneService } from "../service";
19+import { ControlPlaneMembershipsService } from "../service";
2020
2121 const toForbiddenError = (
2222 operation: string,
@@ -63,7 +63,7 @@ export const ControlPlaneMembershipsLive = HttpApiBuilder.group( · 40 unmodified lines
6363 handlers
6464 .handle("list", ({ path }) =>
6565 Effect.gen(function* () {
66− const service = yield* ControlPlaneService;
66+ const service = yield* ControlPlaneMembershipsService;
6767 const actor = yield* resolveActor;
6868
6969 return yield* withPolicy(requireReadMemberships(path.organizationId))(
@@ -80,7 +80,7 @@ export const ControlPlaneMembershipsLive = HttpApiBuilder.group( · 10 unmodified lines
8080 )
8181 .handle("create", ({ path, payload }) =>
8282 Effect.gen(function* () {
83− const service = yield* ControlPlaneService;
83+ const service = yield* ControlPlaneMembershipsService;
8484 const actor = yield* resolveActor;
8585
8686 return yield* withPolicy(requireWriteMemberships(path.organizationId))(
@@ -97,7 +97,7 @@ export const ControlPlaneMembershipsLive = HttpApiBuilder.group( · 10 unmodified lines
9797 )
9898 .handle("update", ({ path, payload }) =>
9999 Effect.gen(function* () {
100− const service = yield* ControlPlaneService;
100+ const service = yield* ControlPlaneMembershipsService;
101101 const actor = yield* resolveActor;
102102
103103 return yield* withPolicy(requireWriteMemberships(path.organizationId))(
@@ -118,7 +118,7 @@ export const ControlPlaneMembershipsLive = HttpApiBuilder.group( · 14 unmodified lines
118118 )
119119 .handle("remove", ({ path }) =>
120120 Effect.gen(function* () {
121− const service = yield* ControlPlaneService;
121+ const service = yield* ControlPlaneMembershipsService;
122122 const actor = yield* resolveActor;
123123
124124 return yield* withPolicy(requireWriteMemberships(path.organizationId))(
packages/control-plane/src/api/organizations/http.ts+6−6
@@ -16,7 +16,7 @@ import { · 15 unmodified lines
1616 ControlPlaneForbiddenError,
1717 ControlPlaneUnauthorizedError,
1818 } from "../errors";
19−import { ControlPlaneService } from "../service";
19+import { ControlPlaneOrganizationsService } from "../service";
2020
2121 const toForbiddenError = (
2222 operation: string,
@@ -61,7 +61,7 @@ export const ControlPlaneOrganizationsLive = HttpApiBuilder.group( · 38 unmodified lines
6161 handlers
6262 .handle("list", () =>
6363 Effect.gen(function* () {
64− const service = yield* ControlPlaneService;
64+ const service = yield* ControlPlaneOrganizationsService;
6565 const actor = yield* resolveActor;
6666
6767 return yield* withPolicy(requireReadOrganizations)(
@@ -80,7 +80,7 @@ export const ControlPlaneOrganizationsLive = HttpApiBuilder.group( · 12 unmodified lines
8080 )
8181 .handle("create", ({ payload }) =>
8282 Effect.gen(function* () {
83− const service = yield* ControlPlaneService;
83+ const service = yield* ControlPlaneOrganizationsService;
8484 const actor = yield* resolveActor;
8585
8686 return yield* service.createOrganization({
@@ -95,7 +95,7 @@ export const ControlPlaneOrganizationsLive = HttpApiBuilder.group( · 8 unmodified lines
9595 )
9696 .handle("get", ({ path }) =>
9797 Effect.gen(function* () {
98− const service = yield* ControlPlaneService;
98+ const service = yield* ControlPlaneOrganizationsService;
9999 const actor = yield* resolveActor;
100100
101101 return yield* withPolicy(requireReadOrganizations)(
@@ -115,7 +115,7 @@ export const ControlPlaneOrganizationsLive = HttpApiBuilder.group( · 13 unmodified lines
115115 )
116116 .handle("update", ({ path, payload }) =>
117117 Effect.gen(function* () {
118− const service = yield* ControlPlaneService;
118+ const service = yield* ControlPlaneOrganizationsService;
119119 const actor = yield* resolveActor;
120120
121121 return yield* withPolicy(requireManageOrganizations(path.organizationId))(
@@ -135,7 +135,7 @@ export const ControlPlaneOrganizationsLive = HttpApiBuilder.group( · 13 unmodified lines
135135 )
136136 .handle("remove", ({ path }) =>
137137 Effect.gen(function* () {
138− const service = yield* ControlPlaneService;
138+ const service = yield* ControlPlaneOrganizationsService;
139139 const actor = yield* resolveActor;
140140
141141 return yield* withPolicy(requireManageOrganizations(path.organizationId))(
packages/control-plane/src/api/policies/http.ts+6−6
@@ -16,7 +16,7 @@ import { · 15 unmodified lines
1616 ControlPlaneForbiddenError,
1717 ControlPlaneUnauthorizedError,
1818 } from "../errors";
19−import { ControlPlaneService } from "../service";
19+import { ControlPlanePoliciesService } from "../service";
2020
2121 const toForbiddenError = (
2222 operation: string,
@@ -65,7 +65,7 @@ export const ControlPlanePoliciesLive = HttpApiBuilder.group( · 42 unmodified lines
6565 handlers
6666 .handle("list", ({ path }) =>
6767 Effect.gen(function* () {
68− const service = yield* ControlPlaneService;
68+ const service = yield* ControlPlanePoliciesService;
6969 const actor = yield* resolveWorkspaceActor(path.workspaceId);
7070
7171 return yield* withPolicy(requireReadPolicies(path.workspaceId))(
@@ -82,7 +82,7 @@ export const ControlPlanePoliciesLive = HttpApiBuilder.group( · 10 unmodified lines
8282 )
8383 .handle("create", ({ path, payload }) =>
8484 Effect.gen(function* () {
85− const service = yield* ControlPlaneService;
85+ const service = yield* ControlPlanePoliciesService;
8686 const actor = yield* resolveWorkspaceActor(path.workspaceId);
8787
8888 return yield* withPolicy(requireWritePolicies(path.workspaceId))(
@@ -99,7 +99,7 @@ export const ControlPlanePoliciesLive = HttpApiBuilder.group( · 10 unmodified lines
9999 )
100100 .handle("get", ({ path }) =>
101101 Effect.gen(function* () {
102− const service = yield* ControlPlaneService;
102+ const service = yield* ControlPlanePoliciesService;
103103 const actor = yield* resolveWorkspaceActor(path.workspaceId);
104104
105105 return yield* withPolicy(requireReadPolicies(path.workspaceId))(
@@ -119,7 +119,7 @@ export const ControlPlanePoliciesLive = HttpApiBuilder.group( · 13 unmodified lines
119119 )
120120 .handle("update", ({ path, payload }) =>
121121 Effect.gen(function* () {
122− const service = yield* ControlPlaneService;
122+ const service = yield* ControlPlanePoliciesService;
123123 const actor = yield* resolveWorkspaceActor(path.workspaceId);
124124
125125 return yield* withPolicy(requireWritePolicies(path.workspaceId))(
@@ -140,7 +140,7 @@ export const ControlPlanePoliciesLive = HttpApiBuilder.group( · 14 unmodified lines
140140 )
141141 .handle("remove", ({ path }) =>
142142 Effect.gen(function* () {
143− const service = yield* ControlPlaneService;
143+ const service = yield* ControlPlanePoliciesService;
144144 const actor = yield* resolveWorkspaceActor(path.workspaceId);
145145
146146 return yield* withPolicy(requireWritePolicies(path.workspaceId))(
packages/control-plane/src/api/service.ts+56−4
@@ -158,7 +158,7 @@ export type RemovePolicyInput = { · 157 unmodified lines
158158 policyId: PolicyId;
159159 };
160160
161−export type ControlPlaneServiceShape = {
161+export type ControlPlaneOrganizationsServiceShape = {
162162 listOrganizations: (input: {
163163 accountId: AccountId;
164164 }) => Effect.Effect<ReadonlyArray<Organization>, ControlPlaneStorageError>;
@@ -178,7 +178,9 @@ export type ControlPlaneServiceShape = { · 13 unmodified lines
178178 removeOrganization: (
179179 input: RemoveOrganizationInput,
180180 ) => Effect.Effect<{ removed: boolean }, ControlPlaneStorageError>;
181+};
181182
183+export type ControlPlaneMembershipsServiceShape = {
182184 listMemberships: (
183185 organizationId: OrganizationId,
184186 ) => Effect.Effect<
@@ -200,7 +202,9 @@ export type ControlPlaneServiceShape = { · 15 unmodified lines
200202 removeMembership: (
201203 input: RemoveMembershipInput,
202204 ) => Effect.Effect<{ removed: boolean }, ControlPlaneNotFoundError | ControlPlaneStorageError>;
205+};
203206
207+export type ControlPlaneWorkspacesServiceShape = {
204208 listWorkspaces: (
205209 organizationId: OrganizationId,
206210 ) => Effect.Effect<ReadonlyArray<Workspace>, ControlPlaneNotFoundError | ControlPlaneStorageError>;
@@ -222,7 +226,9 @@ export type ControlPlaneServiceShape = { · 15 unmodified lines
222226 removeWorkspace: (
223227 input: RemoveWorkspaceInput,
224228 ) => Effect.Effect<{ removed: boolean }, ControlPlaneStorageError>;
229+};
225230
231+export type ControlPlaneSourcesServiceShape = {
226232 listSources: (
227233 workspaceId: WorkspaceId,
228234 ) => Effect.Effect<ReadonlyArray<Source>, ControlPlaneStorageError>;
@@ -241,7 +247,9 @@ export type ControlPlaneServiceShape = { · 12 unmodified lines
241247 removeSource: (
242248 input: RemoveSourceInput,
243249 ) => Effect.Effect<{ removed: boolean }, ControlPlaneStorageError>;
250+};
244251
252+export type ControlPlaneExecutionsServiceShape = {
245253 createExecution: (
246254 input: CreateExecutionInput,
247255 ) => Effect.Effect<
@@ -257,7 +265,9 @@ export type ControlPlaneServiceShape = { · 9 unmodified lines
257265 ExecutionEnvelope,
258266 ControlPlaneBadRequestError | ControlPlaneNotFoundError | ControlPlaneStorageError
259267 >;
268+};
260269
270+export type ControlPlaneLocalServiceShape = {
261271 getLocalInstallation: () => Effect.Effect<
262272 LocalInstallation,
263273 ControlPlaneNotFoundError | ControlPlaneStorageError
@@ -265,7 +275,9 @@ export type ControlPlaneServiceShape = { · 1 unmodified line
265275 completeSourceAuthCallback: (
266276 input: CompleteSourceAuthCallbackInput,
267277 ) => Effect.Effect<Source, ControlPlaneBadRequestError | ControlPlaneNotFoundError | ControlPlaneStorageError>;
278+};
268279
280+export type ControlPlanePoliciesServiceShape = {
269281 listPolicies: (
270282 workspaceId: WorkspaceId,
271283 ) => Effect.Effect<ReadonlyArray<Policy>, ControlPlaneStorageError>;
@@ -286,6 +298,46 @@ export type ControlPlaneServiceShape = { · 14 unmodified lines
286298 ) => Effect.Effect<{ removed: boolean }, ControlPlaneStorageError>;
287299 };
288300
289−export class ControlPlaneService extends Context.Tag(
290− "#api/ControlPlaneService",
291−)<ControlPlaneService, ControlPlaneServiceShape>() {}
301+export class ControlPlaneOrganizationsService extends Context.Tag(
302+ "#api/ControlPlaneOrganizationsService",
303+)<ControlPlaneOrganizationsService, ControlPlaneOrganizationsServiceShape>() {
304+}
305+
306+export class ControlPlaneMembershipsService extends Context.Tag(
307+ "#api/ControlPlaneMembershipsService",
308+)<ControlPlaneMembershipsService, ControlPlaneMembershipsServiceShape>() {
309+}
310+
311+export class ControlPlaneWorkspacesService extends Context.Tag(
312+ "#api/ControlPlaneWorkspacesService",
313+)<ControlPlaneWorkspacesService, ControlPlaneWorkspacesServiceShape>() {
314+}
315+
316+export class ControlPlaneSourcesService extends Context.Tag(
317+ "#api/ControlPlaneSourcesService",
318+)<ControlPlaneSourcesService, ControlPlaneSourcesServiceShape>() {
319+}
320+
321+export class ControlPlaneExecutionsService extends Context.Tag(
322+ "#api/ControlPlaneExecutionsService",
323+)<ControlPlaneExecutionsService, ControlPlaneExecutionsServiceShape>() {
324+}
325+
326+export class ControlPlaneLocalService extends Context.Tag(
327+ "#api/ControlPlaneLocalService",
328+)<ControlPlaneLocalService, ControlPlaneLocalServiceShape>() {
329+}
330+
331+export class ControlPlanePoliciesService extends Context.Tag(
332+ "#api/ControlPlanePoliciesService",
333+)<ControlPlanePoliciesService, ControlPlanePoliciesServiceShape>() {
334+}
335+
336+export type ControlPlaneApiServiceContext =
337+ | ControlPlaneOrganizationsService
338+ | ControlPlaneMembershipsService
339+ | ControlPlaneWorkspacesService
340+ | ControlPlaneSourcesService
341+ | ControlPlaneExecutionsService
342+ | ControlPlaneLocalService
343+ | ControlPlanePoliciesService;
packages/control-plane/src/api/sources/http.ts+6−6
@@ -16,7 +16,7 @@ import { · 15 unmodified lines
1616 ControlPlaneForbiddenError,
1717 ControlPlaneUnauthorizedError,
1818 } from "../errors";
19−import { ControlPlaneService } from "../service";
19+import { ControlPlaneSourcesService } from "../service";
2020
2121 const toForbiddenError = (
2222 operation: string,
@@ -65,7 +65,7 @@ export const ControlPlaneSourcesLive = HttpApiBuilder.group( · 42 unmodified lines
6565 handlers
6666 .handle("list", ({ path }) =>
6767 Effect.gen(function* () {
68− const service = yield* ControlPlaneService;
68+ const service = yield* ControlPlaneSourcesService;
6969 const actor = yield* resolveWorkspaceActor(path.workspaceId);
7070
7171 return yield* withPolicy(requireReadSources(path.workspaceId))(
@@ -82,7 +82,7 @@ export const ControlPlaneSourcesLive = HttpApiBuilder.group( · 10 unmodified lines
8282 )
8383 .handle("create", ({ path, payload }) =>
8484 Effect.gen(function* () {
85− const service = yield* ControlPlaneService;
85+ const service = yield* ControlPlaneSourcesService;
8686 const actor = yield* resolveWorkspaceActor(path.workspaceId);
8787
8888 return yield* withPolicy(requireWriteSources(path.workspaceId))(
@@ -99,7 +99,7 @@ export const ControlPlaneSourcesLive = HttpApiBuilder.group( · 10 unmodified lines
9999 )
100100 .handle("get", ({ path }) =>
101101 Effect.gen(function* () {
102− const service = yield* ControlPlaneService;
102+ const service = yield* ControlPlaneSourcesService;
103103 const actor = yield* resolveWorkspaceActor(path.workspaceId);
104104
105105 return yield* withPolicy(requireReadSources(path.workspaceId))(
@@ -119,7 +119,7 @@ export const ControlPlaneSourcesLive = HttpApiBuilder.group( · 13 unmodified lines
119119 )
120120 .handle("update", ({ path, payload }) =>
121121 Effect.gen(function* () {
122− const service = yield* ControlPlaneService;
122+ const service = yield* ControlPlaneSourcesService;
123123 const actor = yield* resolveWorkspaceActor(path.workspaceId);
124124
125125 return yield* withPolicy(requireWriteSources(path.workspaceId))(
@@ -140,7 +140,7 @@ export const ControlPlaneSourcesLive = HttpApiBuilder.group( · 14 unmodified lines
140140 )
141141 .handle("remove", ({ path }) =>
142142 Effect.gen(function* () {
143− const service = yield* ControlPlaneService;
143+ const service = yield* ControlPlaneSourcesService;
144144 const actor = yield* resolveWorkspaceActor(path.workspaceId);
145145
146146 return yield* withPolicy(requireWriteSources(path.workspaceId))(
packages/control-plane/src/api/workspaces/http.ts+6−6
@@ -16,7 +16,7 @@ import { · 15 unmodified lines
1616 ControlPlaneForbiddenError,
1717 ControlPlaneUnauthorizedError,
1818 } from "../errors";
19−import { ControlPlaneService } from "../service";
19+import { ControlPlaneWorkspacesService } from "../service";
2020
2121 const toForbiddenError = (
2222 operation: string,
@@ -83,7 +83,7 @@ export const ControlPlaneWorkspacesLive = HttpApiBuilder.group( · 60 unmodified lines
8383 handlers
8484 .handle("list", ({ path }) =>
8585 Effect.gen(function* () {
86− const service = yield* ControlPlaneService;
86+ const service = yield* ControlPlaneWorkspacesService;
8787 const actor = yield* resolveActor;
8888
8989 return yield* withPolicy(
@@ -102,7 +102,7 @@ export const ControlPlaneWorkspacesLive = HttpApiBuilder.group( · 12 unmodified lines
102102 )
103103 .handle("create", ({ path, payload }) =>
104104 Effect.gen(function* () {
105− const service = yield* ControlPlaneService;
105+ const service = yield* ControlPlaneWorkspacesService;
106106 const actor = yield* resolveActor;
107107
108108 return yield* withPolicy(
@@ -125,7 +125,7 @@ export const ControlPlaneWorkspacesLive = HttpApiBuilder.group( · 16 unmodified lines
125125 )
126126 .handle("get", ({ path }) =>
127127 Effect.gen(function* () {
128− const service = yield* ControlPlaneService;
128+ const service = yield* ControlPlaneWorkspacesService;
129129 const actor = yield* resolveWorkspaceActor(path.workspaceId);
130130
131131 return yield* withPolicy(requireReadWorkspace(path.workspaceId))(
@@ -142,7 +142,7 @@ export const ControlPlaneWorkspacesLive = HttpApiBuilder.group( · 10 unmodified lines
142142 )
143143 .handle("update", ({ path, payload }) =>
144144 Effect.gen(function* () {
145− const service = yield* ControlPlaneService;
145+ const service = yield* ControlPlaneWorkspacesService;
146146 const actor = yield* resolveWorkspaceActor(path.workspaceId);
147147
148148 return yield* withPolicy(requireManageWorkspace(path.workspaceId))(
@@ -159,7 +159,7 @@ export const ControlPlaneWorkspacesLive = HttpApiBuilder.group( · 10 unmodified lines
159159 )
160160 .handle("remove", ({ path }) =>
161161 Effect.gen(function* () {
162− const service = yield* ControlPlaneService;
162+ const service = yield* ControlPlaneWorkspacesService;
163163 const actor = yield* resolveWorkspaceActor(path.workspaceId);
164164
165165 return yield* withPolicy(requireManageWorkspace(path.workspaceId))(
packages/control-plane/src/runtime/control-plane-runtime.test.ts+1−6
@@ -1,7 +1,7 @@
11 import { describe, expect, it } from "@effect/vitest";
22 import * as Effect from "effect/Effect";
33
4−import { WorkspaceIdSchema, type AccountId } from "#schema";
4+import type { AccountId } from "#schema";
55
66 import { createSqlControlPlaneRuntime } from "./index";
77 import { withControlPlaneClient } from "./test-http-client";
@@ -314,11 +314,6 @@ describe("control-plane-runtime", () => { · 306 unmodified lines
314314 );
315315 expect(deleteOrg.removed).toBe(true);
316316
317− const deletedWorkspaceLookup = yield* Effect.either(
318− runtime.service.getWorkspace(WorkspaceIdSchema.make(workspace.id)),
319− );
320− expect(deletedWorkspaceLookup._tag).toBe("Left");
321−
322317 const listStaleWorkspacesError = yield* expectLeft(
323318 withControlPlaneClient(
324319 { runtime, accountId: "acc_del" },
packages/control-plane/src/runtime/execution-service.ts+5−18
@@ -1,4 +1,4 @@
1−import type { ControlPlaneServiceShape } from "#api";
1+import type { ControlPlaneExecutionsServiceShape } from "#api";
22 import {
33 ControlPlaneBadRequestError,
44 ControlPlaneNotFoundError,
@@ -24,7 +24,6 @@ import { · 19 unmodified lines
2424 ResumeUnsupportedError,
2525 } from "./execution-state";
2626 import {
27− createLiveExecutionManager,
2827 type LiveExecutionManager,
2928 } from "./live-execution";
3029
@@ -107,13 +106,6 @@ const ElicitationResponseSchema = Schema.Struct({ · 76 unmodified lines
107106
108107 const decodeElicitationResponse = Schema.decodeUnknown(ElicitationResponseSchema);
109108
110−const defaultExecutionResolver: ResolveExecutionEnvironment = () =>
111− Effect.fail(
112− new Error("Execution environment resolver is not configured"),
113− );
114−
115−const defaultLiveExecutionManager = createLiveExecutionManager();
116−
117109 const withExecutionInvocationContext = (input: {
118110 executionId: Execution["id"];
119111 toolInvoker: ToolInvoker;
@@ -190,15 +182,10 @@ const fetchExecutionEnvelope = ( · 70 unmodified lines
190182
191183 export const createRuntimeExecutionsService = (
192184 rows: SqlControlPlaneRows,
193− executionResolver: ResolveExecutionEnvironment = defaultExecutionResolver,
194− liveExecutionManager: LiveExecutionManager = defaultLiveExecutionManager,
195−): Pick<
196− ControlPlaneServiceShape,
197− | "createExecution"
198− | "getExecution"
199− | "resumeExecution"
200−> => {
201− const createExecution: ControlPlaneServiceShape["createExecution"] = (
185+ executionResolver: ResolveExecutionEnvironment,
186+ liveExecutionManager: LiveExecutionManager,
187+): ControlPlaneExecutionsServiceShape => {
188+ const createExecution: ControlPlaneExecutionsServiceShape["createExecution"] = (
202189 { workspaceId, payload, createdByAccountId },
203190 ) =>
204191 Effect.gen(function* () {
packages/control-plane/src/runtime/index.ts+75−14
@@ -5,10 +5,23 @@ import * as Layer from "effect/Layer"; · 4 unmodified lines
55 import * as Scope from "effect/Scope";
66
77 import {
8+ type ControlPlaneApiServiceContext,
89 ControlPlaneActorResolver,
910 type ControlPlaneActorResolverShape,
10− ControlPlaneService,
11− type ControlPlaneServiceShape,
11+ ControlPlaneExecutionsService,
12+ type ControlPlaneExecutionsServiceShape,
13+ ControlPlaneLocalService,
14+ type ControlPlaneLocalServiceShape,
15+ ControlPlaneMembershipsService,
16+ type ControlPlaneMembershipsServiceShape,
17+ ControlPlaneOrganizationsService,
18+ type ControlPlaneOrganizationsServiceShape,
19+ ControlPlanePoliciesService,
20+ type ControlPlanePoliciesServiceShape,
21+ ControlPlaneSourcesService,
22+ type ControlPlaneSourcesServiceShape,
23+ ControlPlaneWorkspacesService,
24+ type ControlPlaneWorkspacesServiceShape,
1225 } from "#api";
1326 import {
1427 SqlControlPlanePersistenceLive,
@@ -39,8 +52,7 @@ import { · 24 unmodified lines
3952 type ResolveSecretMaterial,
4053 } from "./source-auth-service";
4154 import {
42− RuntimeControlPlaneServiceLive,
43− createRuntimeControlPlaneService,
55+ RuntimeControlPlaneApiServicesLive,
4456 } from "./services";
4557 import {
4658 RuntimeExecutionResolverLive,
@@ -49,7 +61,6 @@ import { · 2 unmodified lines
4961 export {
5062 ControlPlaneAuthHeaders,
5163 createHeaderActorResolver,
52− createRuntimeControlPlaneService,
5364 };
5465
5566 export * from "./execution-state";
@@ -85,6 +96,25 @@ const toLocalInstallationBootstrapError = ( · 29 unmodified lines
8596 const closeScope = (scope: Scope.CloseableScope) =>
8697 Scope.close(scope, Exit.void).pipe(Effect.orDie);
8798
99+const createRuntimeServicesLayer = (input: {
100+ organizationsService: ControlPlaneOrganizationsServiceShape;
101+ membershipsService: ControlPlaneMembershipsServiceShape;
102+ workspacesService: ControlPlaneWorkspacesServiceShape;
103+ sourcesService: ControlPlaneSourcesServiceShape;
104+ policiesService: ControlPlanePoliciesServiceShape;
105+ localService: ControlPlaneLocalServiceShape;
106+ executionsService: ControlPlaneExecutionsServiceShape;
107+}): Layer.Layer<ControlPlaneApiServiceContext, never, never> =>
108+ Layer.mergeAll(
109+ Layer.succeed(ControlPlaneOrganizationsService, input.organizationsService),
110+ Layer.succeed(ControlPlaneMembershipsService, input.membershipsService),
111+ Layer.succeed(ControlPlaneWorkspacesService, input.workspacesService),
112+ Layer.succeed(ControlPlaneSourcesService, input.sourcesService),
113+ Layer.succeed(ControlPlanePoliciesService, input.policiesService),
114+ Layer.succeed(ControlPlaneLocalService, input.localService),
115+ Layer.succeed(ControlPlaneExecutionsService, input.executionsService),
116+ );
117+
88118 export const createRuntimeControlPlaneLayer = (
89119 options: RuntimeControlPlaneOptions = {},
90120 ) => {
@@ -105,11 +135,12 @@ export const createRuntimeControlPlaneLayer = ( · 14 unmodified lines
105135 sourceAuthLayer,
106136 executionResolverLayer,
107137 );
138+ const apiServicesLayer = RuntimeControlPlaneApiServicesLive.pipe(
139+ Layer.provide(runtimeDependenciesLayer),
140+ );
108141
109142 return Layer.mergeAll(
110− RuntimeControlPlaneServiceLive.pipe(
111− Layer.provide(runtimeDependenciesLayer),
112− ),
143+ apiServicesLayer,
113144 RuntimeActorResolverLive(options.actorResolver),
114145 runtimeDependenciesLayer,
115146 );
@@ -118,15 +149,30 @@ export const createRuntimeControlPlaneLayer = ( · 2 unmodified lines
118149 export const createRuntimeControlPlane = (
119150 input: RuntimeControlPlaneInput,
120151 ): Effect.Effect<{
121− service: ControlPlaneServiceShape;
152+ serviceLayer: Layer.Layer<ControlPlaneApiServiceContext, never, never>;
122153 actorResolver: ControlPlaneActorResolverShape;
123154 }> =>
124155 Effect.gen(function* () {
125− const service = yield* ControlPlaneService;
126156 const actorResolver = yield* ControlPlaneActorResolver;
157+ const organizationsService = yield* ControlPlaneOrganizationsService;
158+ const membershipsService = yield* ControlPlaneMembershipsService;
159+ const workspacesService = yield* ControlPlaneWorkspacesService;
160+ const sourcesService = yield* ControlPlaneSourcesService;
161+ const policiesService = yield* ControlPlanePoliciesService;
162+ const localService = yield* ControlPlaneLocalService;
163+ const executionsService = yield* ControlPlaneExecutionsService;
164+ const serviceLayer = createRuntimeServicesLayer({
165+ organizationsService,
166+ membershipsService,
167+ workspacesService,
168+ sourcesService,
169+ policiesService,
170+ localService,
171+ executionsService,
172+ });
127173
128174 return {
129− service,
175+ serviceLayer,
130176 actorResolver,
131177 };
132178 }).pipe(
@@ -143,7 +189,7 @@ export const createRuntimeControlPlane = ( · 10 unmodified lines
143189 export type SqlControlPlaneRuntime = {
144190 persistence: SqlControlPlanePersistence;
145191 localInstallation: LocalInstallation;
146− service: ControlPlaneServiceShape;
192+ serviceLayer: Layer.Layer<ControlPlaneApiServiceContext, never, never>;
147193 actorResolver: ControlPlaneActorResolverShape;
148194 close: () => Promise<void>;
149195 };
@@ -171,8 +217,23 @@ export const createSqlControlPlaneRuntime = ( · 21 unmodified lines
171217 );
172218
173219 const persistence = Context.get(context, SqlControlPlanePersistenceService);
174− const service = Context.get(context, ControlPlaneService);
175220 const actorResolver = Context.get(context, ControlPlaneActorResolver);
221+ const organizationsService = Context.get(context, ControlPlaneOrganizationsService);
222+ const membershipsService = Context.get(context, ControlPlaneMembershipsService);
223+ const workspacesService = Context.get(context, ControlPlaneWorkspacesService);
224+ const sourcesService = Context.get(context, ControlPlaneSourcesService);
225+ const policiesService = Context.get(context, ControlPlanePoliciesService);
226+ const localService = Context.get(context, ControlPlaneLocalService);
227+ const executionsService = Context.get(context, ControlPlaneExecutionsService);
228+ const serviceLayer = createRuntimeServicesLayer({
229+ organizationsService,
230+ membershipsService,
231+ workspacesService,
232+ sourcesService,
233+ policiesService,
234+ localService,
235+ executionsService,
236+ });
176237
177238 const localInstallation = yield* getOrProvisionLocalInstallation(
178239 persistence.rows,
@@ -187,7 +248,7 @@ export const createSqlControlPlaneRuntime = ( · 8 unmodified lines
187248 return {
188249 persistence,
189250 localInstallation,
190− service,
251+ serviceLayer,
191252 actorResolver,
192253 close: () => Effect.runPromise(Scope.close(scope, Exit.void)),
193254 };
packages/control-plane/src/runtime/services.ts+71−86
@@ -1,6 +1,18 @@
11 import {
2− ControlPlaneService,
3− type ControlPlaneServiceShape,
2+ ControlPlaneExecutionsService,
3+ type ControlPlaneExecutionsServiceShape,
4+ ControlPlaneLocalService,
5+ type ControlPlaneLocalServiceShape,
6+ ControlPlaneMembershipsService,
7+ type ControlPlaneMembershipsServiceShape,
8+ ControlPlaneOrganizationsService,
9+ type ControlPlaneOrganizationsServiceShape,
10+ ControlPlanePoliciesService,
11+ type ControlPlanePoliciesServiceShape,
12+ ControlPlaneSourcesService,
13+ type ControlPlaneSourcesServiceShape,
14+ ControlPlaneWorkspacesService,
15+ type ControlPlaneWorkspacesServiceShape,
416 ControlPlaneBadRequestError,
517 ControlPlaneNotFoundError,
618 ControlPlaneStorageError,
@@ -30,10 +42,8 @@ import * as Effect from "effect/Effect"; · 23 unmodified lines
3042 import * as Layer from "effect/Layer";
3143 import * as Option from "effect/Option";
3244
33−import { type ResolveExecutionEnvironment } from "./execution-state";
3445 import {
3546 LiveExecutionManagerService,
36− type LiveExecutionManager,
3747 } from "./live-execution";
3848 import { createRuntimeExecutionsService } from "./execution-service";
3949 import { loadLocalInstallation } from "./local-installation";
@@ -204,14 +214,7 @@ const ensureOrganizationExists = ( · 164 unmodified lines
204214
205215 const createOrganizationsService = (
206216 rows: SqlControlPlaneRows,
207−): Pick<
208− ControlPlaneServiceShape,
209− | "listOrganizations"
210− | "createOrganization"
211− | "getOrganization"
212− | "updateOrganization"
213− | "removeOrganization"
214−> => ({
217+): ControlPlaneOrganizationsServiceShape => ({
215218 listOrganizations: ({ accountId }) =>
216219 Effect.gen(function* () {
217220 const memberships = yield* mapStorageError(
@@ -363,13 +366,7 @@ const createOrganizationsService = ( · 145 unmodified lines
363366
364367 const createMembershipsService = (
365368 rows: SqlControlPlaneRows,
366−): Pick<
367− ControlPlaneServiceShape,
368− | "listMemberships"
369− | "createMembership"
370− | "updateMembership"
371− | "removeMembership"
372−> => ({
369+): ControlPlaneMembershipsServiceShape => ({
373370 listMemberships: (organizationId) =>
374371 Effect.gen(function* () {
375372 yield* ensureOrganizationExists(rows, "memberships.list", organizationId);
@@ -485,14 +482,7 @@ const createMembershipsService = ( · 109 unmodified lines
485482
486483 const createWorkspacesService = (
487484 rows: SqlControlPlaneRows,
488−): Pick<
489− ControlPlaneServiceShape,
490− | "listWorkspaces"
491− | "createWorkspace"
492− | "getWorkspace"
493− | "updateWorkspace"
494− | "removeWorkspace"
495−> => ({
485+): ControlPlaneWorkspacesServiceShape => ({
496486 listWorkspaces: (organizationId) =>
497487 Effect.gen(function* () {
498488 yield* ensureOrganizationExists(rows, "workspaces.list", organizationId);
@@ -594,14 +584,7 @@ const createWorkspacesService = ( · 95 unmodified lines
594584
595585 const createSourcesService = (
596586 rows: SqlControlPlaneRows,
597−): Pick<
598− ControlPlaneServiceShape,
599− | "listSources"
600− | "createSource"
601− | "getSource"
602− | "updateSource"
603− | "removeSource"
604−> => ({
587+): ControlPlaneSourcesServiceShape => ({
605588 listSources: (workspaceId) =>
606589 Effect.gen(function* () {
607590 const sourceRecords = yield* mapStorageError(
@@ -833,14 +816,7 @@ const createSourcesService = ( · 225 unmodified lines
833816
834817 const createPoliciesService = (
835818 rows: SqlControlPlaneRows,
836−): Pick<
837− ControlPlaneServiceShape,
838− | "listPolicies"
839− | "createPolicy"
840− | "getPolicy"
841− | "updatePolicy"
842− | "removePolicy"
843−> => ({
819+): ControlPlanePoliciesServiceShape => ({
844820 listPolicies: (workspaceId) =>
845821 mapStorageError(
846822 "policies.list",
@@ -1003,8 +979,8 @@ const createPoliciesService = ( · 156 unmodified lines
1003979
1004980 const createLocalService = (
1005981 rows: SqlControlPlaneRows,
1006− sourceAuthService?: RuntimeSourceAuthService,
1007−): Pick<ControlPlaneServiceShape, "getLocalInstallation" | "completeSourceAuthCallback"> => ({
982+ sourceAuthService: RuntimeSourceAuthService,
983+): ControlPlaneLocalServiceShape => ({
1008984 getLocalInstallation: () =>
1009985 Effect.gen(function* () {
1010986 const installation = yield* loadLocalInstallation(rows).pipe(
@@ -1034,16 +1010,6 @@ const createLocalService = ( · 23 unmodified lines
10341010
10351011 completeSourceAuthCallback: (input) =>
10361012 Effect.gen(function* () {
1037− if (!sourceAuthService) {
1038− return yield* Effect.fail(
1039− badRequest(
1040− "local.oauth.callback",
1041− "Source auth callback handling is unavailable",
1042− "Runtime source auth service is not configured",
1043− ),
1044− );
1045− }
1046−
10471013 return yield* sourceAuthService.completeSourceAuthCallback(input).pipe(
10481014 Effect.mapError((error) =>
10491015 new ControlPlaneStorageError({
@@ -1056,43 +1022,62 @@ const createLocalService = ( · 6 unmodified lines
10561022 }),
10571023 });
10581024
1059−export const createRuntimeControlPlaneService = (
1060− rows: SqlControlPlaneRows,
1061− options: {
1062− executionResolver?: ResolveExecutionEnvironment;
1063− liveExecutionManager?: LiveExecutionManager;
1064− sourceAuthService?: RuntimeSourceAuthService;
1065− } = {},
1066−) => ({
1067− ...createLocalService(rows, options.sourceAuthService),
1068− ...createOrganizationsService(rows),
1069− ...createMembershipsService(rows),
1070− ...createWorkspacesService(rows),
1071− ...createSourcesService(rows),
1072− ...createPoliciesService(rows),
1073− ...createRuntimeExecutionsService(
1074− rows,
1075− options.executionResolver,
1076− options.liveExecutionManager,
1077− ),
1078−} satisfies ControlPlaneServiceShape);
1079−
1080−export type RuntimeControlPlaneService = ReturnType<
1081− typeof createRuntimeControlPlaneService
1082−>;
1083−
1084−export const RuntimeControlPlaneServiceLive = Layer.effect(
1085− ControlPlaneService,
1025+const RuntimeOrganizationsServiceLive = Layer.effect(
1026+ ControlPlaneOrganizationsService,
1027+ Effect.map(SqlControlPlaneRowsService, createOrganizationsService),
1028+);
1029+
1030+const RuntimeMembershipsServiceLive = Layer.effect(
1031+ ControlPlaneMembershipsService,
1032+ Effect.map(SqlControlPlaneRowsService, createMembershipsService),
1033+);
1034+
1035+const RuntimeWorkspacesServiceLive = Layer.effect(
1036+ ControlPlaneWorkspacesService,
1037+ Effect.map(SqlControlPlaneRowsService, createWorkspacesService),
1038+);
1039+
1040+const RuntimeSourcesServiceLive = Layer.effect(
1041+ ControlPlaneSourcesService,
1042+ Effect.map(SqlControlPlaneRowsService, createSourcesService),
1043+);
1044+
1045+const RuntimePoliciesServiceLive = Layer.effect(
1046+ ControlPlanePoliciesService,
1047+ Effect.map(SqlControlPlaneRowsService, createPoliciesService),
1048+);
1049+
1050+const RuntimeLocalServiceLive = Layer.effect(
1051+ ControlPlaneLocalService,
1052+ Effect.gen(function* () {
1053+ const rows = yield* SqlControlPlaneRowsService;
1054+ const sourceAuthService = yield* RuntimeSourceAuthServiceTag;
1055+
1056+ return createLocalService(rows, sourceAuthService);
1057+ }),
1058+);
1059+
1060+const RuntimeExecutionsServiceLive = Layer.effect(
1061+ ControlPlaneExecutionsService,
10861062 Effect.gen(function* () {
10871063 const rows = yield* SqlControlPlaneRowsService;
10881064 const executionResolver = yield* RuntimeExecutionResolverService;
10891065 const liveExecutionManager = yield* LiveExecutionManagerService;
1090− const sourceAuthService = yield* RuntimeSourceAuthServiceTag;
10911066
1092− return createRuntimeControlPlaneService(rows, {
1067+ return createRuntimeExecutionsService(
1068+ rows,
10931069 executionResolver,
10941070 liveExecutionManager,
1095− sourceAuthService,
1096− });
1071+ );
10971072 }),
10981073 );
1074+
1075+export const RuntimeControlPlaneApiServicesLive = Layer.mergeAll(
1076+ RuntimeOrganizationsServiceLive,
1077+ RuntimeMembershipsServiceLive,
1078+ RuntimeWorkspacesServiceLive,
1079+ RuntimeSourcesServiceLive,
1080+ RuntimePoliciesServiceLive,
1081+ RuntimeLocalServiceLive,
1082+ RuntimeExecutionsServiceLive,
1083+);
packages/control-plane/src/runtime/slug.ts+0−18
@@ -7,21 +7,3 @@ export const slugify = (value: string): string => · 6 unmodified lines
77 .replace(slugifyRegex, "-")
88 .replace(/^-+/, "")
99 .replace(/-+$/, "");
10−
11−export const ensureUniqueSlug = async (
12− base: string,
13− hasCollision: (candidate: string) => Promise<boolean>,
14−): Promise<string> => {
15− const normalizedBase = slugify(base);
16− const seed = normalizedBase.length > 0 ? normalizedBase : "item";
17−
18− let counter = 0;
19− while (true) {
20− const candidate = counter === 0 ? seed : `${seed}-${counter + 1}`;
21− if (!(await hasCollision(candidate))) {
22− return candidate;
23− }
24−
25− counter += 1;
26− }
27−};
packages/control-plane/src/runtime/test-http-client.ts+2−4
@@ -11,7 +11,6 @@ import * as Layer from "effect/Layer"; · 10 unmodified lines
1111 import {
1212 ControlPlaneActorResolver,
1313 ControlPlaneApi,
14− ControlPlaneService,
1514 createControlPlaneApiLayer,
1615 } from "#api";
1716
@@ -21,12 +20,11 @@ import { · 3 unmodified lines
2120 } from "./index";
2221
2322 const createClientLayer = (runtime: SqlControlPlaneRuntime) => {
24− const serviceLayer = Layer.succeed(ControlPlaneService, runtime.service);
2523 const actorResolverLayer = Layer.succeed(
2624 ControlPlaneActorResolver,
2725 runtime.actorResolver,
2826 );
29− const apiLayer = createControlPlaneApiLayer(serviceLayer, actorResolverLayer);
27+ const apiLayer = createControlPlaneApiLayer(runtime.serviceLayer, actorResolverLayer);
3028
3129 return HttpApiBuilder.serve().pipe(
3230 Layer.provide(apiLayer),
@@ -49,7 +47,7 @@ const createControlPlaneClient = (accountId?: string) => · 16 unmodified lines
4947 : undefined,
5048 });
5149
52−export type ControlPlaneClient = Effect.Effect.Success<
50+type ControlPlaneClient = Effect.Effect.Success<
5351 ReturnType<typeof createControlPlaneClient>
5452 >;
5553
packages/kitchen-sink/package.json+0−1
@@ -13,7 +13,6 @@ · 12 unmodified lines
1313 "@executor-v3/ai-sdk-adapter": "workspace:*",
1414 "@executor-v3/codemode-core": "workspace:*",
1515 "@executor-v3/codemode-openapi": "workspace:*",
16− "@executor-v3/control-plane": "workspace:*",
1716 "@executor-v3/runtime-local-inproc": "workspace:*",
1817 "effect": "catalog:"
1918 },