@harrylabsj/kiwi-merchant-cloud 0.12.5 → 0.12.7
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/app/a2a/access/workbuddy-address.d.ts +45 -0
- package/app/a2a/access/workbuddy-address.js +88 -0
- package/app/a2a/access/workbuddy-address.js.map +1 -0
- package/app/a2a/client/client.d.ts +6 -0
- package/app/a2a/client/client.js +27 -2
- package/app/a2a/client/client.js.map +1 -1
- package/app/a2a/client/types.d.ts +5 -0
- package/app/a2a/server/server.d.ts +5 -0
- package/app/a2a/server/server.js +10 -2
- package/app/a2a/server/server.js.map +1 -1
- package/app/buyer-core/a2a-knp.d.ts +18 -1
- package/app/buyer-core/a2a-knp.js +29 -5
- package/app/buyer-core/a2a-knp.js.map +1 -1
- package/app/buyer-core/a2a-negotiator.d.ts +4 -0
- package/app/buyer-core/a2a-negotiator.js +3 -0
- package/app/buyer-core/a2a-negotiator.js.map +1 -1
- package/app/buyer-core/a2a-quote-fetcher.d.ts +47 -0
- package/app/buyer-core/a2a-quote-fetcher.js +109 -11
- package/app/buyer-core/a2a-quote-fetcher.js.map +1 -1
- package/app/buyer-core/build-service.d.ts +7 -0
- package/app/buyer-core/build-service.js +67 -0
- package/app/buyer-core/build-service.js.map +1 -1
- package/app/buyer-core/merchant-index.js +3 -0
- package/app/buyer-core/merchant-index.js.map +1 -1
- package/app/buyer-core/protocol-recovery.js +7 -0
- package/app/buyer-core/protocol-recovery.js.map +1 -1
- package/app/buyer-core/service.d.ts +36 -1
- package/app/buyer-core/service.js +325 -33
- package/app/buyer-core/service.js.map +1 -1
- package/app/buyer-core/store.d.ts +23 -0
- package/app/buyer-core/store.js +71 -8
- package/app/buyer-core/store.js.map +1 -1
- package/app/cloud/access/workbuddy-share-link.d.ts +92 -0
- package/app/cloud/access/workbuddy-share-link.js +150 -0
- package/app/cloud/access/workbuddy-share-link.js.map +1 -0
- package/app/cloud/bootstrap.d.ts +13 -0
- package/app/cloud/bootstrap.js +60 -4
- package/app/cloud/bootstrap.js.map +1 -1
- package/app/cloud/catalog-client.d.ts +66 -0
- package/app/cloud/catalog-client.js +155 -0
- package/app/cloud/catalog-client.js.map +1 -1
- package/app/cloud/config.d.ts +32 -0
- package/app/cloud/config.js +79 -3
- package/app/cloud/config.js.map +1 -1
- package/app/cloud/connect-service.d.ts +68 -0
- package/app/cloud/connect-service.js +198 -0
- package/app/cloud/connect-service.js.map +1 -1
- package/app/cloud/http-router.d.ts +5 -0
- package/app/cloud/http-router.js +7 -0
- package/app/cloud/http-router.js.map +1 -1
- package/app/cloud/main.d.ts +69 -0
- package/app/cloud/main.js +285 -0
- package/app/cloud/main.js.map +1 -1
- package/app/cloud/owned-clock.d.ts +27 -0
- package/app/cloud/owned-clock.js +98 -0
- package/app/cloud/owned-clock.js.map +1 -0
- package/app/cloud/owned-runtime.d.ts +188 -0
- package/app/cloud/owned-runtime.js +1041 -0
- package/app/cloud/owned-runtime.js.map +1 -0
- package/app/cloud-sample/products.json +3 -3
- package/app/demo/demo-runner.js +6 -0
- package/app/demo/demo-runner.js.map +1 -1
- package/app/discovery/catalog-source/kiwi-record.d.ts +10 -0
- package/app/discovery/catalog-source/kiwi-record.js.map +1 -1
- package/app/discovery/catalog-source/merchant-access.d.ts +77 -0
- package/app/discovery/catalog-source/merchant-access.js +279 -0
- package/app/discovery/catalog-source/merchant-access.js.map +1 -0
- package/app/handoff/destination.d.ts +2 -0
- package/app/handoff/destination.js +4 -0
- package/app/handoff/destination.js.map +1 -1
- package/app/http/merchant-management/api.d.ts +21 -0
- package/app/http/merchant-management/api.js +79 -0
- package/app/http/merchant-management/api.js.map +1 -1
- package/app/http/merchant-management/page.js +81 -1
- package/app/http/merchant-management/page.js.map +1 -1
- package/app/tools/trusted-buyer-keys.d.ts +31 -0
- package/app/tools/trusted-buyer-keys.js +98 -0
- package/app/tools/trusted-buyer-keys.js.map +1 -0
- package/app/tools/workbuddy-echo.d.ts +69 -0
- package/app/tools/workbuddy-echo.js +132 -0
- package/app/tools/workbuddy-echo.js.map +1 -0
- package/build-manifest.json +42847 -41772
- package/contracts/kiwi-catalog/1.0/agent-record.schema.json +21 -0
- package/contracts/kiwi-contracts.lock.json +2 -2
- package/contracts/manifest.json +2 -2
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/README.md +356 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.d.ts +53 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.js +64 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/cloudflare.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.d.ts +43 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.js +320 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/declarations.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.d.ts +6 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.js +13 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/identifier.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.d.ts +11 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.js +10 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/index.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.d.ts +15 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.js +12 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/portable.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.d.ts +66 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.js +494 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/execution.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.d.ts +13 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.js +72 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/host.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.d.ts +63 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.js +80 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/inline.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.d.ts +45 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.js +520 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/prelude-source.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.d.ts +110 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.js +15 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/protocol.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.d.ts +102 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.js +175 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/remote.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.d.ts +24 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.js +293 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/vm.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.d.ts +2 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.js +38 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/runtime/worker.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.d.ts +36 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.js +98 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/source.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.d.ts +232 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.js +2 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/types.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.d.ts +12 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.d.ts.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.js +24 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/dist/wasm.js.map +1 -0
- package/node_modules/@earendil-works/pi-durable/node_modules/@earendil-works/pi-codemode/package.json +76 -0
- package/node_modules/body-parser/README.md +17 -13
- package/node_modules/body-parser/lib/read.js +74 -57
- package/node_modules/body-parser/lib/types/json.js +11 -11
- package/node_modules/body-parser/lib/types/urlencoded.js +5 -5
- package/node_modules/body-parser/lib/utils.js +0 -15
- package/node_modules/body-parser/package.json +7 -12
- package/node_modules/fast-uri/.github/workflows/release.yml +35 -0
- package/node_modules/fast-uri/README.md +8 -0
- package/node_modules/fast-uri/index.js +98 -18
- package/node_modules/fast-uri/lib/utils.js +52 -0
- package/node_modules/fast-uri/package.json +1 -1
- package/node_modules/fast-uri/test/host-delimiter-security.test.js +94 -0
- package/node_modules/fast-uri/test/relative-normalization-security.test.js +156 -0
- package/node_modules/fast-uri/test/reserved-path-normalization.test.js +32 -4
- package/node_modules/fast-uri/test/scheme-validation.test.js +53 -14
- package/node_modules/hono/README.md +1 -1
- package/node_modules/hono/dist/_virtual/_rolldown/runtime.js +13 -0
- package/node_modules/hono/dist/adapter/aws-lambda/conninfo.js +42 -23
- package/node_modules/hono/dist/adapter/aws-lambda/handler.js +320 -342
- package/node_modules/hono/dist/adapter/aws-lambda/index.js +2 -8
- package/node_modules/hono/dist/adapter/aws-lambda/types.js +1 -0
- package/node_modules/hono/dist/adapter/bun/conninfo.js +20 -25
- package/node_modules/hono/dist/adapter/bun/index.js +3 -13
- package/node_modules/hono/dist/adapter/bun/serve-static.js +27 -27
- package/node_modules/hono/dist/adapter/bun/server.js +11 -5
- package/node_modules/hono/dist/adapter/bun/ssg.js +25 -15
- package/node_modules/hono/dist/adapter/bun/websocket.js +61 -68
- package/node_modules/hono/dist/adapter/cloudflare-pages/conninfo.js +24 -9
- package/node_modules/hono/dist/adapter/cloudflare-pages/handler.js +59 -62
- package/node_modules/hono/dist/adapter/cloudflare-pages/index.js +2 -8
- package/node_modules/hono/dist/adapter/cloudflare-workers/conninfo.js +7 -9
- package/node_modules/hono/dist/adapter/cloudflare-workers/index.js +3 -8
- package/node_modules/hono/dist/adapter/cloudflare-workers/serve-static-module.js +5 -6
- package/node_modules/hono/dist/adapter/cloudflare-workers/serve-static.js +26 -20
- package/node_modules/hono/dist/adapter/cloudflare-workers/utils.js +21 -34
- package/node_modules/hono/dist/adapter/cloudflare-workers/websocket.js +31 -39
- package/node_modules/hono/dist/adapter/deno/conninfo.js +16 -13
- package/node_modules/hono/dist/adapter/deno/deno.d.js +1 -0
- package/node_modules/hono/dist/adapter/deno/index.js +3 -10
- package/node_modules/hono/dist/adapter/deno/serve-static.js +33 -38
- package/node_modules/hono/dist/adapter/deno/ssg.js +27 -16
- package/node_modules/hono/dist/adapter/deno/websocket.js +30 -30
- package/node_modules/hono/dist/adapter/lambda-edge/conninfo.js +7 -9
- package/node_modules/hono/dist/adapter/lambda-edge/handler.js +102 -87
- package/node_modules/hono/dist/adapter/lambda-edge/index.js +2 -6
- package/node_modules/hono/dist/adapter/netlify/conninfo.js +24 -9
- package/node_modules/hono/dist/adapter/netlify/handler.js +10 -8
- package/node_modules/hono/dist/adapter/netlify/index.js +3 -2
- package/node_modules/hono/dist/adapter/netlify/mod.js +2 -6
- package/node_modules/hono/dist/adapter/service-worker/handler.js +15 -19
- package/node_modules/hono/dist/adapter/service-worker/index.js +23 -7
- package/node_modules/hono/dist/adapter/service-worker/types.js +1 -0
- package/node_modules/hono/dist/adapter/vercel/conninfo.js +7 -10
- package/node_modules/hono/dist/adapter/vercel/handler.js +8 -6
- package/node_modules/hono/dist/adapter/vercel/index.js +2 -6
- package/node_modules/hono/dist/cjs/_virtual/_rolldown/runtime.js +33 -0
- package/node_modules/hono/dist/cjs/adapter/aws-lambda/conninfo.js +42 -44
- package/node_modules/hono/dist/cjs/adapter/aws-lambda/handler.js +328 -371
- package/node_modules/hono/dist/cjs/adapter/aws-lambda/index.js +7 -34
- package/node_modules/hono/dist/cjs/adapter/aws-lambda/types.js +0 -15
- package/node_modules/hono/dist/cjs/adapter/bun/conninfo.js +21 -47
- package/node_modules/hono/dist/cjs/adapter/bun/index.js +14 -45
- package/node_modules/hono/dist/cjs/adapter/bun/serve-static.js +29 -50
- package/node_modules/hono/dist/cjs/adapter/bun/server.js +11 -26
- package/node_modules/hono/dist/cjs/adapter/bun/ssg.js +24 -35
- package/node_modules/hono/dist/cjs/adapter/bun/websocket.js +63 -91
- package/node_modules/hono/dist/cjs/adapter/cloudflare-pages/conninfo.js +25 -31
- package/node_modules/hono/dist/cjs/adapter/cloudflare-pages/handler.js +61 -85
- package/node_modules/hono/dist/cjs/adapter/cloudflare-pages/index.js +7 -34
- package/node_modules/hono/dist/cjs/adapter/cloudflare-workers/conninfo.js +8 -31
- package/node_modules/hono/dist/cjs/adapter/cloudflare-workers/index.js +7 -33
- package/node_modules/hono/dist/cjs/adapter/cloudflare-workers/serve-static-module.js +7 -29
- package/node_modules/hono/dist/cjs/adapter/cloudflare-workers/serve-static.js +27 -42
- package/node_modules/hono/dist/cjs/adapter/cloudflare-workers/utils.js +21 -55
- package/node_modules/hono/dist/cjs/adapter/cloudflare-workers/websocket.js +33 -62
- package/node_modules/hono/dist/cjs/adapter/deno/conninfo.js +16 -34
- package/node_modules/hono/dist/cjs/adapter/deno/index.js +10 -38
- package/node_modules/hono/dist/cjs/adapter/deno/serve-static.js +33 -59
- package/node_modules/hono/dist/cjs/adapter/deno/ssg.js +27 -37
- package/node_modules/hono/dist/cjs/adapter/deno/websocket.js +32 -53
- package/node_modules/hono/dist/cjs/adapter/lambda-edge/conninfo.js +8 -31
- package/node_modules/hono/dist/cjs/adapter/lambda-edge/handler.js +105 -119
- package/node_modules/hono/dist/cjs/adapter/lambda-edge/index.js +5 -30
- package/node_modules/hono/dist/cjs/adapter/netlify/conninfo.js +25 -31
- package/node_modules/hono/dist/cjs/adapter/netlify/handler.js +10 -29
- package/node_modules/hono/dist/cjs/adapter/netlify/index.js +5 -21
- package/node_modules/hono/dist/cjs/adapter/netlify/mod.js +5 -30
- package/node_modules/hono/dist/cjs/adapter/service-worker/handler.js +16 -41
- package/node_modules/hono/dist/cjs/adapter/service-worker/index.js +25 -30
- package/node_modules/hono/dist/cjs/adapter/service-worker/types.js +0 -15
- package/node_modules/hono/dist/cjs/adapter/vercel/conninfo.js +8 -32
- package/node_modules/hono/dist/cjs/adapter/vercel/handler.js +8 -27
- package/node_modules/hono/dist/cjs/adapter/vercel/index.js +5 -30
- package/node_modules/hono/dist/cjs/client/client.js +139 -212
- package/node_modules/hono/dist/cjs/client/fetch-result-please.js +62 -80
- package/node_modules/hono/dist/cjs/client/index.js +7 -32
- package/node_modules/hono/dist/cjs/client/types.js +0 -15
- package/node_modules/hono/dist/cjs/client/utils.js +54 -92
- package/node_modules/hono/dist/cjs/compose.js +49 -66
- package/node_modules/hono/dist/cjs/context.js +379 -450
- package/node_modules/hono/dist/cjs/helper/accepts/accepts.js +47 -70
- package/node_modules/hono/dist/cjs/helper/accepts/index.js +3 -27
- package/node_modules/hono/dist/cjs/helper/adapter/index.js +33 -73
- package/node_modules/hono/dist/cjs/helper/conninfo/index.js +0 -15
- package/node_modules/hono/dist/cjs/helper/conninfo/types.js +0 -15
- package/node_modules/hono/dist/cjs/helper/cookie/index.js +75 -116
- package/node_modules/hono/dist/cjs/helper/css/common.js +165 -244
- package/node_modules/hono/dist/cjs/helper/css/index.js +136 -151
- package/node_modules/hono/dist/cjs/helper/dev/index.js +45 -71
- package/node_modules/hono/dist/cjs/helper/factory/index.js +30 -51
- package/node_modules/hono/dist/cjs/helper/html/index.js +32 -62
- package/node_modules/hono/dist/cjs/helper/proxy/index.js +113 -106
- package/node_modules/hono/dist/cjs/helper/route/index.js +123 -66
- package/node_modules/hono/dist/cjs/helper/ssg/index.js +19 -43
- package/node_modules/hono/dist/cjs/helper/ssg/middleware.js +56 -64
- package/node_modules/hono/dist/cjs/helper/ssg/plugins.js +55 -57
- package/node_modules/hono/dist/cjs/helper/ssg/ssg.js +196 -296
- package/node_modules/hono/dist/cjs/helper/ssg/utils.js +47 -90
- package/node_modules/hono/dist/cjs/helper/streaming/index.js +8 -35
- package/node_modules/hono/dist/cjs/helper/streaming/sse.js +53 -85
- package/node_modules/hono/dist/cjs/helper/streaming/stream.js +23 -53
- package/node_modules/hono/dist/cjs/helper/streaming/text.js +10 -32
- package/node_modules/hono/dist/cjs/helper/streaming/utils.js +13 -32
- package/node_modules/hono/dist/cjs/helper/testing/index.js +16 -31
- package/node_modules/hono/dist/cjs/helper/websocket/index.js +51 -76
- package/node_modules/hono/dist/cjs/hono-base.js +345 -403
- package/node_modules/hono/dist/cjs/hono.js +28 -42
- package/node_modules/hono/dist/cjs/http-exception.js +55 -56
- package/node_modules/hono/dist/cjs/index.js +22 -30
- package/node_modules/hono/dist/cjs/jsx/base.js +237 -366
- package/node_modules/hono/dist/cjs/jsx/children.js +16 -41
- package/node_modules/hono/dist/cjs/jsx/components.js +119 -192
- package/node_modules/hono/dist/cjs/jsx/constants.js +15 -42
- package/node_modules/hono/dist/cjs/jsx/context.js +144 -162
- package/node_modules/hono/dist/cjs/jsx/dom/client.js +49 -69
- package/node_modules/hono/dist/cjs/jsx/dom/components.js +23 -52
- package/node_modules/hono/dist/cjs/jsx/dom/context.js +39 -67
- package/node_modules/hono/dist/cjs/jsx/dom/css.js +143 -158
- package/node_modules/hono/dist/cjs/jsx/dom/hooks/index.js +55 -64
- package/node_modules/hono/dist/cjs/jsx/dom/index.js +114 -173
- package/node_modules/hono/dist/cjs/jsx/dom/intrinsic-element/components.js +282 -375
- package/node_modules/hono/dist/cjs/jsx/dom/jsx-dev-runtime.js +14 -49
- package/node_modules/hono/dist/cjs/jsx/dom/jsx-runtime.js +5 -32
- package/node_modules/hono/dist/cjs/jsx/dom/render.js +471 -589
- package/node_modules/hono/dist/cjs/jsx/dom/server.js +37 -64
- package/node_modules/hono/dist/cjs/jsx/dom/utils.js +7 -30
- package/node_modules/hono/dist/cjs/jsx/hooks/index.js +225 -318
- package/node_modules/hono/dist/cjs/jsx/index.js +86 -135
- package/node_modules/hono/dist/cjs/jsx/intrinsic-element/common.js +20 -43
- package/node_modules/hono/dist/cjs/jsx/intrinsic-element/components.js +117 -168
- package/node_modules/hono/dist/cjs/jsx/intrinsic-elements.js +0 -15
- package/node_modules/hono/dist/cjs/jsx/jsx-dev-runtime.js +14 -39
- package/node_modules/hono/dist/cjs/jsx/jsx-runtime.js +34 -68
- package/node_modules/hono/dist/cjs/jsx/streaming.js +123 -166
- package/node_modules/hono/dist/cjs/jsx/types.js +0 -15
- package/node_modules/hono/dist/cjs/jsx/utils.js +91 -175
- package/node_modules/hono/dist/cjs/middleware/basic-auth/index.js +98 -86
- package/node_modules/hono/dist/cjs/middleware/bearer-auth/index.js +92 -109
- package/node_modules/hono/dist/cjs/middleware/body-limit/index.js +66 -72
- package/node_modules/hono/dist/cjs/middleware/cache/index.js +153 -199
- package/node_modules/hono/dist/cjs/middleware/combine/index.js +133 -95
- package/node_modules/hono/dist/cjs/middleware/compress/index.js +73 -88
- package/node_modules/hono/dist/cjs/middleware/context-storage/index.js +49 -41
- package/node_modules/hono/dist/cjs/middleware/cors/index.js +107 -107
- package/node_modules/hono/dist/cjs/middleware/csrf/index.js +101 -72
- package/node_modules/hono/dist/cjs/middleware/etag/digest.js +58 -97
- package/node_modules/hono/dist/cjs/middleware/etag/index.js +71 -91
- package/node_modules/hono/dist/cjs/middleware/ip-restriction/index.js +161 -169
- package/node_modules/hono/dist/cjs/middleware/jsx-renderer/index.js +99 -77
- package/node_modules/hono/dist/cjs/middleware/jwk/index.js +3 -27
- package/node_modules/hono/dist/cjs/middleware/jwk/jwk.js +118 -135
- package/node_modules/hono/dist/cjs/middleware/jwt/index.js +9 -38
- package/node_modules/hono/dist/cjs/middleware/jwt/jwt.js +120 -141
- package/node_modules/hono/dist/cjs/middleware/language/index.js +7 -35
- package/node_modules/hono/dist/cjs/middleware/language/language.js +184 -179
- package/node_modules/hono/dist/cjs/middleware/logger/index.js +41 -62
- package/node_modules/hono/dist/cjs/middleware/method-not-allowed/index.js +82 -88
- package/node_modules/hono/dist/cjs/middleware/method-override/index.js +101 -102
- package/node_modules/hono/dist/cjs/middleware/powered-by/index.js +23 -30
- package/node_modules/hono/dist/cjs/middleware/pretty-json/index.js +38 -36
- package/node_modules/hono/dist/cjs/middleware/request-id/index.js +3 -27
- package/node_modules/hono/dist/cjs/middleware/request-id/request-id.js +34 -42
- package/node_modules/hono/dist/cjs/middleware/secure-headers/index.js +4 -29
- package/node_modules/hono/dist/cjs/middleware/secure-headers/permissions-policy.js +0 -15
- package/node_modules/hono/dist/cjs/middleware/secure-headers/secure-headers.js +142 -174
- package/node_modules/hono/dist/cjs/middleware/serve-static/index.js +56 -93
- package/node_modules/hono/dist/cjs/middleware/serve-static/path.js +15 -38
- package/node_modules/hono/dist/cjs/middleware/timeout/index.js +40 -45
- package/node_modules/hono/dist/cjs/middleware/timing/index.js +7 -35
- package/node_modules/hono/dist/cjs/middleware/timing/timing.js +177 -118
- package/node_modules/hono/dist/cjs/middleware/trailing-slash/index.js +85 -58
- package/node_modules/hono/dist/cjs/preset/quick.js +18 -37
- package/node_modules/hono/dist/cjs/preset/tiny.js +15 -33
- package/node_modules/hono/dist/cjs/request/constants.js +5 -27
- package/node_modules/hono/dist/cjs/request.js +334 -343
- package/node_modules/hono/dist/cjs/router/linear-router/index.js +3 -27
- package/node_modules/hono/dist/cjs/router/linear-router/router.js +95 -143
- package/node_modules/hono/dist/cjs/router/pattern-router/index.js +3 -27
- package/node_modules/hono/dist/cjs/router/pattern-router/router.js +41 -63
- package/node_modules/hono/dist/cjs/router/reg-exp-router/index.js +7 -34
- package/node_modules/hono/dist/cjs/router/reg-exp-router/matcher.js +18 -45
- package/node_modules/hono/dist/cjs/router/reg-exp-router/node.js +91 -135
- package/node_modules/hono/dist/cjs/router/reg-exp-router/prepared-router.js +92 -161
- package/node_modules/hono/dist/cjs/router/reg-exp-router/router.js +98 -147
- package/node_modules/hono/dist/cjs/router/reg-exp-router/trie.js +73 -89
- package/node_modules/hono/dist/cjs/router/smart-router/index.js +3 -27
- package/node_modules/hono/dist/cjs/router/smart-router/router.js +49 -79
- package/node_modules/hono/dist/cjs/router/trie-router/index.js +3 -27
- package/node_modules/hono/dist/cjs/router/trie-router/node.js +134 -186
- package/node_modules/hono/dist/cjs/router/trie-router/router.js +15 -39
- package/node_modules/hono/dist/cjs/router/utils.js +5 -27
- package/node_modules/hono/dist/cjs/router.js +37 -37
- package/node_modules/hono/dist/cjs/types.js +5 -28
- package/node_modules/hono/dist/cjs/utils/accept.js +177 -228
- package/node_modules/hono/dist/cjs/utils/basic-auth.js +16 -40
- package/node_modules/hono/dist/cjs/utils/body.js +84 -110
- package/node_modules/hono/dist/cjs/utils/buffer.js +43 -91
- package/node_modules/hono/dist/cjs/utils/color.js +35 -44
- package/node_modules/hono/dist/cjs/utils/compress.js +11 -26
- package/node_modules/hono/dist/cjs/utils/concurrent.js +29 -59
- package/node_modules/hono/dist/cjs/utils/constants.js +7 -26
- package/node_modules/hono/dist/cjs/utils/cookie.js +107 -177
- package/node_modules/hono/dist/cjs/utils/crypto.js +30 -61
- package/node_modules/hono/dist/cjs/utils/encode.js +31 -48
- package/node_modules/hono/dist/cjs/utils/filepath.js +23 -54
- package/node_modules/hono/dist/cjs/utils/handler.js +11 -33
- package/node_modules/hono/dist/cjs/utils/headers.js +0 -15
- package/node_modules/hono/dist/cjs/utils/html.js +96 -137
- package/node_modules/hono/dist/cjs/utils/http-status.js +0 -15
- package/node_modules/hono/dist/cjs/utils/ipaddr.js +213 -286
- package/node_modules/hono/dist/cjs/utils/jwt/index.js +14 -27
- package/node_modules/hono/dist/cjs/utils/jwt/jwa.js +25 -42
- package/node_modules/hono/dist/cjs/utils/jwt/jws.js +119 -199
- package/node_modules/hono/dist/cjs/utils/jwt/jwt.js +122 -205
- package/node_modules/hono/dist/cjs/utils/jwt/types.js +122 -159
- package/node_modules/hono/dist/cjs/utils/jwt/utf8.js +9 -28
- package/node_modules/hono/dist/cjs/utils/mime.js +75 -101
- package/node_modules/hono/dist/cjs/utils/stream.js +88 -111
- package/node_modules/hono/dist/cjs/utils/types.js +0 -15
- package/node_modules/hono/dist/cjs/utils/url.js +185 -234
- package/node_modules/hono/dist/cjs/validator/index.js +3 -27
- package/node_modules/hono/dist/cjs/validator/utils.js +0 -15
- package/node_modules/hono/dist/cjs/validator/validator.js +60 -103
- package/node_modules/hono/dist/client/client.js +138 -197
- package/node_modules/hono/dist/client/fetch-result-please.js +59 -56
- package/node_modules/hono/dist/client/index.js +3 -7
- package/node_modules/hono/dist/client/types.js +1 -0
- package/node_modules/hono/dist/client/utils.js +51 -68
- package/node_modules/hono/dist/compose.js +49 -45
- package/node_modules/hono/dist/context.js +376 -426
- package/node_modules/hono/dist/helper/accepts/accepts.js +47 -49
- package/node_modules/hono/dist/helper/accepts/index.js +1 -4
- package/node_modules/hono/dist/helper/adapter/index.js +33 -52
- package/node_modules/hono/dist/helper/conninfo/index.js +1 -0
- package/node_modules/hono/dist/helper/conninfo/types.js +1 -0
- package/node_modules/hono/dist/helper/cookie/index.js +74 -94
- package/node_modules/hono/dist/helper/css/common.js +167 -225
- package/node_modules/hono/dist/helper/css/index.js +132 -137
- package/node_modules/hono/dist/helper/dev/index.js +44 -49
- package/node_modules/hono/dist/helper/factory/index.js +27 -27
- package/node_modules/hono/dist/helper/html/index.js +30 -39
- package/node_modules/hono/dist/helper/proxy/index.js +116 -88
- package/node_modules/hono/dist/helper/route/index.js +121 -43
- package/node_modules/hono/dist/helper/ssg/index.js +3 -18
- package/node_modules/hono/dist/helper/ssg/middleware.js +53 -40
- package/node_modules/hono/dist/helper/ssg/plugins.js +55 -36
- package/node_modules/hono/dist/helper/ssg/ssg.js +198 -283
- package/node_modules/hono/dist/helper/ssg/utils.js +53 -75
- package/node_modules/hono/dist/helper/streaming/index.js +2 -8
- package/node_modules/hono/dist/helper/streaming/sse.js +50 -61
- package/node_modules/hono/dist/helper/streaming/stream.js +22 -31
- package/node_modules/hono/dist/helper/streaming/text.js +9 -10
- package/node_modules/hono/dist/helper/streaming/utils.js +9 -12
- package/node_modules/hono/dist/helper/testing/index.js +16 -10
- package/node_modules/hono/dist/helper/websocket/index.js +49 -53
- package/node_modules/hono/dist/hono-base.js +342 -379
- package/node_modules/hono/dist/hono.js +27 -20
- package/node_modules/hono/dist/http-exception.js +53 -33
- package/node_modules/hono/dist/index.js +19 -6
- package/node_modules/hono/dist/jsx/base.js +231 -340
- package/node_modules/hono/dist/jsx/children.js +16 -20
- package/node_modules/hono/dist/jsx/components.js +118 -170
- package/node_modules/hono/dist/jsx/constants.js +9 -15
- package/node_modules/hono/dist/jsx/context.js +153 -150
- package/node_modules/hono/dist/jsx/dom/client.js +45 -48
- package/node_modules/hono/dist/jsx/dom/components.js +21 -29
- package/node_modules/hono/dist/jsx/dom/context.js +37 -44
- package/node_modules/hono/dist/jsx/dom/css.js +142 -147
- package/node_modules/hono/dist/jsx/dom/hooks/index.js +52 -40
- package/node_modules/hono/dist/jsx/dom/index.js +71 -134
- package/node_modules/hono/dist/jsx/dom/intrinsic-element/components.js +275 -359
- package/node_modules/hono/dist/jsx/dom/jsx-dev-runtime.js +14 -18
- package/node_modules/hono/dist/jsx/dom/jsx-runtime.js +2 -8
- package/node_modules/hono/dist/jsx/dom/render.js +492 -595
- package/node_modules/hono/dist/jsx/dom/server.js +32 -32
- package/node_modules/hono/dist/jsx/dom/utils.js +6 -8
- package/node_modules/hono/dist/jsx/hooks/index.js +236 -308
- package/node_modules/hono/dist/jsx/index.js +45 -98
- package/node_modules/hono/dist/jsx/intrinsic-element/common.js +20 -22
- package/node_modules/hono/dist/jsx/intrinsic-element/components.js +113 -154
- package/node_modules/hono/dist/jsx/intrinsic-elements.js +1 -0
- package/node_modules/hono/dist/jsx/jsx-dev-runtime.js +12 -16
- package/node_modules/hono/dist/jsx/jsx-runtime.js +29 -42
- package/node_modules/hono/dist/jsx/streaming.js +120 -142
- package/node_modules/hono/dist/jsx/types.js +1 -0
- package/node_modules/hono/dist/jsx/utils.js +105 -168
- package/node_modules/hono/dist/middleware/basic-auth/index.js +96 -63
- package/node_modules/hono/dist/middleware/bearer-auth/index.js +93 -89
- package/node_modules/hono/dist/middleware/body-limit/index.js +66 -51
- package/node_modules/hono/dist/middleware/cache/index.js +165 -190
- package/node_modules/hono/dist/middleware/combine/index.js +132 -73
- package/node_modules/hono/dist/middleware/compress/index.js +75 -69
- package/node_modules/hono/dist/middleware/context-storage/index.js +49 -19
- package/node_modules/hono/dist/middleware/cors/index.js +107 -86
- package/node_modules/hono/dist/middleware/csrf/index.js +103 -53
- package/node_modules/hono/dist/middleware/etag/digest.js +59 -77
- package/node_modules/hono/dist/middleware/etag/index.js +71 -70
- package/node_modules/hono/dist/middleware/ip-restriction/index.js +163 -158
- package/node_modules/hono/dist/middleware/jsx-renderer/index.js +97 -54
- package/node_modules/hono/dist/middleware/jwk/index.js +1 -4
- package/node_modules/hono/dist/middleware/jwk/jwk.js +116 -112
- package/node_modules/hono/dist/middleware/jwt/index.js +2 -10
- package/node_modules/hono/dist/middleware/jwt/jwt.js +114 -114
- package/node_modules/hono/dist/middleware/language/index.js +2 -15
- package/node_modules/hono/dist/middleware/language/language.js +180 -154
- package/node_modules/hono/dist/middleware/logger/index.js +43 -37
- package/node_modules/hono/dist/middleware/method-not-allowed/index.js +81 -66
- package/node_modules/hono/dist/middleware/method-override/index.js +101 -81
- package/node_modules/hono/dist/middleware/powered-by/index.js +23 -9
- package/node_modules/hono/dist/middleware/pretty-json/index.js +39 -16
- package/node_modules/hono/dist/middleware/request-id/index.js +1 -4
- package/node_modules/hono/dist/middleware/request-id/request-id.js +33 -20
- package/node_modules/hono/dist/middleware/secure-headers/index.js +1 -5
- package/node_modules/hono/dist/middleware/secure-headers/permissions-policy.js +1 -0
- package/node_modules/hono/dist/middleware/secure-headers/secure-headers.js +144 -155
- package/node_modules/hono/dist/middleware/serve-static/index.js +56 -72
- package/node_modules/hono/dist/middleware/serve-static/path.js +15 -17
- package/node_modules/hono/dist/middleware/timeout/index.js +40 -23
- package/node_modules/hono/dist/middleware/timing/index.js +2 -9
- package/node_modules/hono/dist/middleware/timing/timing.js +177 -97
- package/node_modules/hono/dist/middleware/trailing-slash/index.js +85 -37
- package/node_modules/hono/dist/preset/quick.js +17 -15
- package/node_modules/hono/dist/preset/tiny.js +14 -11
- package/node_modules/hono/dist/request/constants.js +4 -5
- package/node_modules/hono/dist/request.js +328 -316
- package/node_modules/hono/dist/router/linear-router/index.js +1 -4
- package/node_modules/hono/dist/router/linear-router/router.js +93 -120
- package/node_modules/hono/dist/router/pattern-router/index.js +1 -4
- package/node_modules/hono/dist/router/pattern-router/router.js +39 -40
- package/node_modules/hono/dist/router/reg-exp-router/index.js +1 -7
- package/node_modules/hono/dist/router/reg-exp-router/matcher.js +17 -23
- package/node_modules/hono/dist/router/reg-exp-router/node.js +87 -110
- package/node_modules/hono/dist/router/reg-exp-router/prepared-router.js +89 -137
- package/node_modules/hono/dist/router/reg-exp-router/router.js +92 -129
- package/node_modules/hono/dist/router/reg-exp-router/trie.js +69 -64
- package/node_modules/hono/dist/router/smart-router/index.js +1 -4
- package/node_modules/hono/dist/router/smart-router/router.js +46 -55
- package/node_modules/hono/dist/router/trie-router/index.js +1 -4
- package/node_modules/hono/dist/router/trie-router/node.js +131 -162
- package/node_modules/hono/dist/router/trie-router/router.js +11 -14
- package/node_modules/hono/dist/router/utils.js +4 -5
- package/node_modules/hono/dist/router.js +35 -14
- package/node_modules/hono/dist/types/adapter/aws-lambda/conninfo.d.ts +4 -1
- package/node_modules/hono/dist/types/adapter/aws-lambda/handler.d.ts +150 -105
- package/node_modules/hono/dist/types/adapter/aws-lambda/index.d.ts +4 -8
- package/node_modules/hono/dist/types/adapter/aws-lambda/types.d.ts +152 -123
- package/node_modules/hono/dist/types/adapter/bun/conninfo.d.ts +4 -1
- package/node_modules/hono/dist/types/adapter/bun/index.d.ts +6 -10
- package/node_modules/hono/dist/types/adapter/bun/serve-static.d.ts +7 -2
- package/node_modules/hono/dist/types/adapter/bun/server.d.ts +4 -5
- package/node_modules/hono/dist/types/adapter/bun/ssg.d.ts +5 -1
- package/node_modules/hono/dist/types/adapter/bun/websocket.d.ts +31 -17
- package/node_modules/hono/dist/types/adapter/cloudflare-pages/conninfo.d.ts +4 -1
- package/node_modules/hono/dist/types/adapter/cloudflare-pages/handler.d.ts +29 -18
- package/node_modules/hono/dist/types/adapter/cloudflare-pages/index.d.ts +3 -7
- package/node_modules/hono/dist/types/adapter/cloudflare-workers/conninfo.d.ts +6 -1
- package/node_modules/hono/dist/types/adapter/cloudflare-workers/index.d.ts +4 -7
- package/node_modules/hono/dist/types/adapter/cloudflare-workers/serve-static-module.d.ts +5 -3
- package/node_modules/hono/dist/types/adapter/cloudflare-workers/serve-static.d.ts +10 -5
- package/node_modules/hono/dist/types/adapter/cloudflare-workers/utils.d.ts +10 -2
- package/node_modules/hono/dist/types/adapter/cloudflare-workers/websocket.d.ts +6 -1
- package/node_modules/hono/dist/types/adapter/deno/conninfo.d.ts +4 -1
- package/node_modules/hono/dist/types/adapter/deno/deno.d.ts +1 -0
- package/node_modules/hono/dist/types/adapter/deno/index.d.ts +5 -8
- package/node_modules/hono/dist/types/adapter/deno/serve-static.d.ts +7 -2
- package/node_modules/hono/dist/types/adapter/deno/ssg.d.ts +5 -1
- package/node_modules/hono/dist/types/adapter/deno/websocket.d.ts +6 -1
- package/node_modules/hono/dist/types/adapter/lambda-edge/conninfo.d.ts +6 -1
- package/node_modules/hono/dist/types/adapter/lambda-edge/handler.d.ts +83 -58
- package/node_modules/hono/dist/types/adapter/lambda-edge/index.d.ts +3 -7
- package/node_modules/hono/dist/types/adapter/netlify/conninfo.d.ts +4 -1
- package/node_modules/hono/dist/types/adapter/netlify/handler.d.ts +6 -1
- package/node_modules/hono/dist/types/adapter/netlify/index.d.ts +3 -5
- package/node_modules/hono/dist/types/adapter/netlify/mod.d.ts +3 -2
- package/node_modules/hono/dist/types/adapter/service-worker/handler.d.ts +9 -8
- package/node_modules/hono/dist/types/adapter/service-worker/index.d.ts +6 -9
- package/node_modules/hono/dist/types/adapter/service-worker/types.d.ts +12 -8
- package/node_modules/hono/dist/types/adapter/vercel/conninfo.d.ts +6 -1
- package/node_modules/hono/dist/types/adapter/vercel/handler.d.ts +6 -1
- package/node_modules/hono/dist/types/adapter/vercel/index.d.ts +3 -6
- package/node_modules/hono/dist/types/client/client.d.ts +5 -3
- package/node_modules/hono/dist/types/client/fetch-result-please.d.ts +21 -19
- package/node_modules/hono/dist/types/client/index.d.ts +5 -7
- package/node_modules/hono/dist/types/client/types.d.ts +134 -160
- package/node_modules/hono/dist/types/client/utils.d.ts +6 -4
- package/node_modules/hono/dist/types/compose.d.ts +4 -2
- package/node_modules/hono/dist/types/context.d.ts +335 -336
- package/node_modules/hono/dist/types/helper/accepts/accepts.d.ts +11 -9
- package/node_modules/hono/dist/types/helper/accepts/index.d.ts +2 -5
- package/node_modules/hono/dist/types/helper/adapter/index.d.ts +4 -6
- package/node_modules/hono/dist/types/helper/conninfo/index.d.ts +2 -5
- package/node_modules/hono/dist/types/helper/conninfo/types.d.ts +25 -23
- package/node_modules/hono/dist/types/helper/cookie/index.d.ts +10 -13
- package/node_modules/hono/dist/types/helper/css/common.d.ts +11 -10
- package/node_modules/hono/dist/types/helper/css/index.d.ts +25 -28
- package/node_modules/hono/dist/types/helper/dev/index.d.ts +10 -13
- package/node_modules/hono/dist/types/helper/factory/index.d.ts +26 -74
- package/node_modules/hono/dist/types/helper/html/index.d.ts +4 -7
- package/node_modules/hono/dist/types/helper/proxy/index.d.ts +20 -23
- package/node_modules/hono/dist/types/helper/route/index.d.ts +6 -4
- package/node_modules/hono/dist/types/helper/ssg/index.d.ts +4 -7
- package/node_modules/hono/dist/types/helper/ssg/middleware.d.ts +8 -7
- package/node_modules/hono/dist/types/helper/ssg/plugins.d.ts +3 -1
- package/node_modules/hono/dist/types/helper/ssg/ssg.d.ts +38 -36
- package/node_modules/hono/dist/types/helper/ssg/utils.d.ts +5 -4
- package/node_modules/hono/dist/types/helper/streaming/index.d.ts +4 -8
- package/node_modules/hono/dist/types/helper/streaming/sse.d.ts +10 -8
- package/node_modules/hono/dist/types/helper/streaming/stream.d.ts +4 -2
- package/node_modules/hono/dist/types/helper/streaming/text.d.ts +4 -2
- package/node_modules/hono/dist/types/helper/streaming/utils.d.ts +2 -0
- package/node_modules/hono/dist/types/helper/testing/index.d.ts +7 -10
- package/node_modules/hono/dist/types/helper/websocket/index.d.ts +30 -33
- package/node_modules/hono/dist/types/hono-base.d.ts +208 -211
- package/node_modules/hono/dist/types/hono.d.ts +11 -10
- package/node_modules/hono/dist/types/http-exception.d.ts +20 -23
- package/node_modules/hono/dist/types/index.d.ts +6 -37
- package/node_modules/hono/dist/types/jsx/base.d.ts +36 -35
- package/node_modules/hono/dist/types/jsx/children.d.ts +8 -6
- package/node_modules/hono/dist/types/jsx/components.d.ts +8 -5
- package/node_modules/hono/dist/types/jsx/constants.d.ts +2 -0
- package/node_modules/hono/dist/types/jsx/context.d.ts +9 -7
- package/node_modules/hono/dist/types/jsx/dom/client.d.ts +8 -10
- package/node_modules/hono/dist/types/jsx/dom/components.d.ts +9 -6
- package/node_modules/hono/dist/types/jsx/dom/context.d.ts +3 -1
- package/node_modules/hono/dist/types/jsx/dom/css.d.ts +26 -30
- package/node_modules/hono/dist/types/jsx/dom/hooks/index.d.ts +11 -13
- package/node_modules/hono/dist/types/jsx/dom/index.d.ts +78 -83
- package/node_modules/hono/dist/types/jsx/dom/intrinsic-element/components.d.ts +9 -5
- package/node_modules/hono/dist/types/jsx/dom/jsx-dev-runtime.d.ts +4 -6
- package/node_modules/hono/dist/types/jsx/dom/jsx-runtime.d.ts +3 -7
- package/node_modules/hono/dist/types/jsx/dom/render.d.ts +32 -51
- package/node_modules/hono/dist/types/jsx/dom/server.d.ts +86 -85
- package/node_modules/hono/dist/types/jsx/dom/utils.d.ts +2 -0
- package/node_modules/hono/dist/types/jsx/hooks/index.d.ts +16 -17
- package/node_modules/hono/dist/types/jsx/index.d.ts +70 -73
- package/node_modules/hono/dist/types/jsx/intrinsic-element/common.d.ts +3 -1
- package/node_modules/hono/dist/types/jsx/intrinsic-element/components.d.ts +7 -4
- package/node_modules/hono/dist/types/jsx/intrinsic-elements.d.ts +708 -708
- package/node_modules/hono/dist/types/jsx/jsx-dev-runtime.d.ts +4 -7
- package/node_modules/hono/dist/types/jsx/jsx-runtime.d.ts +7 -10
- package/node_modules/hono/dist/types/jsx/streaming.d.ts +9 -10
- package/node_modules/hono/dist/types/jsx/types.d.ts +11 -13
- package/node_modules/hono/dist/types/jsx/utils.d.ts +2 -0
- package/node_modules/hono/dist/types/middleware/basic-auth/index.d.ts +17 -20
- package/node_modules/hono/dist/types/middleware/bearer-auth/index.d.ts +46 -49
- package/node_modules/hono/dist/types/middleware/body-limit/index.d.ts +6 -9
- package/node_modules/hono/dist/types/middleware/cache/index.d.ts +13 -15
- package/node_modules/hono/dist/types/middleware/combine/index.d.ts +7 -8
- package/node_modules/hono/dist/types/middleware/compress/index.d.ts +8 -10
- package/node_modules/hono/dist/types/middleware/context-storage/index.d.ts +4 -6
- package/node_modules/hono/dist/types/middleware/cors/index.d.ts +10 -13
- package/node_modules/hono/dist/types/middleware/csrf/index.d.ts +6 -9
- package/node_modules/hono/dist/types/middleware/etag/digest.d.ts +2 -0
- package/node_modules/hono/dist/types/middleware/etag/index.d.ts +6 -9
- package/node_modules/hono/dist/types/middleware/ip-restriction/index.d.ts +11 -13
- package/node_modules/hono/dist/types/middleware/jsx-renderer/index.d.ts +11 -12
- package/node_modules/hono/dist/types/middleware/jwk/index.d.ts +2 -1
- package/node_modules/hono/dist/types/middleware/jwk/jwk.d.ts +20 -23
- package/node_modules/hono/dist/types/middleware/jwt/index.d.ts +6 -6
- package/node_modules/hono/dist/types/middleware/jwt/jwt.d.ts +28 -30
- package/node_modules/hono/dist/types/middleware/language/index.d.ts +5 -5
- package/node_modules/hono/dist/types/middleware/language/language.d.ts +42 -44
- package/node_modules/hono/dist/types/middleware/logger/index.d.ts +3 -6
- package/node_modules/hono/dist/types/middleware/method-not-allowed/index.d.ts +7 -10
- package/node_modules/hono/dist/types/middleware/method-override/index.d.ts +14 -17
- package/node_modules/hono/dist/types/middleware/powered-by/index.d.ts +8 -11
- package/node_modules/hono/dist/types/middleware/pretty-json/index.d.ts +18 -21
- package/node_modules/hono/dist/types/middleware/request-id/index.d.ts +5 -5
- package/node_modules/hono/dist/types/middleware/request-id/request-id.d.ts +9 -11
- package/node_modules/hono/dist/types/middleware/secure-headers/index.d.ts +5 -6
- package/node_modules/hono/dist/types/middleware/secure-headers/permissions-policy.d.ts +2 -1
- package/node_modules/hono/dist/types/middleware/secure-headers/secure-headers.d.ts +55 -58
- package/node_modules/hono/dist/types/middleware/serve-static/index.d.ts +24 -24
- package/node_modules/hono/dist/types/middleware/serve-static/path.d.ts +2 -0
- package/node_modules/hono/dist/types/middleware/timeout/index.d.ts +5 -7
- package/node_modules/hono/dist/types/middleware/timing/index.d.ts +5 -5
- package/node_modules/hono/dist/types/middleware/timing/timing.d.ts +17 -21
- package/node_modules/hono/dist/types/middleware/trailing-slash/index.d.ts +35 -38
- package/node_modules/hono/dist/types/preset/quick.d.ts +6 -9
- package/node_modules/hono/dist/types/preset/tiny.d.ts +6 -9
- package/node_modules/hono/dist/types/request/constants.d.ts +2 -0
- package/node_modules/hono/dist/types/request.d.ts +288 -287
- package/node_modules/hono/dist/types/router/linear-router/index.d.ts +2 -5
- package/node_modules/hono/dist/types/router/linear-router/router.d.ts +7 -5
- package/node_modules/hono/dist/types/router/pattern-router/index.d.ts +2 -5
- package/node_modules/hono/dist/types/router/pattern-router/router.d.ts +7 -5
- package/node_modules/hono/dist/types/router/reg-exp-router/index.d.ts +3 -6
- package/node_modules/hono/dist/types/router/reg-exp-router/matcher.d.ts +3 -1
- package/node_modules/hono/dist/types/router/reg-exp-router/node.d.ts +6 -4
- package/node_modules/hono/dist/types/router/reg-exp-router/prepared-router.d.ts +11 -11
- package/node_modules/hono/dist/types/router/reg-exp-router/router.d.ts +10 -9
- package/node_modules/hono/dist/types/router/reg-exp-router/trie.d.ts +7 -5
- package/node_modules/hono/dist/types/router/smart-router/index.d.ts +2 -5
- package/node_modules/hono/dist/types/router/smart-router/router.d.ts +11 -9
- package/node_modules/hono/dist/types/router/trie-router/index.d.ts +2 -5
- package/node_modules/hono/dist/types/router/trie-router/node.d.ts +6 -4
- package/node_modules/hono/dist/types/router/trie-router/router.d.ts +7 -5
- package/node_modules/hono/dist/types/router/utils.d.ts +2 -0
- package/node_modules/hono/dist/types/router.d.ts +23 -22
- package/node_modules/hono/dist/types/types.d.ts +146 -506
- package/node_modules/hono/dist/types/utils/accept.d.ts +5 -3
- package/node_modules/hono/dist/types/utils/basic-auth.d.ts +4 -2
- package/node_modules/hono/dist/types/utils/body.d.ts +46 -51
- package/node_modules/hono/dist/types/utils/buffer.d.ts +7 -6
- package/node_modules/hono/dist/types/utils/color.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/compress.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/concurrent.d.ts +6 -4
- package/node_modules/hono/dist/types/utils/constants.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/cookie.d.ts +20 -19
- package/node_modules/hono/dist/types/utils/crypto.d.ts +5 -8
- package/node_modules/hono/dist/types/utils/encode.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/filepath.d.ts +5 -4
- package/node_modules/hono/dist/types/utils/handler.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/headers.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/html.d.ts +11 -10
- package/node_modules/hono/dist/types/utils/http-status.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/ipaddr.d.ts +4 -6
- package/node_modules/hono/dist/types/utils/jwt/index.d.ts +18 -12
- package/node_modules/hono/dist/types/utils/jwt/jwa.d.ts +15 -13
- package/node_modules/hono/dist/types/utils/jwt/jws.d.ts +4 -7
- package/node_modules/hono/dist/types/utils/jwt/jwt.d.ts +26 -29
- package/node_modules/hono/dist/types/utils/jwt/types.d.ts +48 -45
- package/node_modules/hono/dist/types/utils/jwt/utf8.d.ts +2 -0
- package/node_modules/hono/dist/types/utils/mime.d.ts +59 -57
- package/node_modules/hono/dist/types/utils/stream.d.ts +27 -25
- package/node_modules/hono/dist/types/utils/types.d.ts +15 -28
- package/node_modules/hono/dist/types/utils/url.d.ts +2 -1
- package/node_modules/hono/dist/types/validator/index.d.ts +3 -7
- package/node_modules/hono/dist/types/validator/utils.d.ts +6 -9
- package/node_modules/hono/dist/types/validator/validator.d.ts +11 -10
- package/node_modules/hono/dist/types.js +4 -6
- package/node_modules/hono/dist/utils/accept.js +185 -215
- package/node_modules/hono/dist/utils/basic-auth.js +18 -21
- package/node_modules/hono/dist/utils/body.js +87 -92
- package/node_modules/hono/dist/utils/buffer.js +44 -71
- package/node_modules/hono/dist/utils/color.js +33 -21
- package/node_modules/hono/dist/utils/compress.js +11 -5
- package/node_modules/hono/dist/utils/concurrent.js +29 -38
- package/node_modules/hono/dist/utils/constants.js +7 -5
- package/node_modules/hono/dist/utils/cookie.js +114 -163
- package/node_modules/hono/dist/utils/crypto.js +30 -40
- package/node_modules/hono/dist/utils/encode.js +30 -26
- package/node_modules/hono/dist/utils/filepath.js +23 -33
- package/node_modules/hono/dist/utils/handler.js +10 -11
- package/node_modules/hono/dist/utils/headers.js +1 -0
- package/node_modules/hono/dist/utils/html.js +97 -117
- package/node_modules/hono/dist/utils/http-status.js +1 -0
- package/node_modules/hono/dist/utils/ipaddr.js +227 -279
- package/node_modules/hono/dist/utils/jwt/index.js +12 -4
- package/node_modules/hono/dist/utils/jwt/jwa.js +24 -20
- package/node_modules/hono/dist/utils/jwt/jws.js +115 -174
- package/node_modules/hono/dist/utils/jwt/jwt.js +120 -197
- package/node_modules/hono/dist/utils/jwt/types.js +79 -95
- package/node_modules/hono/dist/utils/jwt/utf8.js +9 -7
- package/node_modules/hono/dist/utils/mime.js +74 -79
- package/node_modules/hono/dist/utils/stream.js +86 -88
- package/node_modules/hono/dist/utils/types.js +1 -0
- package/node_modules/hono/dist/utils/url.js +187 -215
- package/node_modules/hono/dist/validator/index.js +1 -4
- package/node_modules/hono/dist/validator/utils.js +1 -0
- package/node_modules/hono/dist/validator/validator.js +61 -83
- package/node_modules/hono/package.json +27 -27
- package/node_modules/ip-address/README.md +104 -104
- package/node_modules/ip-address/dist/common.js +2 -2
- package/node_modules/ip-address/dist/common.js.map +1 -1
- package/node_modules/ip-address/dist/ipv4.js +7 -0
- package/node_modules/ip-address/dist/ipv4.js.map +1 -1
- package/node_modules/ip-address/dist/ipv6.js +7 -4
- package/node_modules/ip-address/dist/ipv6.js.map +1 -1
- package/node_modules/ip-address/dist/v6/constants.d.ts +3 -0
- package/node_modules/ip-address/dist/v6/constants.js +3 -0
- package/node_modules/ip-address/dist/v6/constants.js.map +1 -1
- package/node_modules/ip-address/package.json +3 -2
- package/node_modules/qs/.editorconfig +1 -1
- package/node_modules/qs/.github/THREAT_MODEL.md +4 -2
- package/node_modules/qs/CHANGELOG.md +61 -14
- package/node_modules/qs/README.md +57 -4
- package/node_modules/qs/dist/qs.js +19 -19
- package/node_modules/qs/eslint.config.mjs +61 -50
- package/node_modules/qs/lib/formats.js +7 -2
- package/node_modules/qs/lib/parse.js +105 -8
- package/node_modules/qs/lib/stringify.js +9 -7
- package/node_modules/qs/lib/utils.js +145 -13
- package/node_modules/qs/package.json +8 -8
- package/node_modules/qs/test/parse.js +440 -2
- package/node_modules/qs/test/stringify.js +485 -33
- package/node_modules/qs/test/utils.js +245 -3
- package/node_modules/zod/README.md +29 -2
- package/node_modules/zod/compile.cjs +96 -0
- package/node_modules/zod/compile.d.cts +1 -0
- package/node_modules/zod/compile.d.ts +1 -0
- package/node_modules/zod/compile.js +52 -0
- package/node_modules/zod/index.cjs +21 -2
- package/node_modules/zod/index.d.cts +1 -2
- package/node_modules/zod/index.d.ts +1 -2
- package/node_modules/zod/index.js +5 -2
- package/node_modules/zod/locales/index.cjs +19 -0
- package/node_modules/zod/mini/index.cjs +19 -0
- package/node_modules/zod/package.json +20 -8
- package/node_modules/zod/src/compile.ts +56 -0
- package/node_modules/zod/src/index.ts +5 -2
- package/node_modules/zod/src/v3/ZodError.ts +22 -12
- package/node_modules/zod/src/v3/helpers/errorUtil.ts +1 -1
- package/node_modules/zod/src/v3/tests/error.test.ts +35 -0
- package/node_modules/zod/src/v3/tests/intersection.test.ts +18 -0
- package/node_modules/zod/src/v3/tests/language-server.test.ts +1 -2
- package/node_modules/zod/src/v3/tests/object.test.ts +3 -6
- package/node_modules/zod/src/v3/tests/readonly.test.ts +0 -80
- package/node_modules/zod/src/v3/tests/string.test.ts +6 -0
- package/node_modules/zod/src/v3/types.ts +5 -5
- package/node_modules/zod/src/v4/classic/checks.ts +1 -0
- package/node_modules/zod/src/v4/classic/compat.ts +26 -18
- package/node_modules/zod/src/v4/classic/deep-partial.ts +76 -0
- package/node_modules/zod/src/v4/classic/errors.ts +59 -44
- package/node_modules/zod/src/v4/classic/external.ts +14 -9
- package/node_modules/zod/src/v4/classic/from-json-schema.ts +363 -78
- package/node_modules/zod/src/v4/classic/in-out.ts +45 -0
- package/node_modules/zod/src/v4/classic/index.ts +2 -2
- package/node_modules/zod/src/v4/classic/iso.ts +2 -72
- package/node_modules/zod/src/v4/classic/parse.ts +10 -4
- package/node_modules/zod/src/v4/classic/schemas.ts +640 -375
- package/node_modules/zod/src/v4/classic/tests/apply.test.ts +27 -0
- package/node_modules/zod/src/v4/classic/tests/array.test.ts +29 -2
- package/node_modules/zod/src/v4/classic/tests/assignability.test.ts +186 -0
- package/node_modules/zod/src/v4/classic/tests/bigint.test.ts +36 -1
- package/node_modules/zod/src/v4/classic/tests/catch.test.ts +278 -0
- package/node_modules/zod/src/v4/classic/tests/codec-examples.test.ts +1 -2
- package/node_modules/zod/src/v4/classic/tests/codec.test.ts +2 -1
- package/node_modules/zod/src/v4/classic/tests/continuability.test.ts +3 -3
- package/node_modules/zod/src/v4/classic/tests/credit-card.test.ts +76 -0
- package/node_modules/zod/src/v4/classic/tests/cyclic-data.test.ts +985 -0
- package/node_modules/zod/src/v4/classic/tests/date.test.ts +30 -0
- package/node_modules/zod/src/v4/classic/tests/datetime.test.ts +32 -18
- package/node_modules/zod/src/v4/classic/tests/deep-partial.test.ts +380 -0
- package/node_modules/zod/src/v4/classic/tests/default-locale.test.ts +32 -0
- package/node_modules/zod/src/v4/classic/tests/default.test.ts +46 -0
- package/node_modules/zod/src/v4/classic/tests/detached-methods.test.ts +31 -7
- package/node_modules/zod/src/v4/classic/tests/discriminated-unions.test.ts +261 -13
- package/node_modules/zod/src/v4/classic/tests/enum.test.ts +20 -0
- package/node_modules/zod/src/v4/classic/tests/error-utils.test.ts +112 -2
- package/node_modules/zod/src/v4/classic/tests/error.test.ts +403 -6
- package/node_modules/zod/src/v4/classic/tests/from-json-schema.test.ts +582 -10
- package/node_modules/zod/src/v4/classic/tests/function.test.ts +31 -0
- package/node_modules/zod/src/v4/classic/tests/global-config.test.ts +2 -9
- package/node_modules/zod/src/v4/classic/tests/hash.test.ts +1 -2
- package/node_modules/zod/src/v4/classic/tests/iban.test.ts +81 -0
- package/node_modules/zod/src/v4/classic/tests/in-out.test.ts +159 -0
- package/node_modules/zod/src/v4/classic/tests/index.test.ts +21 -2
- package/node_modules/zod/src/v4/classic/tests/instance-footprint.test.ts +319 -0
- package/node_modules/zod/src/v4/classic/tests/instanceof.test.ts +67 -0
- package/node_modules/zod/src/v4/classic/tests/intersection.test.ts +136 -0
- package/node_modules/zod/src/v4/classic/tests/issue-schema.test.ts +215 -0
- package/node_modules/zod/src/v4/classic/tests/jitless-allows-eval.test.ts +3 -10
- package/node_modules/zod/src/v4/classic/tests/lazy.test.ts +36 -1
- package/node_modules/zod/src/v4/classic/tests/literal.test.ts +12 -1
- package/node_modules/zod/src/v4/classic/tests/map.test.ts +19 -0
- package/node_modules/zod/src/v4/classic/tests/number.test.ts +85 -9
- package/node_modules/zod/src/v4/classic/tests/object.test.ts +301 -12
- package/node_modules/zod/src/v4/classic/tests/optin-ladder.test.ts +235 -0
- package/node_modules/zod/src/v4/classic/tests/optional.test.ts +49 -16
- package/node_modules/zod/src/v4/classic/tests/partial.test.ts +51 -4
- package/node_modules/zod/src/v4/classic/tests/prefault.test.ts +70 -0
- package/node_modules/zod/src/v4/classic/tests/preprocess-types.test.ts +20 -2
- package/node_modules/zod/src/v4/classic/tests/properties.test.ts +141 -0
- package/node_modules/zod/src/v4/classic/tests/readonly.test.ts +0 -68
- package/node_modules/zod/src/v4/classic/tests/record.test.ts +186 -18
- package/node_modules/zod/src/v4/classic/tests/recursive-types.test.ts +79 -3
- package/node_modules/zod/src/v4/classic/tests/redos.test.ts +68 -0
- package/node_modules/zod/src/v4/classic/tests/refine.test.ts +60 -0
- package/node_modules/zod/src/v4/classic/tests/set.test.ts +15 -0
- package/node_modules/zod/src/v4/classic/tests/standard-schema.test.ts +19 -0
- package/node_modules/zod/src/v4/classic/tests/string.test.ts +222 -6
- package/node_modules/zod/src/v4/classic/tests/stringbool.test.ts +18 -0
- package/node_modules/zod/src/v4/classic/tests/template-literal.test.ts +44 -3
- package/node_modules/zod/src/v4/classic/tests/to-json-schema.test.ts +1812 -204
- package/node_modules/zod/src/v4/classic/tests/tuple.test.ts +45 -30
- package/node_modules/zod/src/v4/classic/tests/union.test.ts +39 -2
- package/node_modules/zod/src/v4/classic/tests/validate.test.ts +645 -0
- package/node_modules/zod/src/v4/classic/tests/validations.test.ts +2 -2
- package/node_modules/zod/src/v4/core/api.ts +87 -35
- package/node_modules/zod/src/v4/core/checks.ts +119 -146
- package/node_modules/zod/src/v4/core/compile.ts +2322 -0
- package/node_modules/zod/src/v4/core/core.ts +99 -22
- package/node_modules/zod/src/v4/core/doc.ts +17 -9
- package/node_modules/zod/src/v4/core/errors.ts +113 -25
- package/node_modules/zod/src/v4/core/index.ts +3 -0
- package/node_modules/zod/src/v4/core/json-schema-generator.ts +8 -3
- package/node_modules/zod/src/v4/core/json-schema-processors.ts +424 -156
- package/node_modules/zod/src/v4/core/json-schema.ts +2 -1
- package/node_modules/zod/src/v4/core/memoizer.ts +331 -0
- package/node_modules/zod/src/v4/core/parse.ts +164 -50
- package/node_modules/zod/src/v4/core/regexes.ts +42 -15
- package/node_modules/zod/src/v4/core/registries.ts +2 -2
- package/node_modules/zod/src/v4/core/schemas.ts +1035 -539
- package/node_modules/zod/src/v4/core/tests/cached.test.ts +54 -0
- package/node_modules/zod/src/v4/core/tests/compile-differential.test.ts +1004 -0
- package/node_modules/zod/src/v4/core/tests/compile-generative.test.ts +445 -0
- package/node_modules/zod/src/v4/core/tests/compile-global.test.ts +89 -0
- package/node_modules/zod/src/v4/core/tests/compile-off-by-default.test.ts +26 -0
- package/node_modules/zod/src/v4/core/tests/compile-stats.test.ts +34 -0
- package/node_modules/zod/src/v4/core/tests/compile.test.ts +2036 -0
- package/node_modules/zod/src/v4/core/tests/email-regex.test.ts +140 -0
- package/node_modules/zod/src/v4/core/tests/locales/el.test.ts +1 -2
- package/node_modules/zod/src/v4/core/tests/locales/es.test.ts +1 -2
- package/node_modules/zod/src/v4/core/tests/locales/fr.test.ts +3 -3
- package/node_modules/zod/src/v4/core/tests/locales/parity.test.ts +42 -0
- package/node_modules/zod/src/v4/core/tests/locales/tg.test.ts +85 -0
- package/node_modules/zod/src/v4/core/tests/locales/tk.test.ts +69 -0
- package/node_modules/zod/src/v4/core/tests/polyfill-collision.test.ts +46 -0
- package/node_modules/zod/src/v4/core/tests/treeshake.test.ts +51 -0
- package/node_modules/zod/src/v4/core/tests/url-no-canparse.test.ts +133 -0
- package/node_modules/zod/src/v4/core/to-json-schema.ts +283 -48
- package/node_modules/zod/src/v4/core/util.ts +467 -157
- package/node_modules/zod/src/v4/core/versions.ts +2 -2
- package/node_modules/zod/src/v4/core/visit.ts +193 -0
- package/node_modules/zod/src/v4/index.ts +3 -3
- package/node_modules/zod/src/v4/locales/ar.ts +5 -0
- package/node_modules/zod/src/v4/locales/az.ts +5 -0
- package/node_modules/zod/src/v4/locales/be.ts +12 -0
- package/node_modules/zod/src/v4/locales/bg.ts +5 -0
- package/node_modules/zod/src/v4/locales/bn.ts +123 -0
- package/node_modules/zod/src/v4/locales/ca.ts +5 -0
- package/node_modules/zod/src/v4/locales/ckb.ts +140 -0
- package/node_modules/zod/src/v4/locales/cs.ts +5 -0
- package/node_modules/zod/src/v4/locales/da.ts +7 -2
- package/node_modules/zod/src/v4/locales/de.ts +5 -0
- package/node_modules/zod/src/v4/locales/el.ts +3 -0
- package/node_modules/zod/src/v4/locales/en.ts +17 -4
- package/node_modules/zod/src/v4/locales/eo.ts +5 -0
- package/node_modules/zod/src/v4/locales/es.ts +4 -0
- package/node_modules/zod/src/v4/locales/fa.ts +5 -0
- package/node_modules/zod/src/v4/locales/fi.ts +5 -0
- package/node_modules/zod/src/v4/locales/fr-CA.ts +5 -0
- package/node_modules/zod/src/v4/locales/fr.ts +21 -14
- package/node_modules/zod/src/v4/locales/gu.ts +123 -0
- package/node_modules/zod/src/v4/locales/he.ts +8 -1
- package/node_modules/zod/src/v4/locales/hi.ts +126 -0
- package/node_modules/zod/src/v4/locales/hr.ts +4 -0
- package/node_modules/zod/src/v4/locales/hu.ts +5 -0
- package/node_modules/zod/src/v4/locales/hy.ts +11 -0
- package/node_modules/zod/src/v4/locales/id.ts +5 -0
- package/node_modules/zod/src/v4/locales/index.ts +11 -0
- package/node_modules/zod/src/v4/locales/is.ts +5 -0
- package/node_modules/zod/src/v4/locales/it.ts +5 -0
- package/node_modules/zod/src/v4/locales/ja.ts +5 -0
- package/node_modules/zod/src/v4/locales/ka.ts +5 -0
- package/node_modules/zod/src/v4/locales/km.ts +5 -0
- package/node_modules/zod/src/v4/locales/kn.ts +126 -0
- package/node_modules/zod/src/v4/locales/ko.ts +5 -0
- package/node_modules/zod/src/v4/locales/lt.ts +4 -0
- package/node_modules/zod/src/v4/locales/mk.ts +5 -0
- package/node_modules/zod/src/v4/locales/ms.ts +5 -0
- package/node_modules/zod/src/v4/locales/ne.ts +128 -0
- package/node_modules/zod/src/v4/locales/nl.ts +5 -0
- package/node_modules/zod/src/v4/locales/nn.ts +121 -0
- package/node_modules/zod/src/v4/locales/no.ts +7 -2
- package/node_modules/zod/src/v4/locales/ota.ts +5 -0
- package/node_modules/zod/src/v4/locales/pl.ts +5 -0
- package/node_modules/zod/src/v4/locales/ps.ts +5 -0
- package/node_modules/zod/src/v4/locales/pt-BR.ts +161 -0
- package/node_modules/zod/src/v4/locales/pt.ts +101 -58
- package/node_modules/zod/src/v4/locales/ro.ts +3 -0
- package/node_modules/zod/src/v4/locales/ru.ts +12 -0
- package/node_modules/zod/src/v4/locales/sk.ts +123 -0
- package/node_modules/zod/src/v4/locales/sl.ts +5 -0
- package/node_modules/zod/src/v4/locales/sv.ts +7 -2
- package/node_modules/zod/src/v4/locales/ta.ts +5 -0
- package/node_modules/zod/src/v4/locales/tg.ts +135 -0
- package/node_modules/zod/src/v4/locales/th.ts +5 -0
- package/node_modules/zod/src/v4/locales/tk.ts +113 -0
- package/node_modules/zod/src/v4/locales/tr.ts +5 -0
- package/node_modules/zod/src/v4/locales/uk.ts +5 -0
- package/node_modules/zod/src/v4/locales/ur.ts +5 -0
- package/node_modules/zod/src/v4/locales/uz.ts +3 -0
- package/node_modules/zod/src/v4/locales/vi.ts +5 -0
- package/node_modules/zod/src/v4/locales/yo.ts +5 -0
- package/node_modules/zod/src/v4/locales/zh-CN.ts +5 -0
- package/node_modules/zod/src/v4/locales/zh-TW.ts +5 -0
- package/node_modules/zod/src/v4/mini/checks.ts +1 -0
- package/node_modules/zod/src/v4/mini/deep-partial.ts +73 -0
- package/node_modules/zod/src/v4/mini/external.ts +12 -1
- package/node_modules/zod/src/v4/mini/in-out.ts +45 -0
- package/node_modules/zod/src/v4/mini/parse.ts +2 -0
- package/node_modules/zod/src/v4/mini/schemas.ts +167 -63
- package/node_modules/zod/src/v4/mini/tests/apply.test.ts +33 -0
- package/node_modules/zod/src/v4/mini/tests/assignability.test.ts +62 -1
- package/node_modules/zod/src/v4/mini/tests/checks.test.ts +14 -0
- package/node_modules/zod/src/v4/mini/tests/codec.test.ts +35 -1
- package/node_modules/zod/src/v4/mini/tests/computed.test.ts +11 -17
- package/node_modules/zod/src/v4/mini/tests/cyclic-data.test.ts +84 -0
- package/node_modules/zod/src/v4/mini/tests/deep-partial.test.ts +54 -0
- package/node_modules/zod/src/v4/mini/tests/error.test.ts +23 -4
- package/node_modules/zod/src/v4/mini/tests/functions.test.ts +9 -0
- package/node_modules/zod/src/v4/mini/tests/index.test.ts +158 -5
- package/node_modules/zod/src/v4/mini/tests/number.test.ts +14 -0
- package/node_modules/zod/src/v4/mini/tests/object.test.ts +65 -0
- package/node_modules/zod/src/v4/mini/tests/recursive-types.test.ts +16 -0
- package/node_modules/zod/src/v4/mini/tests/string.test.ts +44 -0
- package/node_modules/zod/v3/ZodError.cjs +41 -12
- package/node_modules/zod/v3/ZodError.d.cts +1 -1
- package/node_modules/zod/v3/ZodError.d.ts +1 -1
- package/node_modules/zod/v3/ZodError.js +22 -12
- package/node_modules/zod/v3/errors.cjs +19 -0
- package/node_modules/zod/v3/external.cjs +19 -0
- package/node_modules/zod/v3/helpers/enumUtil.cjs +19 -0
- package/node_modules/zod/v3/helpers/errorUtil.cjs +20 -1
- package/node_modules/zod/v3/helpers/errorUtil.js +1 -1
- package/node_modules/zod/v3/helpers/parseUtil.cjs +19 -0
- package/node_modules/zod/v3/helpers/partialUtil.cjs +19 -0
- package/node_modules/zod/v3/helpers/typeAliases.cjs +19 -0
- package/node_modules/zod/v3/helpers/util.cjs +19 -0
- package/node_modules/zod/v3/index.cjs +19 -0
- package/node_modules/zod/v3/standard-schema.cjs +19 -0
- package/node_modules/zod/v3/types.cjs +26 -5
- package/node_modules/zod/v3/types.js +7 -5
- package/node_modules/zod/v4/classic/checks.cjs +21 -1
- package/node_modules/zod/v4/classic/checks.d.cts +1 -1
- package/node_modules/zod/v4/classic/checks.d.ts +1 -1
- package/node_modules/zod/v4/classic/checks.js +1 -1
- package/node_modules/zod/v4/classic/coerce.cjs +19 -0
- package/node_modules/zod/v4/classic/compat.cjs +19 -0
- package/node_modules/zod/v4/classic/compat.d.cts +9 -11
- package/node_modules/zod/v4/classic/compat.d.ts +9 -11
- package/node_modules/zod/v4/classic/deep-partial.cjs +58 -0
- package/node_modules/zod/v4/classic/deep-partial.d.cts +14 -0
- package/node_modules/zod/v4/classic/deep-partial.d.ts +14 -0
- package/node_modules/zod/v4/classic/deep-partial.js +13 -0
- package/node_modules/zod/v4/classic/errors.cjs +62 -34
- package/node_modules/zod/v4/classic/errors.d.cts +3 -4
- package/node_modules/zod/v4/classic/errors.d.ts +3 -4
- package/node_modules/zod/v4/classic/errors.js +43 -34
- package/node_modules/zod/v4/classic/external.cjs +51 -27
- package/node_modules/zod/v4/classic/external.d.cts +5 -2
- package/node_modules/zod/v4/classic/external.d.ts +5 -2
- package/node_modules/zod/v4/classic/external.js +5 -8
- package/node_modules/zod/v4/classic/from-json-schema.cjs +376 -75
- package/node_modules/zod/v4/classic/from-json-schema.js +357 -75
- package/node_modules/zod/v4/classic/in-out.cjs +82 -0
- package/node_modules/zod/v4/classic/in-out.d.cts +8 -0
- package/node_modules/zod/v4/classic/in-out.d.ts +8 -0
- package/node_modules/zod/v4/classic/in-out.js +36 -0
- package/node_modules/zod/v4/classic/index.cjs +21 -2
- package/node_modules/zod/v4/classic/index.d.cts +1 -2
- package/node_modules/zod/v4/classic/index.d.ts +1 -2
- package/node_modules/zod/v4/classic/index.js +2 -2
- package/node_modules/zod/v4/classic/iso.cjs +30 -22
- package/node_modules/zod/v4/classic/iso.d.cts +2 -17
- package/node_modules/zod/v4/classic/iso.d.ts +2 -17
- package/node_modules/zod/v4/classic/iso.js +2 -17
- package/node_modules/zod/v4/classic/parse.cjs +23 -1
- package/node_modules/zod/v4/classic/parse.d.cts +17 -4
- package/node_modules/zod/v4/classic/parse.d.ts +17 -4
- package/node_modules/zod/v4/classic/parse.js +1 -0
- package/node_modules/zod/v4/classic/schemas.cjs +591 -426
- package/node_modules/zod/v4/classic/schemas.d.cts +68 -19
- package/node_modules/zod/v4/classic/schemas.d.ts +68 -19
- package/node_modules/zod/v4/classic/schemas.js +564 -424
- package/node_modules/zod/v4/core/api.cjs +66 -24
- package/node_modules/zod/v4/core/api.d.cts +22 -12
- package/node_modules/zod/v4/core/api.d.ts +22 -12
- package/node_modules/zod/v4/core/api.js +44 -24
- package/node_modules/zod/v4/core/checks.cjs +88 -128
- package/node_modules/zod/v4/core/checks.d.cts +29 -13
- package/node_modules/zod/v4/core/checks.d.ts +29 -13
- package/node_modules/zod/v4/core/checks.js +68 -127
- package/node_modules/zod/v4/core/compile.cjs +1916 -0
- package/node_modules/zod/v4/core/compile.d.cts +65 -0
- package/node_modules/zod/v4/core/compile.d.ts +65 -0
- package/node_modules/zod/v4/core/compile.js +1866 -0
- package/node_modules/zod/v4/core/core.cjs +101 -19
- package/node_modules/zod/v4/core/core.d.cts +16 -4
- package/node_modules/zod/v4/core/core.d.ts +16 -4
- package/node_modules/zod/v4/core/core.js +83 -20
- package/node_modules/zod/v4/core/doc.cjs +31 -9
- package/node_modules/zod/v4/core/doc.d.cts +3 -1
- package/node_modules/zod/v4/core/doc.d.ts +3 -1
- package/node_modules/zod/v4/core/doc.js +12 -9
- package/node_modules/zod/v4/core/errors.cjs +126 -25
- package/node_modules/zod/v4/core/errors.d.cts +4 -0
- package/node_modules/zod/v4/core/errors.d.ts +4 -0
- package/node_modules/zod/v4/core/errors.js +107 -25
- package/node_modules/zod/v4/core/index.cjs +24 -1
- package/node_modules/zod/v4/core/index.d.cts +3 -0
- package/node_modules/zod/v4/core/index.d.ts +3 -0
- package/node_modules/zod/v4/core/index.js +3 -0
- package/node_modules/zod/v4/core/json-schema-generator.cjs +24 -1
- package/node_modules/zod/v4/core/json-schema-generator.d.cts +2 -2
- package/node_modules/zod/v4/core/json-schema-generator.d.ts +2 -2
- package/node_modules/zod/v4/core/json-schema-generator.js +6 -2
- package/node_modules/zod/v4/core/json-schema-processors.cjs +441 -156
- package/node_modules/zod/v4/core/json-schema-processors.d.cts +16 -0
- package/node_modules/zod/v4/core/json-schema-processors.d.ts +16 -0
- package/node_modules/zod/v4/core/json-schema-processors.js +400 -158
- package/node_modules/zod/v4/core/json-schema.cjs +19 -0
- package/node_modules/zod/v4/core/json-schema.d.cts +2 -1
- package/node_modules/zod/v4/core/json-schema.d.ts +2 -1
- package/node_modules/zod/v4/core/memoizer.cjs +360 -0
- package/node_modules/zod/v4/core/memoizer.d.cts +15 -0
- package/node_modules/zod/v4/core/memoizer.d.ts +15 -0
- package/node_modules/zod/v4/core/memoizer.js +311 -0
- package/node_modules/zod/v4/core/parse.cjs +148 -46
- package/node_modules/zod/v4/core/parse.d.cts +14 -11
- package/node_modules/zod/v4/core/parse.d.ts +14 -11
- package/node_modules/zod/v4/core/parse.js +127 -45
- package/node_modules/zod/v4/core/regexes.cjs +54 -17
- package/node_modules/zod/v4/core/regexes.d.cts +5 -0
- package/node_modules/zod/v4/core/regexes.d.ts +5 -0
- package/node_modules/zod/v4/core/regexes.js +32 -15
- package/node_modules/zod/v4/core/registries.cjs +19 -0
- package/node_modules/zod/v4/core/registries.js +2 -2
- package/node_modules/zod/v4/core/schemas.cjs +815 -386
- package/node_modules/zod/v4/core/schemas.d.cts +126 -35
- package/node_modules/zod/v4/core/schemas.d.ts +126 -35
- package/node_modules/zod/v4/core/schemas.js +783 -386
- package/node_modules/zod/v4/core/standard-schema.cjs +19 -0
- package/node_modules/zod/v4/core/to-json-schema.cjs +269 -45
- package/node_modules/zod/v4/core/to-json-schema.d.cts +45 -5
- package/node_modules/zod/v4/core/to-json-schema.d.ts +45 -5
- package/node_modules/zod/v4/core/to-json-schema.js +247 -44
- package/node_modules/zod/v4/core/util.cjs +387 -157
- package/node_modules/zod/v4/core/util.d.cts +81 -1
- package/node_modules/zod/v4/core/util.d.ts +81 -1
- package/node_modules/zod/v4/core/util.js +355 -156
- package/node_modules/zod/v4/core/versions.cjs +21 -2
- package/node_modules/zod/v4/core/versions.d.cts +1 -1
- package/node_modules/zod/v4/core/versions.d.ts +1 -1
- package/node_modules/zod/v4/core/versions.js +2 -2
- package/node_modules/zod/v4/core/visit.cjs +214 -0
- package/node_modules/zod/v4/core/visit.d.cts +30 -0
- package/node_modules/zod/v4/core/visit.d.ts +30 -0
- package/node_modules/zod/v4/core/visit.js +169 -0
- package/node_modules/zod/v4/index.cjs +34 -5
- package/node_modules/zod/v4/index.d.cts +2 -2
- package/node_modules/zod/v4/index.d.ts +2 -2
- package/node_modules/zod/v4/index.js +3 -2
- package/node_modules/zod/v4/locales/ar.cjs +5 -0
- package/node_modules/zod/v4/locales/ar.js +5 -0
- package/node_modules/zod/v4/locales/az.cjs +5 -0
- package/node_modules/zod/v4/locales/az.js +5 -0
- package/node_modules/zod/v4/locales/be.cjs +12 -0
- package/node_modules/zod/v4/locales/be.js +12 -0
- package/node_modules/zod/v4/locales/bg.cjs +5 -0
- package/node_modules/zod/v4/locales/bg.js +5 -0
- package/node_modules/zod/v4/locales/bn.cjs +140 -0
- package/node_modules/zod/v4/locales/bn.d.cts +5 -0
- package/node_modules/zod/v4/locales/bn.d.ts +4 -0
- package/node_modules/zod/v4/locales/bn.js +113 -0
- package/node_modules/zod/v4/locales/ca.cjs +5 -0
- package/node_modules/zod/v4/locales/ca.js +5 -0
- package/node_modules/zod/v4/locales/ckb.cjs +160 -0
- package/node_modules/zod/v4/locales/ckb.d.cts +5 -0
- package/node_modules/zod/v4/locales/ckb.d.ts +4 -0
- package/node_modules/zod/v4/locales/ckb.js +133 -0
- package/node_modules/zod/v4/locales/cs.cjs +5 -0
- package/node_modules/zod/v4/locales/cs.js +5 -0
- package/node_modules/zod/v4/locales/da.cjs +7 -2
- package/node_modules/zod/v4/locales/da.js +7 -2
- package/node_modules/zod/v4/locales/de.cjs +5 -0
- package/node_modules/zod/v4/locales/de.js +5 -0
- package/node_modules/zod/v4/locales/el.cjs +3 -0
- package/node_modules/zod/v4/locales/el.js +3 -0
- package/node_modules/zod/v4/locales/en.cjs +16 -4
- package/node_modules/zod/v4/locales/en.js +16 -4
- package/node_modules/zod/v4/locales/eo.cjs +5 -0
- package/node_modules/zod/v4/locales/eo.js +5 -0
- package/node_modules/zod/v4/locales/es.cjs +4 -0
- package/node_modules/zod/v4/locales/es.js +4 -0
- package/node_modules/zod/v4/locales/fa.cjs +5 -0
- package/node_modules/zod/v4/locales/fa.js +5 -0
- package/node_modules/zod/v4/locales/fi.cjs +5 -0
- package/node_modules/zod/v4/locales/fi.js +5 -0
- package/node_modules/zod/v4/locales/fr-CA.cjs +5 -0
- package/node_modules/zod/v4/locales/fr-CA.js +5 -0
- package/node_modules/zod/v4/locales/fr.cjs +18 -14
- package/node_modules/zod/v4/locales/fr.js +18 -14
- package/node_modules/zod/v4/locales/gu.cjs +140 -0
- package/node_modules/zod/v4/locales/gu.d.cts +5 -0
- package/node_modules/zod/v4/locales/gu.d.ts +4 -0
- package/node_modules/zod/v4/locales/gu.js +113 -0
- package/node_modules/zod/v4/locales/he.cjs +7 -0
- package/node_modules/zod/v4/locales/he.js +7 -0
- package/node_modules/zod/v4/locales/hi.cjs +138 -0
- package/node_modules/zod/v4/locales/hi.d.cts +5 -0
- package/node_modules/zod/v4/locales/hi.d.ts +4 -0
- package/node_modules/zod/v4/locales/hi.js +111 -0
- package/node_modules/zod/v4/locales/hr.cjs +4 -0
- package/node_modules/zod/v4/locales/hr.js +4 -0
- package/node_modules/zod/v4/locales/hu.cjs +5 -0
- package/node_modules/zod/v4/locales/hu.js +5 -0
- package/node_modules/zod/v4/locales/hy.cjs +11 -0
- package/node_modules/zod/v4/locales/hy.js +11 -0
- package/node_modules/zod/v4/locales/id.cjs +5 -0
- package/node_modules/zod/v4/locales/id.js +5 -0
- package/node_modules/zod/v4/locales/index.cjs +43 -2
- package/node_modules/zod/v4/locales/index.d.cts +11 -0
- package/node_modules/zod/v4/locales/index.d.ts +11 -0
- package/node_modules/zod/v4/locales/index.js +11 -0
- package/node_modules/zod/v4/locales/is.cjs +5 -0
- package/node_modules/zod/v4/locales/is.js +5 -0
- package/node_modules/zod/v4/locales/it.cjs +5 -0
- package/node_modules/zod/v4/locales/it.js +5 -0
- package/node_modules/zod/v4/locales/ja.cjs +5 -0
- package/node_modules/zod/v4/locales/ja.js +5 -0
- package/node_modules/zod/v4/locales/ka.cjs +5 -0
- package/node_modules/zod/v4/locales/ka.js +5 -0
- package/node_modules/zod/v4/locales/km.cjs +5 -0
- package/node_modules/zod/v4/locales/km.js +5 -0
- package/node_modules/zod/v4/locales/kn.cjs +143 -0
- package/node_modules/zod/v4/locales/kn.d.cts +5 -0
- package/node_modules/zod/v4/locales/kn.d.ts +4 -0
- package/node_modules/zod/v4/locales/kn.js +116 -0
- package/node_modules/zod/v4/locales/ko.cjs +5 -0
- package/node_modules/zod/v4/locales/ko.js +5 -0
- package/node_modules/zod/v4/locales/lt.cjs +4 -0
- package/node_modules/zod/v4/locales/lt.js +4 -0
- package/node_modules/zod/v4/locales/mk.cjs +5 -0
- package/node_modules/zod/v4/locales/mk.js +5 -0
- package/node_modules/zod/v4/locales/ms.cjs +5 -0
- package/node_modules/zod/v4/locales/ms.js +5 -0
- package/node_modules/zod/v4/locales/ne.cjs +138 -0
- package/node_modules/zod/v4/locales/ne.d.cts +5 -0
- package/node_modules/zod/v4/locales/ne.d.ts +4 -0
- package/node_modules/zod/v4/locales/ne.js +111 -0
- package/node_modules/zod/v4/locales/nl.cjs +5 -0
- package/node_modules/zod/v4/locales/nl.js +5 -0
- package/node_modules/zod/v4/locales/nn.cjs +140 -0
- package/node_modules/zod/v4/locales/nn.d.cts +5 -0
- package/node_modules/zod/v4/locales/nn.d.ts +4 -0
- package/node_modules/zod/v4/locales/nn.js +113 -0
- package/node_modules/zod/v4/locales/no.cjs +7 -2
- package/node_modules/zod/v4/locales/no.js +7 -2
- package/node_modules/zod/v4/locales/ota.cjs +5 -0
- package/node_modules/zod/v4/locales/ota.js +5 -0
- package/node_modules/zod/v4/locales/pl.cjs +5 -0
- package/node_modules/zod/v4/locales/pl.js +5 -0
- package/node_modules/zod/v4/locales/ps.cjs +5 -0
- package/node_modules/zod/v4/locales/ps.js +5 -0
- package/node_modules/zod/v4/locales/pt-BR.cjs +170 -0
- package/node_modules/zod/v4/locales/pt-BR.d.cts +5 -0
- package/node_modules/zod/v4/locales/pt-BR.d.ts +4 -0
- package/node_modules/zod/v4/locales/pt-BR.js +143 -0
- package/node_modules/zod/v4/locales/pt.cjs +89 -55
- package/node_modules/zod/v4/locales/pt.js +89 -55
- package/node_modules/zod/v4/locales/ro.cjs +3 -0
- package/node_modules/zod/v4/locales/ro.js +3 -0
- package/node_modules/zod/v4/locales/ru.cjs +12 -0
- package/node_modules/zod/v4/locales/ru.js +12 -0
- package/node_modules/zod/v4/locales/sk.cjs +143 -0
- package/node_modules/zod/v4/locales/sk.d.cts +5 -0
- package/node_modules/zod/v4/locales/sk.d.ts +4 -0
- package/node_modules/zod/v4/locales/sk.js +116 -0
- package/node_modules/zod/v4/locales/sl.cjs +5 -0
- package/node_modules/zod/v4/locales/sl.js +5 -0
- package/node_modules/zod/v4/locales/sv.cjs +7 -2
- package/node_modules/zod/v4/locales/sv.js +7 -2
- package/node_modules/zod/v4/locales/ta.cjs +5 -0
- package/node_modules/zod/v4/locales/ta.js +5 -0
- package/node_modules/zod/v4/locales/tg.cjs +144 -0
- package/node_modules/zod/v4/locales/tg.d.cts +5 -0
- package/node_modules/zod/v4/locales/tg.d.ts +4 -0
- package/node_modules/zod/v4/locales/tg.js +117 -0
- package/node_modules/zod/v4/locales/th.cjs +5 -0
- package/node_modules/zod/v4/locales/th.js +5 -0
- package/node_modules/zod/v4/locales/tk.cjs +134 -0
- package/node_modules/zod/v4/locales/tk.d.cts +5 -0
- package/node_modules/zod/v4/locales/tk.d.ts +4 -0
- package/node_modules/zod/v4/locales/tk.js +107 -0
- package/node_modules/zod/v4/locales/tr.cjs +5 -0
- package/node_modules/zod/v4/locales/tr.js +5 -0
- package/node_modules/zod/v4/locales/uk.cjs +5 -0
- package/node_modules/zod/v4/locales/uk.js +5 -0
- package/node_modules/zod/v4/locales/ur.cjs +5 -0
- package/node_modules/zod/v4/locales/ur.js +5 -0
- package/node_modules/zod/v4/locales/uz.cjs +3 -0
- package/node_modules/zod/v4/locales/uz.js +3 -0
- package/node_modules/zod/v4/locales/vi.cjs +5 -0
- package/node_modules/zod/v4/locales/vi.js +5 -0
- package/node_modules/zod/v4/locales/yo.cjs +5 -0
- package/node_modules/zod/v4/locales/yo.js +5 -0
- package/node_modules/zod/v4/locales/zh-CN.cjs +5 -0
- package/node_modules/zod/v4/locales/zh-CN.js +5 -0
- package/node_modules/zod/v4/locales/zh-TW.cjs +5 -0
- package/node_modules/zod/v4/locales/zh-TW.js +5 -0
- package/node_modules/zod/v4/mini/checks.cjs +21 -1
- package/node_modules/zod/v4/mini/checks.d.cts +1 -1
- package/node_modules/zod/v4/mini/checks.d.ts +1 -1
- package/node_modules/zod/v4/mini/checks.js +1 -1
- package/node_modules/zod/v4/mini/coerce.cjs +19 -0
- package/node_modules/zod/v4/mini/deep-partial.cjs +58 -0
- package/node_modules/zod/v4/mini/deep-partial.d.cts +14 -0
- package/node_modules/zod/v4/mini/deep-partial.d.ts +14 -0
- package/node_modules/zod/v4/mini/deep-partial.js +13 -0
- package/node_modules/zod/v4/mini/external.cjs +33 -1
- package/node_modules/zod/v4/mini/external.d.cts +5 -2
- package/node_modules/zod/v4/mini/external.d.ts +5 -2
- package/node_modules/zod/v4/mini/external.js +3 -1
- package/node_modules/zod/v4/mini/in-out.cjs +82 -0
- package/node_modules/zod/v4/mini/in-out.d.cts +8 -0
- package/node_modules/zod/v4/mini/in-out.d.ts +8 -0
- package/node_modules/zod/v4/mini/in-out.js +36 -0
- package/node_modules/zod/v4/mini/index.cjs +19 -0
- package/node_modules/zod/v4/mini/iso.cjs +19 -0
- package/node_modules/zod/v4/mini/parse.cjs +22 -1
- package/node_modules/zod/v4/mini/parse.d.cts +1 -1
- package/node_modules/zod/v4/mini/parse.d.ts +1 -1
- package/node_modules/zod/v4/mini/parse.js +1 -1
- package/node_modules/zod/v4/mini/schemas.cjs +117 -53
- package/node_modules/zod/v4/mini/schemas.d.cts +49 -14
- package/node_modules/zod/v4/mini/schemas.d.ts +49 -14
- package/node_modules/zod/v4/mini/schemas.js +92 -51
- package/node_modules/zod/v4-mini/index.cjs +19 -0
- package/package.json +7 -7
- package/prepare.mjs +109 -4
- package/runtime-package.json +13 -8
- package/shipping-sbom.cdx.json +167 -168
- package/shipping-source.json +12 -12
- package/node_modules/zod/src/v4/core/config.ts +0 -15
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/README.md +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.js +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/index.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.js +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/memory.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.js +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/noop.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.js +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/conformance.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.js +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/index.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/types.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/types.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode/dist → pi-ai/node_modules/@earendil-works/pi-telemetry/dist/testing}/types.js +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/dist/testing/types.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry → pi-ai/node_modules/@earendil-works/pi-telemetry}/package.json +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/README.md +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/cloudflare.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/declarations.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/identifier.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/index.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/portable.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/execution.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/host.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/inline.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/prelude-source.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/protocol.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/remote.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/vm.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/runtime/worker.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/source.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/types.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/types.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-telemetry/dist/testing → pi-coding-agent/node_modules/@earendil-works/pi-codemode/dist}/types.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/types.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.js +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/dist/wasm.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-codemode → pi-coding-agent/node_modules/@earendil-works/pi-codemode}/package.json +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/CHANGELOG.md +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/LICENSES/modelcontextprotocol-typescript-sdk.txt +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/README.md +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/auth-provider.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/client.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/index.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/callback.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/discovery.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/errors.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/flow.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/index.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/provider.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/oauth/types.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/content.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/jsonrpc.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/protocol/types.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/testing/index.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/in-memory.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/stdio.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/streamable-http.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.js +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/dist/transports/transport.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-mcp → pi-coding-agent/node_modules/@earendil-works/pi-mcp}/package.json +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/README.md +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/alt-screen-search.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/autocomplete.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/colors.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/alt-screen-flash.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/box.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/cancellable-loader.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/editor.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/h-stack.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/image.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/input.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/loader.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/markdown.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/mouse-region.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/scroll-view.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/select-list.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/settings-list.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/spacer.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/stack.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/text.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/truncated-text.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/components/v-stack.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/editor-component.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/fuzzy.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/index.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keybindings.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/keys.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/kill-ring.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/latex.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout-node.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/layout.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-modifiers.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-module-path.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/native-platform.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/oklab.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/program-status.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/stdin-buffer.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-colors.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal-image.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/terminal.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-alt-screen.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui-main-screen.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/tui.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/undo-stack.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/utils.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/wheel-scroll.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.d.ts +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.d.ts.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.js +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/dist/word-navigation.js.map +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/clipboard.h +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/README.md +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/build.sh +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/prebuilds/darwin-arm64/darwin-platform.node +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/prebuilds/darwin-x64/darwin-platform.node +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/darwin/src/darwin-platform.m +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/README.md +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/build.sh +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/prebuilds/linux-arm64/linux-platform-x11.node +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/prebuilds/linux-x64/linux-platform-x11.node +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/src/clipboard-worker.h +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/linux/src/linux-platform-x11.c +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/napi.h +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/README.md +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/build.mjs +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/prebuilds/win32-arm64/win32-platform.node +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/prebuilds/win32-x64/win32-platform.node +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/native/win32/src/win32-platform.c +0 -0
- /package/node_modules/@earendil-works/{pi-tui → pi-coding-agent/node_modules/@earendil-works/pi-tui}/package.json +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/LICENSE +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/README.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Agent.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/BalancedPool.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/CacheStorage.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/CacheStore.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Client.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/ClientStats.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Connector.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/ContentType.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Cookies.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Debug.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/DiagnosticsChannel.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Dispatcher.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/EnvHttpProxyAgent.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Errors.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/EventSource.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Fetch.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/GlobalInstallation.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/H2CClient.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Interceptors.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockAgent.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockCallHistory.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockCallHistoryLog.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockClient.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockErrors.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/MockPool.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Pool.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/PoolStats.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/ProxyAgent.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RedirectHandler.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RetryAgent.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RetryHandler.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/RoundRobinPool.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/SnapshotAgent.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Socks5ProxyAgent.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/Util.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/WebSocket.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/api/api-lifecycle.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/client-certificate.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/crawling.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/migrating-from-v7-to-v8.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/mocking-request.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/proxy.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/undici-vs-builtin-fetch.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/best-practices/writing-tests.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/getting-started.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/index.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/site.json +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/docs/docs/type-map.json +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/index-fetch.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/index.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/index.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/abort-signal.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-connect.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-pipeline.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-request.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-stream.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/api-upgrade.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/index.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/api/readable.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/cache/memory-cache-store.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/cache/sqlite-cache-store.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/connect.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/constants.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/diagnostics.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/errors.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/request.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/socks5-client.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/socks5-utils.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/symbols.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/tree.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/core/util.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/agent.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/balanced-pool.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/client-h1.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/client-h2.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/client.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/dispatcher-base.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/dispatcher.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/dispatcher1-wrapper.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/env-http-proxy-agent.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/fixed-queue.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/h2c-client.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/pool-base.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/pool.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/proxy-agent.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/retry-agent.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/round-robin-pool.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/dispatcher/socks5-proxy-agent.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/encoding/index.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/global.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/cache-handler.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/cache-revalidation-handler.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/decorator-handler.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/deduplication-handler.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/redirect-handler.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/handler/retry-handler.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/cache.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/decompress.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/deduplicate.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/dns.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/dump.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/redirect.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/response-error.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/interceptor/retry.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/constants.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/constants.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/llhttp-wasm.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/llhttp_simd-wasm.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/utils.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/llhttp/utils.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-agent.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-call-history.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-client.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-errors.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-interceptor.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-pool.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-symbols.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/mock-utils.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/pending-interceptors-formatter.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/snapshot-agent.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/snapshot-recorder.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/mock/snapshot-utils.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/cache.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/date.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/runtime-features.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/stats.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/util/timers.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cache/cache.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cache/cachestorage.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cache/util.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/constants.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/index.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/parse.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/cookies/util.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/eventsource/eventsource-stream.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/eventsource/eventsource.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/eventsource/util.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/LICENSE +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/body.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/constants.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/data-url.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/formdata-parser.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/formdata.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/global.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/headers.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/index.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/request.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/response.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/fetch/util.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/infra/index.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/subresource-integrity/Readme.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/subresource-integrity/subresource-integrity.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/webidl/index.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/connection.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/constants.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/events.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/frame.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/permessage-deflate.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/receiver.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/sender.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/stream/websocketerror.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/stream/websocketstream.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/util.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/lib/web/websocket/websocket.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/package.json +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/scripts/strip-comments.js +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/README.md +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/agent.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/api.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/balanced-pool.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/cache-interceptor.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/cache.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/client-stats.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/client.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/connector.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/content-type.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/cookies.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/diagnostics-channel.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/dispatcher.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/dispatcher1-wrapper.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/env-http-proxy-agent.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/errors.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/eventsource.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/fetch.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/formdata.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/global-dispatcher.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/global-origin.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/h2c-client.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/handlers.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/header.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/index.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/interceptors.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-agent.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-call-history.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-client.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-errors.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-interceptor.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/mock-pool.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/patch.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/pool-stats.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/pool.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/proxy-agent.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/readable.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/retry-agent.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/retry-handler.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/round-robin-pool.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/snapshot-agent.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/socks5-proxy-agent.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/util.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/utility.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/webidl.d.ts +0 -0
- /package/node_modules/{undici → @earendil-works/pi-coding-agent/node_modules/undici}/types/websocket.d.ts +0 -0
|
@@ -0,0 +1,1041 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright 2026 harrylabsj
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
/**
|
|
17
|
+
* 可选 owned 运行模式(MANAGER-APPROVAL-SCOPE-v2 §B)。
|
|
18
|
+
*
|
|
19
|
+
* 与 SDK / HTTP / Core 无关的**最小持久生命周期**:
|
|
20
|
+
* - owner 唯一性(journal 代际 + O_EXCL guard)
|
|
21
|
+
* - 持久计数(业务转发 / MCP / Core 预留,失败不退还)
|
|
22
|
+
* - window 期限与持久时间锚(provider/host/boot 绑定,未知即 HOLD)
|
|
23
|
+
* - 终态(到期 / 预算 / 进程内 owner stop)与重启拒绝
|
|
24
|
+
*
|
|
25
|
+
* 本模块不做:外部 stop 通道、跨窗额度迁移、真实业务库与计数跨库原子。
|
|
26
|
+
*/
|
|
27
|
+
import { closeSync, existsSync, fsyncSync, mkdirSync, openSync, readFileSync, renameSync, rmdirSync, rmSync, statSync, writeSync } from "node:fs";
|
|
28
|
+
import path from "node:path";
|
|
29
|
+
import { randomBytes, createHash } from "node:crypto";
|
|
30
|
+
import { createRequire } from "node:module";
|
|
31
|
+
import { contentDigest } from "../negotiation/jcs.js";
|
|
32
|
+
import { createOwnedClock, ownedHostBootId } from "./owned-clock.js";
|
|
33
|
+
export { createOwnedClock, ownedHostBootId } from "./owned-clock.js";
|
|
34
|
+
export const requireCjs = createRequire(import.meta.url);
|
|
35
|
+
const OWNED_DIR = "owned";
|
|
36
|
+
export const LEDGER_FILE = "window-ledger.json";
|
|
37
|
+
export const GUARD_FILE = "owner.guard";
|
|
38
|
+
export const JOURNAL_FILE = "journal.sqlite";
|
|
39
|
+
export class OwnedRuntimeError extends Error {
|
|
40
|
+
code;
|
|
41
|
+
constructor(code, message) {
|
|
42
|
+
super(message.startsWith(code) ? message : `${code}: ${message}`);
|
|
43
|
+
this.name = "OwnedRuntimeError";
|
|
44
|
+
this.code = code;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
function fail(code, message) {
|
|
48
|
+
throw new OwnedRuntimeError(code, message);
|
|
49
|
+
}
|
|
50
|
+
function isSqliteBusy(error) {
|
|
51
|
+
const code = String(error?.code ?? "");
|
|
52
|
+
return code === "SQLITE_BUSY" || code === "SQLITE_LOCKED" || /database is locked|database table is locked/i.test(String(error));
|
|
53
|
+
}
|
|
54
|
+
function sha256(input) {
|
|
55
|
+
return createHash("sha256").update(input).digest("hex");
|
|
56
|
+
}
|
|
57
|
+
function canonical(value) {
|
|
58
|
+
return Buffer.from(`${JSON.stringify(value, null, 2)}\n`, "utf8");
|
|
59
|
+
}
|
|
60
|
+
function isPositiveInt(value) {
|
|
61
|
+
return typeof value === "number" && Number.isSafeInteger(value) && value > 0;
|
|
62
|
+
}
|
|
63
|
+
function parseUtc(value, field) {
|
|
64
|
+
if (typeof value !== "string")
|
|
65
|
+
fail("OWNED_POLICY_INVALID", `${field} 必须是 ISO 时间字符串`);
|
|
66
|
+
const ms = Date.parse(value);
|
|
67
|
+
if (!Number.isFinite(ms))
|
|
68
|
+
fail("OWNED_POLICY_INVALID", `${field} 不可解析`);
|
|
69
|
+
return new Date(ms).toISOString();
|
|
70
|
+
}
|
|
71
|
+
/** 严格校验策略:不填补缺省值、不接受多余语义。 */
|
|
72
|
+
export function validateOwnedPolicy(input, nowMs) {
|
|
73
|
+
if (input === null || typeof input !== "object" || Array.isArray(input)) {
|
|
74
|
+
fail("OWNED_POLICY_INVALID", "owned_policy 必须是对象");
|
|
75
|
+
}
|
|
76
|
+
const raw = input;
|
|
77
|
+
const allowed = ["version", "policy_id", "window_id", "window_start_utc", "window_end_utc", "caps"];
|
|
78
|
+
for (const key of Object.keys(raw)) {
|
|
79
|
+
if (!allowed.includes(key))
|
|
80
|
+
fail("OWNED_POLICY_INVALID", `owned_policy 含未知字段:${key}`);
|
|
81
|
+
}
|
|
82
|
+
const version = raw.version;
|
|
83
|
+
if (typeof version !== "string" || version.trim() === "")
|
|
84
|
+
fail("OWNED_POLICY_INVALID", "version 必填");
|
|
85
|
+
const policyId = raw.policy_id;
|
|
86
|
+
if (typeof policyId !== "string" || policyId.trim() === "")
|
|
87
|
+
fail("OWNED_POLICY_INVALID", "policy_id 必填");
|
|
88
|
+
const windowId = raw.window_id;
|
|
89
|
+
if (typeof windowId !== "string" || windowId.trim() === "")
|
|
90
|
+
fail("OWNED_POLICY_INVALID", "window_id 必填");
|
|
91
|
+
const startUtc = parseUtc(raw.window_start_utc, "window_start_utc");
|
|
92
|
+
const endUtc = parseUtc(raw.window_end_utc, "window_end_utc");
|
|
93
|
+
if (Date.parse(endUtc) <= Date.parse(startUtc)) {
|
|
94
|
+
fail("OWNED_POLICY_INVALID", "window_end_utc 必须晚于 window_start_utc");
|
|
95
|
+
}
|
|
96
|
+
const capsRaw = raw.caps;
|
|
97
|
+
if (capsRaw === null || typeof capsRaw !== "object" || Array.isArray(capsRaw)) {
|
|
98
|
+
fail("OWNED_POLICY_INVALID", "caps 必须是对象");
|
|
99
|
+
}
|
|
100
|
+
const caps = capsRaw;
|
|
101
|
+
const capKeys = ["business_requests", "mcp_calls", "core_starts"];
|
|
102
|
+
for (const key of Object.keys(caps)) {
|
|
103
|
+
if (!capKeys.includes(key))
|
|
104
|
+
fail("OWNED_POLICY_INVALID", `caps 含未知字段:${key}`);
|
|
105
|
+
}
|
|
106
|
+
for (const key of capKeys) {
|
|
107
|
+
if (!isPositiveInt(caps[key]))
|
|
108
|
+
fail("OWNED_POLICY_INVALID", `caps.${key} 必须是正整数`);
|
|
109
|
+
}
|
|
110
|
+
// 已过期窗口不允许成为"新"策略,避免用历史夹具开零计数窗口。
|
|
111
|
+
if (Date.parse(endUtc) <= nowMs)
|
|
112
|
+
fail("OWNED_POLICY_EXPIRED", "window_end_utc 已过");
|
|
113
|
+
return {
|
|
114
|
+
version: version.trim(),
|
|
115
|
+
policy_id: policyId.trim(),
|
|
116
|
+
window_id: windowId.trim(),
|
|
117
|
+
window_start_utc: startUtc,
|
|
118
|
+
window_end_utc: endUtc,
|
|
119
|
+
caps: {
|
|
120
|
+
business_requests: caps.business_requests,
|
|
121
|
+
mcp_calls: caps.mcp_calls,
|
|
122
|
+
core_starts: caps.core_starts,
|
|
123
|
+
},
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
/** 平台能力探针:只在**自建独占**子目录内操作,绝不递归删除既有目录或未知内容。 */
|
|
127
|
+
export function probeOwnedCapabilities(parentDir) {
|
|
128
|
+
let probeDir;
|
|
129
|
+
let created = false;
|
|
130
|
+
try {
|
|
131
|
+
const parentStat = statSync(parentDir);
|
|
132
|
+
if (!parentStat.isDirectory())
|
|
133
|
+
fail("OWNED_PLATFORM_UNSUPPORTED", `探针父路径不是目录:${parentDir}`);
|
|
134
|
+
}
|
|
135
|
+
catch (error) {
|
|
136
|
+
fail("OWNED_PLATFORM_UNSUPPORTED", `探针父目录不可用:${error.message}`);
|
|
137
|
+
}
|
|
138
|
+
try {
|
|
139
|
+
probeDir = path.join(parentDir, `probe-${randomBytes(8).toString("hex")}`);
|
|
140
|
+
// 独占创建:已存在即说明不是"我们自己新建的",拒绝(不清理他人内容)。
|
|
141
|
+
mkdirSync(probeDir, { mode: 0o700 });
|
|
142
|
+
created = true;
|
|
143
|
+
const file = path.join(probeDir, "cap");
|
|
144
|
+
const fd = openSync(file, "wx", 0o600);
|
|
145
|
+
try {
|
|
146
|
+
writeSync(fd, "ok");
|
|
147
|
+
fsyncSync(fd);
|
|
148
|
+
}
|
|
149
|
+
finally {
|
|
150
|
+
closeSync(fd);
|
|
151
|
+
}
|
|
152
|
+
try {
|
|
153
|
+
openSync(file, "wx", 0o600);
|
|
154
|
+
fail("OWNED_PLATFORM_UNSUPPORTED", "O_EXCL 语义未生效");
|
|
155
|
+
}
|
|
156
|
+
catch (error) {
|
|
157
|
+
if (error instanceof OwnedRuntimeError)
|
|
158
|
+
throw error;
|
|
159
|
+
}
|
|
160
|
+
const moved = path.join(probeDir, "cap.moved");
|
|
161
|
+
renameSync(file, moved);
|
|
162
|
+
const dirFd = openSync(probeDir, "r");
|
|
163
|
+
try {
|
|
164
|
+
fsyncSync(dirFd);
|
|
165
|
+
}
|
|
166
|
+
finally {
|
|
167
|
+
closeSync(dirFd);
|
|
168
|
+
}
|
|
169
|
+
// 只清理本轮自建且身份可证的对象(独占创建 + 单一已知文件)。
|
|
170
|
+
rmSync(moved, { force: true });
|
|
171
|
+
rmSync(file, { force: true });
|
|
172
|
+
}
|
|
173
|
+
catch (error) {
|
|
174
|
+
if (error instanceof OwnedRuntimeError)
|
|
175
|
+
throw error;
|
|
176
|
+
fail("OWNED_PLATFORM_UNSUPPORTED", `持久能力探针失败:${error.message}`);
|
|
177
|
+
}
|
|
178
|
+
finally {
|
|
179
|
+
if (created && probeDir !== undefined) {
|
|
180
|
+
try {
|
|
181
|
+
// 只用 rmdir:非空(出现未知内容)就保持原样,绝不递归删除。
|
|
182
|
+
rmdirSync(probeDir);
|
|
183
|
+
}
|
|
184
|
+
catch {
|
|
185
|
+
// 非空或无法删除:保留原样,不强行递归删除(未知内容一律不动)。
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
/**
|
|
191
|
+
* 最小 SQLite journal:owner 所有权(held + token)与操作意图。
|
|
192
|
+
*
|
|
193
|
+
* 所有权 CAS 只在 SQL 里做:`UPDATE ... WHERE held=0 OR token_hash=<观察到的旧 token>`,
|
|
194
|
+
* 单语句原子,且**只处置被观察的对象**(旧 token),不做"先读再按路径删除"。
|
|
195
|
+
*/
|
|
196
|
+
export class OwnedJournal {
|
|
197
|
+
db;
|
|
198
|
+
dbPath;
|
|
199
|
+
constructor(db, dbPath) {
|
|
200
|
+
this.db = db;
|
|
201
|
+
this.dbPath = dbPath;
|
|
202
|
+
}
|
|
203
|
+
static open(dbPath) {
|
|
204
|
+
let sqlite;
|
|
205
|
+
try {
|
|
206
|
+
sqlite = requireCjs("node:sqlite");
|
|
207
|
+
}
|
|
208
|
+
catch {
|
|
209
|
+
fail("OWNED_PLATFORM_UNSUPPORTED", "node:sqlite 不可用");
|
|
210
|
+
}
|
|
211
|
+
const db = new sqlite.DatabaseSync(dbPath);
|
|
212
|
+
const journal = new OwnedJournal(db, dbPath);
|
|
213
|
+
journal.migrate();
|
|
214
|
+
return journal;
|
|
215
|
+
}
|
|
216
|
+
migrate() {
|
|
217
|
+
this.db.exec(`
|
|
218
|
+
CREATE TABLE IF NOT EXISTS owner_state (
|
|
219
|
+
id INTEGER PRIMARY KEY CHECK (id = 1),
|
|
220
|
+
generation INTEGER NOT NULL,
|
|
221
|
+
token_hash TEXT NOT NULL,
|
|
222
|
+
held INTEGER NOT NULL DEFAULT 0,
|
|
223
|
+
owner_pid INTEGER,
|
|
224
|
+
owner_boot TEXT,
|
|
225
|
+
owner_at_ms INTEGER,
|
|
226
|
+
pending_json TEXT,
|
|
227
|
+
dispatch_json TEXT,
|
|
228
|
+
last_ledger_sha256 TEXT
|
|
229
|
+
);
|
|
230
|
+
`);
|
|
231
|
+
const cols = this.db.prepare("PRAGMA table_info(owner_state)").all();
|
|
232
|
+
for (const [name, ddl] of [
|
|
233
|
+
["held", "ALTER TABLE owner_state ADD COLUMN held INTEGER NOT NULL DEFAULT 0"],
|
|
234
|
+
["owner_pid", "ALTER TABLE owner_state ADD COLUMN owner_pid INTEGER"],
|
|
235
|
+
["owner_boot", "ALTER TABLE owner_state ADD COLUMN owner_boot TEXT"],
|
|
236
|
+
["owner_at_ms", "ALTER TABLE owner_state ADD COLUMN owner_at_ms INTEGER"],
|
|
237
|
+
]) {
|
|
238
|
+
if (!cols.some((c) => c.name === name))
|
|
239
|
+
this.db.exec(ddl);
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
state() {
|
|
243
|
+
const row = this.db
|
|
244
|
+
.prepare("SELECT generation, token_hash, held, pending_json, dispatch_json, last_ledger_sha256 FROM owner_state WHERE id = 1")
|
|
245
|
+
.get();
|
|
246
|
+
if (row === undefined)
|
|
247
|
+
return undefined;
|
|
248
|
+
return {
|
|
249
|
+
generation: Number(row.generation),
|
|
250
|
+
token_hash: String(row.token_hash),
|
|
251
|
+
held: Number(row.held ?? 0),
|
|
252
|
+
pending_json: row.pending_json === null ? null : String(row.pending_json),
|
|
253
|
+
dispatch_json: row.dispatch_json === null ? null : String(row.dispatch_json),
|
|
254
|
+
last_ledger_sha256: row.last_ledger_sha256 === null ? null : String(row.last_ledger_sha256),
|
|
255
|
+
};
|
|
256
|
+
}
|
|
257
|
+
/**
|
|
258
|
+
* 取得所有权(原子)。
|
|
259
|
+
* - 全新:INSERT(主键冲突即另一进程已建);
|
|
260
|
+
* - 空闲:held=0 时抢占;
|
|
261
|
+
* - 接管:仅当 held=1 且 token_hash 正好等于**观察到的旧 token**(调用方已证明其 owner 已死)。
|
|
262
|
+
* 任何其它情形 changes=0 → 失败,调用方必须 HOLD/BUSY,不得再改任何文件。
|
|
263
|
+
*/
|
|
264
|
+
acquire(identity, observedTokenHash) {
|
|
265
|
+
const current = this.state();
|
|
266
|
+
if (current === undefined) {
|
|
267
|
+
try {
|
|
268
|
+
this.db
|
|
269
|
+
.prepare("INSERT INTO owner_state (id, generation, token_hash, held, owner_pid, owner_boot, owner_at_ms) VALUES (1, 1, ?, 1, ?, ?, ?)")
|
|
270
|
+
.run(identity.tokenHash, identity.pid, identity.hostBootId, identity.atMs);
|
|
271
|
+
}
|
|
272
|
+
catch {
|
|
273
|
+
fail("OWNED_RUNTIME_OWNER_BUSY", "并发首启:owner 行已被创建");
|
|
274
|
+
}
|
|
275
|
+
return 1;
|
|
276
|
+
}
|
|
277
|
+
const next = current.generation + 1;
|
|
278
|
+
const result = observedTokenHash === undefined
|
|
279
|
+
? this.db
|
|
280
|
+
.prepare("UPDATE owner_state SET generation = ?, token_hash = ?, held = 1, owner_pid = ?, owner_boot = ?, owner_at_ms = ? WHERE id = 1 AND held = 0")
|
|
281
|
+
.run(next, identity.tokenHash, identity.pid, identity.hostBootId, identity.atMs)
|
|
282
|
+
: this.db
|
|
283
|
+
.prepare("UPDATE owner_state SET generation = ?, token_hash = ?, held = 1, owner_pid = ?, owner_boot = ?, owner_at_ms = ? WHERE id = 1 AND held = 1 AND token_hash = ?")
|
|
284
|
+
.run(next, identity.tokenHash, identity.pid, identity.hostBootId, identity.atMs, observedTokenHash);
|
|
285
|
+
if (Number(result.changes ?? 0) !== 1) {
|
|
286
|
+
fail("OWNED_RUNTIME_OWNER_BUSY", observedTokenHash === undefined
|
|
287
|
+
? "owner 仍被持有(held=1),拒绝第二 owner"
|
|
288
|
+
: "观察到的 owner 已变化,拒绝基于旧观察的接管");
|
|
289
|
+
}
|
|
290
|
+
return next;
|
|
291
|
+
}
|
|
292
|
+
/** 释放:只释放自己的 token(不按路径、不按时间猜测)。 */
|
|
293
|
+
release(tokenHash) {
|
|
294
|
+
this.db.prepare("UPDATE owner_state SET held = 0 WHERE id = 1 AND token_hash = ? AND held = 1").run(tokenHash);
|
|
295
|
+
}
|
|
296
|
+
/** 每次写账本前确认自己仍是 owner(fencing)。 */
|
|
297
|
+
assertOwner(tokenHash) {
|
|
298
|
+
const row = this.db.prepare("SELECT held, token_hash FROM owner_state WHERE id = 1").get();
|
|
299
|
+
if (row === undefined || Number(row.held ?? 0) !== 1 || String(row.token_hash) !== tokenHash) {
|
|
300
|
+
fail("OWNED_RUNTIME_OWNER_FENCED", "已不是当前 owner,拒绝写入");
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
setPending(operation) {
|
|
304
|
+
const result = this.db
|
|
305
|
+
.prepare("UPDATE owner_state SET pending_json = ? WHERE id = 1 AND pending_json IS NULL AND held = 1 AND token_hash = ?")
|
|
306
|
+
.run(JSON.stringify(operation), operation.token_hash);
|
|
307
|
+
if (Number(result.changes ?? 0) !== 1)
|
|
308
|
+
fail("OWNED_PENDING_EXISTS", "已有未完成的 journal 操作或已非 owner");
|
|
309
|
+
}
|
|
310
|
+
pending() {
|
|
311
|
+
const state = this.state();
|
|
312
|
+
if (state?.pending_json === null || state?.pending_json === undefined)
|
|
313
|
+
return undefined;
|
|
314
|
+
let parsed;
|
|
315
|
+
try {
|
|
316
|
+
parsed = JSON.parse(state.pending_json);
|
|
317
|
+
}
|
|
318
|
+
catch {
|
|
319
|
+
fail("OWNED_JOURNAL_CORRUPT", "pending 记录不是合法 JSON");
|
|
320
|
+
}
|
|
321
|
+
const value = parsed;
|
|
322
|
+
const keys = Object.keys(value).sort();
|
|
323
|
+
const expected = [
|
|
324
|
+
"base_sha256", "generation", "kind", "operation_id", "schema", "target_json", "target_sha256", "token_hash",
|
|
325
|
+
];
|
|
326
|
+
if (JSON.stringify(keys) !== JSON.stringify(expected))
|
|
327
|
+
fail("OWNED_JOURNAL_CORRUPT", "pending 字段集不符");
|
|
328
|
+
if (value.schema !== "kiwi.cloud.owned-pending/1")
|
|
329
|
+
fail("OWNED_JOURNAL_CORRUPT", "pending schema 不符");
|
|
330
|
+
for (const key of ["operation_id", "base_sha256", "target_sha256", "target_json", "token_hash"]) {
|
|
331
|
+
if (typeof value[key] !== "string" || value[key].length === 0) {
|
|
332
|
+
fail("OWNED_JOURNAL_CORRUPT", `pending.${key} 非法`);
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
if (!isPositiveInt(value.generation))
|
|
336
|
+
fail("OWNED_JOURNAL_CORRUPT", "pending.generation 非法");
|
|
337
|
+
if (value.kind !== "terminal" && value.kind !== "count")
|
|
338
|
+
fail("OWNED_JOURNAL_CORRUPT", "pending.kind 非法");
|
|
339
|
+
return value;
|
|
340
|
+
}
|
|
341
|
+
/** 最终确认:清 pending 并记录账本摘要,只在账本写入+读回之后调用。 */
|
|
342
|
+
finalize(ledgerSha256) {
|
|
343
|
+
const result = this.db
|
|
344
|
+
.prepare("UPDATE owner_state SET pending_json = NULL, last_ledger_sha256 = ? WHERE id = 1")
|
|
345
|
+
.run(ledgerSha256);
|
|
346
|
+
if (Number(result.changes ?? 0) !== 1)
|
|
347
|
+
fail("OWNED_JOURNAL_FINALIZE", "journal 最终确认失败");
|
|
348
|
+
}
|
|
349
|
+
close() {
|
|
350
|
+
this.db.close();
|
|
351
|
+
}
|
|
352
|
+
}
|
|
353
|
+
export function ownedLayout(dataDir) {
|
|
354
|
+
const dir = path.join(dataDir, OWNED_DIR);
|
|
355
|
+
return {
|
|
356
|
+
dir,
|
|
357
|
+
ledger: path.join(dir, LEDGER_FILE),
|
|
358
|
+
guard: path.join(dir, GUARD_FILE),
|
|
359
|
+
journal: path.join(dir, JOURNAL_FILE),
|
|
360
|
+
};
|
|
361
|
+
}
|
|
362
|
+
export function classifyDataDir(dataDir, layout) {
|
|
363
|
+
const ownedExists = existsSync(layout.dir);
|
|
364
|
+
let dataDirEntries = [];
|
|
365
|
+
try {
|
|
366
|
+
dataDirEntries = existsSync(dataDir)
|
|
367
|
+
? requireCjs("node:fs").readdirSync(dataDir).filter((name) => name !== OWNED_DIR)
|
|
368
|
+
: [];
|
|
369
|
+
}
|
|
370
|
+
catch {
|
|
371
|
+
fail("OWNED_DATA_DIR_UNREADABLE", `无法读取 dataDir:${dataDir}`);
|
|
372
|
+
}
|
|
373
|
+
if (!ownedExists)
|
|
374
|
+
return dataDirEntries.length === 0 ? "FRESH" : "LEGACY";
|
|
375
|
+
const required = [layout.ledger, layout.journal];
|
|
376
|
+
const allThere = required.every((file) => existsSync(file));
|
|
377
|
+
if (!allThere)
|
|
378
|
+
return "PARTIAL";
|
|
379
|
+
return "ACTIVE";
|
|
380
|
+
}
|
|
381
|
+
function readJsonFile(file) {
|
|
382
|
+
return JSON.parse(readFileSync(file, "utf8"));
|
|
383
|
+
}
|
|
384
|
+
function atomicWrite(target, bytes) {
|
|
385
|
+
const tmp = `${target}.tmp-${randomBytes(6).toString("hex")}`;
|
|
386
|
+
const fd = openSync(tmp, "wx", 0o600);
|
|
387
|
+
try {
|
|
388
|
+
writeSync(fd, bytes);
|
|
389
|
+
fsyncSync(fd);
|
|
390
|
+
}
|
|
391
|
+
finally {
|
|
392
|
+
closeSync(fd);
|
|
393
|
+
}
|
|
394
|
+
renameSync(tmp, target);
|
|
395
|
+
const dirFd = openSync(path.dirname(target), "r");
|
|
396
|
+
try {
|
|
397
|
+
fsyncSync(dirFd);
|
|
398
|
+
}
|
|
399
|
+
finally {
|
|
400
|
+
closeSync(dirFd);
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
const LEDGER_KEYS = [
|
|
404
|
+
"schema", "policy_id", "policy_sha256", "window_id", "window_start_utc", "window_end_utc",
|
|
405
|
+
"caps", "counts", "process_boots", "revision", "terminal", "terminal_reason", "anchor", "updated_at_utc",
|
|
406
|
+
];
|
|
407
|
+
const COUNT_KEYS = ["business_requests", "mcp_calls", "core_starts"];
|
|
408
|
+
const TERMINAL_REASONS = [
|
|
409
|
+
"OWNER_STOPPED_PERMANENTLY", "RUNTIME_WINDOW_ENDED", "BUSINESS_REQUESTS_EXHAUSTED",
|
|
410
|
+
"MCP_CALLS_EXHAUSTED", "CORE_STARTS_EXHAUSTED",
|
|
411
|
+
];
|
|
412
|
+
/** 账本语义门:所有真实入口共用,未知终态/计数/时间锚一律在副作用前 HOLD。 */
|
|
413
|
+
function assertLedgerSemantic(value, policy, nowMs) {
|
|
414
|
+
if (value === null || typeof value !== "object" || Array.isArray(value))
|
|
415
|
+
fail("OWNED_RUNTIME_STATE_UNKNOWN", "账本语义不是对象");
|
|
416
|
+
const raw = value;
|
|
417
|
+
const caps = raw.caps;
|
|
418
|
+
const counts = raw.counts;
|
|
419
|
+
for (const key of COUNT_KEYS) {
|
|
420
|
+
if (!isPositiveInt(caps?.[key]))
|
|
421
|
+
fail("OWNED_LEDGER_BOUNDS", `caps.${key} 非法`);
|
|
422
|
+
if (!Number.isSafeInteger(counts?.[key]) || counts[key] < 0 || counts[key] > caps[key]) {
|
|
423
|
+
fail("OWNED_LEDGER_BOUNDS", `counts.${key} 非法`);
|
|
424
|
+
}
|
|
425
|
+
}
|
|
426
|
+
if (!Number.isSafeInteger(raw.revision) || raw.revision < 0)
|
|
427
|
+
fail("OWNED_LEDGER_BOUNDS", "revision 非法");
|
|
428
|
+
if (!Number.isSafeInteger(raw.process_boots) || raw.process_boots < 1)
|
|
429
|
+
fail("OWNED_LEDGER_BOUNDS", "process_boots 非法");
|
|
430
|
+
if (typeof raw.terminal !== "boolean")
|
|
431
|
+
fail("OWNED_LEDGER_BOUNDS", "terminal 非布尔");
|
|
432
|
+
if (raw.terminal) {
|
|
433
|
+
if (typeof raw.terminal_reason !== "string" || !TERMINAL_REASONS.includes(raw.terminal_reason)) {
|
|
434
|
+
fail("OWNED_RUNTIME_TERMINAL_REASON_UNKNOWN", "终态理由未知");
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
else if (raw.terminal_reason !== null) {
|
|
438
|
+
fail("OWNED_LEDGER_BOUNDS", "非终态不得携带 terminal_reason");
|
|
439
|
+
}
|
|
440
|
+
if (raw.terminal) {
|
|
441
|
+
const reason = raw.terminal_reason;
|
|
442
|
+
if (reason === "BUSINESS_REQUESTS_EXHAUSTED" && counts.business_requests < caps.business_requests) {
|
|
443
|
+
fail("OWNED_RUNTIME_TERMINAL_REASON_INCONSISTENT", "业务终态理由与计数不相容");
|
|
444
|
+
}
|
|
445
|
+
if (reason === "MCP_CALLS_EXHAUSTED" && counts.mcp_calls < caps.mcp_calls) {
|
|
446
|
+
fail("OWNED_RUNTIME_TERMINAL_REASON_INCONSISTENT", "MCP终态理由与计数不相容");
|
|
447
|
+
}
|
|
448
|
+
if (reason === "CORE_STARTS_EXHAUSTED" && counts.core_starts < caps.core_starts) {
|
|
449
|
+
fail("OWNED_RUNTIME_TERMINAL_REASON_INCONSISTENT", "Core终态理由与计数不相容");
|
|
450
|
+
}
|
|
451
|
+
if (reason === "RUNTIME_WINDOW_ENDED" && policy !== undefined && nowMs !== undefined && nowMs < Date.parse(policy.window_end_utc)) {
|
|
452
|
+
fail("OWNED_RUNTIME_TERMINAL_REASON_INCONSISTENT", "到期终态理由与当前窗口不相容");
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
const anchor = raw.anchor;
|
|
456
|
+
if (anchor === null || typeof anchor !== "object" ||
|
|
457
|
+
!["DARWIN_MACH_CONTINUOUS_NS", "LINUX_PROC_UPTIME_NS"].includes(String(anchor.provider)) ||
|
|
458
|
+
typeof anchor.host_boot_id !== "string" || anchor.host_boot_id.length === 0 ||
|
|
459
|
+
(typeof anchor.clock_namespace !== "string" && anchor.clock_namespace !== null) ||
|
|
460
|
+
!Number.isSafeInteger(anchor.wall_ms) || typeof anchor.monotonic_ns !== "string" || !/^\d+$/.test(anchor.monotonic_ns))
|
|
461
|
+
fail("OWNED_RUNTIME_CLOCK_IDENTITY_UNKNOWN", "持久时间锚语义未知");
|
|
462
|
+
}
|
|
463
|
+
/**
|
|
464
|
+
* 重启前校验:journal 记录的账本摘要、精确键集、数值范围、计数不超上限、
|
|
465
|
+
* 以及**完整不可变策略**(含 caps/起止,经 policy_sha256)与路径身份绑定。
|
|
466
|
+
* 任何漂移都在副作用前 HOLD。
|
|
467
|
+
*/
|
|
468
|
+
function assertLedgerIntegrity(ledger, journalState, ledgerPath, policy) {
|
|
469
|
+
if (ledger === null || typeof ledger !== "object" || Array.isArray(ledger)) {
|
|
470
|
+
fail("OWNED_RUNTIME_STATE_UNKNOWN", "ledger 不是对象");
|
|
471
|
+
}
|
|
472
|
+
const value = ledger;
|
|
473
|
+
const keys = Object.keys(value).sort();
|
|
474
|
+
if (JSON.stringify(keys) !== JSON.stringify([...LEDGER_KEYS].sort())) {
|
|
475
|
+
fail("OWNED_LEDGER_SCHEMA_DRIFT", `ledger 键集不符:${keys.join(",")}`);
|
|
476
|
+
}
|
|
477
|
+
if (value.schema !== "kiwi.cloud.owned-ledger/1")
|
|
478
|
+
fail("OWNED_LEDGER_SCHEMA_DRIFT", "ledger schema 不符");
|
|
479
|
+
assertLedgerSemantic(value, policy);
|
|
480
|
+
// 可信摘要:journal 必须记录与磁盘一致的内容摘要。
|
|
481
|
+
const bytes = readFileSync(ledgerPath);
|
|
482
|
+
const actual = sha256(bytes);
|
|
483
|
+
if (journalState?.last_ledger_sha256 !== actual) {
|
|
484
|
+
fail("OWNED_LEDGER_DRIFT", "journal 记录的账本摘要与磁盘不一致");
|
|
485
|
+
}
|
|
486
|
+
// 完整不可变策略绑定(含 caps / 起止),不是只看 id。
|
|
487
|
+
if (value.policy_id !== policy.policy_id || value.window_id !== policy.window_id) {
|
|
488
|
+
fail("OWNED_RUNTIME_POLICY_DRIFT", "策略与既有窗口不一致(不允许换窗/换策略)");
|
|
489
|
+
}
|
|
490
|
+
if (value.policy_sha256 !== contentDigest(policy)) {
|
|
491
|
+
fail("OWNED_RUNTIME_POLICY_DRIFT", "策略内容漂移(caps/期限等被改动)");
|
|
492
|
+
}
|
|
493
|
+
if (value.window_start_utc !== policy.window_start_utc || value.window_end_utc !== policy.window_end_utc) {
|
|
494
|
+
fail("OWNED_RUNTIME_POLICY_DRIFT", "窗口起止与策略不一致");
|
|
495
|
+
}
|
|
496
|
+
// 数值范围与计数不超上限。
|
|
497
|
+
const caps = value.caps;
|
|
498
|
+
const counts = value.counts;
|
|
499
|
+
for (const key of COUNT_KEYS) {
|
|
500
|
+
const cap = caps?.[key];
|
|
501
|
+
const used = counts?.[key];
|
|
502
|
+
if (!isPositiveInt(cap))
|
|
503
|
+
fail("OWNED_LEDGER_BOUNDS", `caps.${key} 非法`);
|
|
504
|
+
if (typeof used !== "number" || !Number.isSafeInteger(used) || used < 0) {
|
|
505
|
+
fail("OWNED_LEDGER_BOUNDS", `counts.${key} 非法`);
|
|
506
|
+
}
|
|
507
|
+
if (used > cap)
|
|
508
|
+
fail("OWNED_LEDGER_BOUNDS", `counts.${key} 超过上限`);
|
|
509
|
+
if (cap !== policy.caps[key]) {
|
|
510
|
+
fail("OWNED_RUNTIME_POLICY_DRIFT", `caps.${key} 与策略不一致`);
|
|
511
|
+
}
|
|
512
|
+
}
|
|
513
|
+
}
|
|
514
|
+
/** pending 恢复:只有完整匹配 base/target 与 delta 时才前向应用,否则保留原文件 HOLD。 */
|
|
515
|
+
function recoverPending(pending, ledgerPath, generation, tokenHash, journal) {
|
|
516
|
+
// pending 必须属于"我们刚刚接管的那个 owner/代际",否则拒绝应用。
|
|
517
|
+
if (pending.generation !== generation || pending.token_hash !== tokenHash) {
|
|
518
|
+
fail("OWNED_RUNTIME_PENDING_FOREIGN", "pending 属于其他 owner/代际,拒绝应用");
|
|
519
|
+
}
|
|
520
|
+
if (!existsSync(ledgerPath))
|
|
521
|
+
fail("OWNED_RUNTIME_PENDING_NO_BASE", "pending 存在但账本缺失");
|
|
522
|
+
const currentBytes = readFileSync(ledgerPath);
|
|
523
|
+
const currentSha = sha256(currentBytes);
|
|
524
|
+
if (currentSha === pending.target_sha256) {
|
|
525
|
+
// 已达目标:只需最终确认。
|
|
526
|
+
if (!canonical(JSON.parse(pending.target_json)).equals(currentBytes)) {
|
|
527
|
+
fail("OWNED_RUNTIME_PENDING_TARGET_MISMATCH", "目标摘要相同但字节不一致");
|
|
528
|
+
}
|
|
529
|
+
finalizePendingAfterCheck(ledgerPath, currentBytes);
|
|
530
|
+
journal.finalize(sha256(currentBytes));
|
|
531
|
+
return;
|
|
532
|
+
}
|
|
533
|
+
if (currentSha !== pending.base_sha256) {
|
|
534
|
+
fail("OWNED_RUNTIME_PENDING_BASE_MISMATCH", "当前账本不处于允许的 base/target 状态");
|
|
535
|
+
}
|
|
536
|
+
const base = JSON.parse(currentBytes.toString("utf8"));
|
|
537
|
+
assertLedgerSemantic(base);
|
|
538
|
+
const targetBytes = Buffer.from(pending.target_json, "utf8");
|
|
539
|
+
if (sha256(targetBytes) !== pending.target_sha256) {
|
|
540
|
+
fail("OWNED_RUNTIME_PENDING_TARGET_MISMATCH", "target_json 与 target_sha256 不符");
|
|
541
|
+
}
|
|
542
|
+
const target = JSON.parse(targetBytes.toString("utf8"));
|
|
543
|
+
assertLedgerSemantic(target);
|
|
544
|
+
assertDeltaAllowed(base, target, pending.kind);
|
|
545
|
+
if (!canonical(JSON.parse(targetBytes.toString("utf8"))).equals(targetBytes)) {
|
|
546
|
+
fail("OWNED_RUNTIME_PENDING_TARGET_MISMATCH", "target_json 非规范序列化");
|
|
547
|
+
}
|
|
548
|
+
finalizePendingAfterCheck(ledgerPath, targetBytes);
|
|
549
|
+
journal.finalize(sha256(targetBytes));
|
|
550
|
+
}
|
|
551
|
+
function finalizePendingAfterCheck(ledgerPath, bytes) {
|
|
552
|
+
atomicWrite(ledgerPath, bytes);
|
|
553
|
+
const readBack = readFileSync(ledgerPath);
|
|
554
|
+
if (!readBack.equals(bytes))
|
|
555
|
+
fail("OWNED_RUNTIME_PENDING_READBACK", "恢复写回不一致");
|
|
556
|
+
}
|
|
557
|
+
/** 允许的 delta:计数只增不退、策略/anchor/window 不变、revision 恰好 +1、终态理由合法。 */
|
|
558
|
+
function assertDeltaAllowed(base, target, kind) {
|
|
559
|
+
if (target.schema !== "kiwi.cloud.owned-ledger/1")
|
|
560
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "target schema 不符");
|
|
561
|
+
if (target.policy_sha256 !== base.policy_sha256 || target.policy_id !== base.policy_id || target.window_id !== base.window_id) {
|
|
562
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending 试图改变策略绑定");
|
|
563
|
+
}
|
|
564
|
+
if (JSON.stringify(target.anchor) !== JSON.stringify(base.anchor)) {
|
|
565
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending 试图改变时间锚");
|
|
566
|
+
}
|
|
567
|
+
if (target.window_start_utc !== base.window_start_utc || target.window_end_utc !== base.window_end_utc) {
|
|
568
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending 试图改变窗口");
|
|
569
|
+
}
|
|
570
|
+
if (JSON.stringify(target.caps) !== JSON.stringify(base.caps)) {
|
|
571
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending 试图改变上限");
|
|
572
|
+
}
|
|
573
|
+
if (target.revision !== base.revision + 1)
|
|
574
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending revision 非法");
|
|
575
|
+
if (Date.parse(target.updated_at_utc) < Date.parse(base.updated_at_utc)) {
|
|
576
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending 时间倒退");
|
|
577
|
+
}
|
|
578
|
+
for (const key of ["business_requests", "mcp_calls", "core_starts"]) {
|
|
579
|
+
const before = base.counts[key];
|
|
580
|
+
const after = target.counts[key];
|
|
581
|
+
if (!Number.isSafeInteger(after) || after < before) {
|
|
582
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", `pending 使 ${key} 倒退`);
|
|
583
|
+
}
|
|
584
|
+
if (after > base.caps[key])
|
|
585
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", `pending 使 ${key} 超上限`);
|
|
586
|
+
}
|
|
587
|
+
if (base.terminal && !target.terminal)
|
|
588
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending 试图撤销终态");
|
|
589
|
+
if (!base.terminal && target.terminal) {
|
|
590
|
+
if (kind !== "terminal")
|
|
591
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "非 terminal 操作不得写终态");
|
|
592
|
+
if (typeof target.terminal_reason !== "string" || !TERMINAL_REASONS.includes(target.terminal_reason)) {
|
|
593
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "终态理由不在白名单");
|
|
594
|
+
}
|
|
595
|
+
}
|
|
596
|
+
if (target.process_boots !== base.process_boots) {
|
|
597
|
+
fail("OWNED_RUNTIME_PENDING_DELTA", "pending 试图改变 process_boots");
|
|
598
|
+
}
|
|
599
|
+
}
|
|
600
|
+
export async function startOwnedRuntime(options) {
|
|
601
|
+
const { dataDir, policy } = options;
|
|
602
|
+
const now = options.now ?? Date.now;
|
|
603
|
+
const clock = options.clock ?? createOwnedClock();
|
|
604
|
+
const clockIdentity = clock.identity;
|
|
605
|
+
const layout = ownedLayout(dataDir);
|
|
606
|
+
const crashHook = options.crashHook ?? (() => { });
|
|
607
|
+
const dataClass = classifyDataDir(dataDir, layout);
|
|
608
|
+
if (dataClass === "LEGACY") {
|
|
609
|
+
fail("OWNED_RUNTIME_LEGACY_STATE", `dataDir 非空且无 owned 状态,拒绝初始化:${dataDir}`);
|
|
610
|
+
}
|
|
611
|
+
if (dataClass === "FRESH") {
|
|
612
|
+
// 全新:先确保 dataDir 自身存在(0700);owned/ 随后独占创建。
|
|
613
|
+
try {
|
|
614
|
+
mkdirSync(dataDir, { recursive: true, mode: 0o700 });
|
|
615
|
+
}
|
|
616
|
+
catch (error) {
|
|
617
|
+
fail("OWNED_DATA_DIR_UNWRITABLE", `无法创建 dataDir:${error.message}`);
|
|
618
|
+
}
|
|
619
|
+
}
|
|
620
|
+
// 能力探针:只在 dataDir 下自建**独占随机子目录**,只清理该子目录(非递归、且仅自有对象)。
|
|
621
|
+
probeOwnedCapabilities(options.probeDir ?? dataDir);
|
|
622
|
+
if (dataClass === "FRESH") {
|
|
623
|
+
try {
|
|
624
|
+
mkdirSync(layout.dir, { mode: 0o700 });
|
|
625
|
+
}
|
|
626
|
+
catch (error) {
|
|
627
|
+
if (error.code === "EEXIST") {
|
|
628
|
+
fail("OWNED_RUNTIME_CONCURRENT_INIT", "并发首启:owned 目录已被创建");
|
|
629
|
+
}
|
|
630
|
+
throw error;
|
|
631
|
+
}
|
|
632
|
+
}
|
|
633
|
+
// guard:同一时刻只允许一个 owner 进入;身份(host boot + pid + 代际)随 guard 落盘,
|
|
634
|
+
// 只有"同一 host boot 且该 pid 已不存在"才视为可证明的 dead owner,可接管;
|
|
635
|
+
// 未知身份(跨 boot / 解析失败 / guard 损坏)一律 HOLD,不按 mtime 或超时清锁。
|
|
636
|
+
const token = randomBytes(16).toString("hex");
|
|
637
|
+
const tokenHash = sha256(token);
|
|
638
|
+
const hostBootId = ownedHostBootId(clockIdentity);
|
|
639
|
+
const guardBody = (generation) => `${JSON.stringify({ schema: "kiwi.cloud.owned-owner-guard/1", token_hash: tokenHash, host_boot_id: hostBootId, pid: process.pid, generation, at_ms: now() })}\n`;
|
|
640
|
+
/** 读取既有 guard 并判定其 owner 是否可证明已死;结构未知一律 HOLD。 */
|
|
641
|
+
const readGuard = () => {
|
|
642
|
+
if (!existsSync(layout.guard))
|
|
643
|
+
return undefined;
|
|
644
|
+
let existing;
|
|
645
|
+
try {
|
|
646
|
+
existing = JSON.parse(readFileSync(layout.guard, "utf8"));
|
|
647
|
+
}
|
|
648
|
+
catch {
|
|
649
|
+
fail("OWNED_RUNTIME_UNKNOWN_OWNER", "owner guard 损坏,无法判定存活");
|
|
650
|
+
}
|
|
651
|
+
if (existing === undefined ||
|
|
652
|
+
existing.schema !== "kiwi.cloud.owned-owner-guard/1" ||
|
|
653
|
+
typeof existing.host_boot_id !== "string" ||
|
|
654
|
+
typeof existing.pid !== "number" ||
|
|
655
|
+
typeof existing.generation !== "number" ||
|
|
656
|
+
typeof existing.token_hash !== "string") {
|
|
657
|
+
fail("OWNED_RUNTIME_UNKNOWN_OWNER", "owner guard 结构未知,拒绝接管");
|
|
658
|
+
}
|
|
659
|
+
if (existing.host_boot_id !== hostBootId) {
|
|
660
|
+
fail("OWNED_RUNTIME_UNKNOWN_OWNER", "owner 来自不同 host boot,无法证明已死");
|
|
661
|
+
}
|
|
662
|
+
let alive = true;
|
|
663
|
+
try {
|
|
664
|
+
process.kill(existing.pid, 0);
|
|
665
|
+
}
|
|
666
|
+
catch (error) {
|
|
667
|
+
alive = error.code === "EPERM";
|
|
668
|
+
}
|
|
669
|
+
return { token_hash: existing.token_hash, generation: existing.generation, dead: !alive };
|
|
670
|
+
};
|
|
671
|
+
let guardFd;
|
|
672
|
+
/** guard 仅作诊断标记(所有权在 SQL);写入失败不授予/撤销所有权。 */
|
|
673
|
+
const writeGuard = (generation) => {
|
|
674
|
+
try {
|
|
675
|
+
if (guardFd !== undefined)
|
|
676
|
+
closeSync(guardFd);
|
|
677
|
+
if (existsSync(layout.guard)) {
|
|
678
|
+
renameSync(layout.guard, `${layout.guard}.stale-${Date.now()}`);
|
|
679
|
+
}
|
|
680
|
+
guardFd = openSync(layout.guard, "w", 0o600);
|
|
681
|
+
writeSync(guardFd, guardBody(generation));
|
|
682
|
+
fsyncSync(guardFd);
|
|
683
|
+
}
|
|
684
|
+
catch (error) {
|
|
685
|
+
fail("OWNED_RUNTIME_GUARD_WRITE", `guard 写入失败:${error.message}`);
|
|
686
|
+
}
|
|
687
|
+
};
|
|
688
|
+
if (dataClass === "PARTIAL") {
|
|
689
|
+
fail("OWNED_RUNTIME_STATE_UNKNOWN", `owned 状态不完整:${layout.dir}`);
|
|
690
|
+
}
|
|
691
|
+
let journal;
|
|
692
|
+
try {
|
|
693
|
+
journal = OwnedJournal.open(layout.journal);
|
|
694
|
+
}
|
|
695
|
+
catch (error) {
|
|
696
|
+
if (isSqliteBusy(error))
|
|
697
|
+
fail("OWNED_RUNTIME_OWNER_BUSY", "SQLite owner journal 正在被其他 owner 写入");
|
|
698
|
+
throw error;
|
|
699
|
+
}
|
|
700
|
+
let ownerReleased = false;
|
|
701
|
+
let acquiredOwner = false;
|
|
702
|
+
const releaseOwner = () => {
|
|
703
|
+
if (ownerReleased)
|
|
704
|
+
return;
|
|
705
|
+
ownerReleased = true;
|
|
706
|
+
// 只有真正取得过所有权才释放/清理 guard;失败路径保留现场(不清他人的锁)。
|
|
707
|
+
if (acquiredOwner) {
|
|
708
|
+
try {
|
|
709
|
+
if (guardFd !== undefined)
|
|
710
|
+
closeSync(guardFd);
|
|
711
|
+
}
|
|
712
|
+
catch {
|
|
713
|
+
/* ignore */
|
|
714
|
+
}
|
|
715
|
+
try {
|
|
716
|
+
rmSync(layout.guard, { force: true });
|
|
717
|
+
}
|
|
718
|
+
catch {
|
|
719
|
+
/* ignore */
|
|
720
|
+
}
|
|
721
|
+
journal.release(tokenHash);
|
|
722
|
+
}
|
|
723
|
+
journal.close();
|
|
724
|
+
};
|
|
725
|
+
try {
|
|
726
|
+
// 所有权:SQL CAS。held=0 → 抢占;held=1 但观察到的是可证明已死的旧 token → 接管。
|
|
727
|
+
const observed = readGuard();
|
|
728
|
+
if (observed !== undefined && !observed.dead) {
|
|
729
|
+
fail("OWNED_RUNTIME_OWNER_BUSY", "guard 显示 owner 仍存活,拒绝启动");
|
|
730
|
+
}
|
|
731
|
+
const prior = journal.state();
|
|
732
|
+
// 只有 journal 标记 held=1 时才走"基于观察旧 token 的接管 CAS";
|
|
733
|
+
// 否则是空闲状态,用 held=0 抢占。
|
|
734
|
+
const observedToken = prior !== undefined && prior.held === 1 && observed !== undefined ? observed.token_hash : undefined;
|
|
735
|
+
if (prior !== undefined && prior.held === 1 && observedToken !== prior.token_hash) {
|
|
736
|
+
fail("OWNED_RUNTIME_UNKNOWN_OWNER", "guard 与 journal 的 owner 不一致,拒绝接管");
|
|
737
|
+
}
|
|
738
|
+
let generation;
|
|
739
|
+
try {
|
|
740
|
+
generation = journal.acquire({ tokenHash, pid: process.pid, hostBootId, atMs: now() }, observedToken);
|
|
741
|
+
}
|
|
742
|
+
catch (error) {
|
|
743
|
+
if (isSqliteBusy(error))
|
|
744
|
+
fail("OWNED_RUNTIME_OWNER_BUSY", "SQLite owner journal 正在被其他 owner 写入");
|
|
745
|
+
throw error;
|
|
746
|
+
}
|
|
747
|
+
acquiredOwner = true;
|
|
748
|
+
const clockSample = clock.read();
|
|
749
|
+
const pending = journal.pending();
|
|
750
|
+
if (pending !== undefined) {
|
|
751
|
+
recoverPending(pending, layout.ledger, prior.generation, prior.token_hash, journal);
|
|
752
|
+
crashHook("recovered-pending");
|
|
753
|
+
}
|
|
754
|
+
const startMs = now();
|
|
755
|
+
if (startMs >= Date.parse(policy.window_end_utc)) {
|
|
756
|
+
fail("OWNED_RUNTIME_WINDOW_EXPIRED", "策略窗口已结束");
|
|
757
|
+
}
|
|
758
|
+
if (startMs < Date.parse(policy.window_start_utc)) {
|
|
759
|
+
fail("OWNED_RUNTIME_WINDOW_NOT_STARTED", "策略窗口尚未开始");
|
|
760
|
+
}
|
|
761
|
+
const ledgerPath = layout.ledger;
|
|
762
|
+
let ledger;
|
|
763
|
+
if (!existsSync(ledgerPath)) {
|
|
764
|
+
ledger = {
|
|
765
|
+
schema: "kiwi.cloud.owned-ledger/1",
|
|
766
|
+
policy_id: policy.policy_id,
|
|
767
|
+
policy_sha256: contentDigest(policy),
|
|
768
|
+
window_id: policy.window_id,
|
|
769
|
+
window_start_utc: policy.window_start_utc,
|
|
770
|
+
window_end_utc: policy.window_end_utc,
|
|
771
|
+
caps: { ...policy.caps },
|
|
772
|
+
counts: { business_requests: 0, mcp_calls: 0, core_starts: 0 },
|
|
773
|
+
process_boots: generation,
|
|
774
|
+
revision: 0,
|
|
775
|
+
terminal: false,
|
|
776
|
+
terminal_reason: null,
|
|
777
|
+
anchor: {
|
|
778
|
+
provider: clockIdentity.provider,
|
|
779
|
+
host_boot_id: hostBootId,
|
|
780
|
+
clock_namespace: clockIdentity.namespace,
|
|
781
|
+
wall_ms: startMs,
|
|
782
|
+
monotonic_ns: clockSample.monotonicNs,
|
|
783
|
+
},
|
|
784
|
+
updated_at_utc: new Date(startMs).toISOString(),
|
|
785
|
+
};
|
|
786
|
+
atomicWrite(ledgerPath, canonical(ledger));
|
|
787
|
+
journal.finalize(sha256(canonical(ledger)));
|
|
788
|
+
writeGuard(generation);
|
|
789
|
+
}
|
|
790
|
+
else {
|
|
791
|
+
ledger = readJsonFile(ledgerPath);
|
|
792
|
+
assertLedgerIntegrity(ledger, journal.state(), ledgerPath, policy);
|
|
793
|
+
const anchor = ledger.anchor;
|
|
794
|
+
if (anchor.provider !== clockIdentity.provider || anchor.host_boot_id !== hostBootId || anchor.clock_namespace !== clockIdentity.namespace) {
|
|
795
|
+
fail("OWNED_RUNTIME_CLOCK_IDENTITY_DRIFT", "持久时间锚与当前 host/boot/provider/namespace 不一致");
|
|
796
|
+
}
|
|
797
|
+
assertLedgerSemantic(ledger, policy, startMs);
|
|
798
|
+
if (ledger.terminal) {
|
|
799
|
+
fail("OWNED_RUNTIME_STOPPED_PERMANENTLY", `窗口已终态:${ledger.terminal_reason ?? "UNKNOWN"}`);
|
|
800
|
+
}
|
|
801
|
+
ledger = {
|
|
802
|
+
...ledger,
|
|
803
|
+
process_boots: generation,
|
|
804
|
+
revision: ledger.revision + 1,
|
|
805
|
+
updated_at_utc: new Date(startMs).toISOString(),
|
|
806
|
+
};
|
|
807
|
+
atomicWrite(ledgerPath, canonical(ledger));
|
|
808
|
+
journal.finalize(sha256(canonical(ledger)));
|
|
809
|
+
writeGuard(generation);
|
|
810
|
+
}
|
|
811
|
+
let closing = false;
|
|
812
|
+
let forwarding = true;
|
|
813
|
+
const persist = (mutate) => {
|
|
814
|
+
clock.read();
|
|
815
|
+
const current = readJsonFile(ledgerPath);
|
|
816
|
+
assertLedgerSemantic(current, policy, now());
|
|
817
|
+
if (current.terminal)
|
|
818
|
+
fail("OWNED_RUNTIME_TERMINAL", "窗口已终态,拒绝写入");
|
|
819
|
+
journal.assertOwner(tokenHash);
|
|
820
|
+
const next = mutate({ ...current, revision: current.revision + 1, updated_at_utc: new Date(now()).toISOString() });
|
|
821
|
+
atomicWrite(ledgerPath, canonical(next));
|
|
822
|
+
journal.finalize(sha256(canonical(next)));
|
|
823
|
+
return next;
|
|
824
|
+
};
|
|
825
|
+
const terminal = (reason) => {
|
|
826
|
+
clock.read();
|
|
827
|
+
const current = readJsonFile(ledgerPath);
|
|
828
|
+
assertLedgerSemantic(current, policy, now());
|
|
829
|
+
if (current.terminal) {
|
|
830
|
+
if (current.terminal_reason === reason)
|
|
831
|
+
return current;
|
|
832
|
+
fail("OWNED_RUNTIME_TERMINAL_REASON_DRIFT", `已存在终态 ${current.terminal_reason}`);
|
|
833
|
+
}
|
|
834
|
+
const next = {
|
|
835
|
+
...current,
|
|
836
|
+
terminal: true,
|
|
837
|
+
terminal_reason: reason,
|
|
838
|
+
revision: current.revision + 1,
|
|
839
|
+
updated_at_utc: new Date(now()).toISOString(),
|
|
840
|
+
};
|
|
841
|
+
journal.assertOwner(tokenHash);
|
|
842
|
+
const baseBytes = readFileSync(ledgerPath);
|
|
843
|
+
const intentBytes = canonical(next);
|
|
844
|
+
// 注册完整操作:base/target 摘要 + owner 身份;恢复时必须逐项核验。
|
|
845
|
+
journal.setPending({
|
|
846
|
+
schema: "kiwi.cloud.owned-pending/1",
|
|
847
|
+
operation_id: `terminal-${reason}-${next.revision}`,
|
|
848
|
+
kind: "terminal",
|
|
849
|
+
generation,
|
|
850
|
+
token_hash: tokenHash,
|
|
851
|
+
base_sha256: sha256(baseBytes),
|
|
852
|
+
target_sha256: sha256(intentBytes),
|
|
853
|
+
target_json: intentBytes.toString("utf8"),
|
|
854
|
+
});
|
|
855
|
+
crashHook("after-intent-commit");
|
|
856
|
+
atomicWrite(ledgerPath, intentBytes);
|
|
857
|
+
crashHook("after-ledger-replace");
|
|
858
|
+
// 读回确认后才做最终 SQL 确认(清 pending + 记录摘要)。
|
|
859
|
+
const readBack = readFileSync(ledgerPath);
|
|
860
|
+
if (!readBack.equals(intentBytes))
|
|
861
|
+
fail("OWNED_LEDGER_READBACK_MISMATCH", "终态账本读回不一致");
|
|
862
|
+
journal.finalize(sha256(readBack));
|
|
863
|
+
crashHook("after-finalize");
|
|
864
|
+
return next;
|
|
865
|
+
};
|
|
866
|
+
const reserve = (kind) => {
|
|
867
|
+
if (closing || !forwarding)
|
|
868
|
+
fail("OWNED_RUNTIME_STOPPING", "运行期正在关闭");
|
|
869
|
+
if (now() >= Date.parse(policy.window_end_utc)) {
|
|
870
|
+
terminal("RUNTIME_WINDOW_ENDED");
|
|
871
|
+
fail("OWNED_RUNTIME_WINDOW_EXPIRED", "窗口已到期");
|
|
872
|
+
}
|
|
873
|
+
const current = readJsonFile(ledgerPath);
|
|
874
|
+
assertLedgerSemantic(current, policy, now());
|
|
875
|
+
if (current.counts[kind] >= current.caps[kind]) {
|
|
876
|
+
const reason = kind === "business_requests"
|
|
877
|
+
? "BUSINESS_REQUESTS_EXHAUSTED"
|
|
878
|
+
: kind === "mcp_calls"
|
|
879
|
+
? "MCP_CALLS_EXHAUSTED"
|
|
880
|
+
: "CORE_STARTS_EXHAUSTED";
|
|
881
|
+
try {
|
|
882
|
+
terminal(reason);
|
|
883
|
+
}
|
|
884
|
+
catch {
|
|
885
|
+
/* 已终态:保留既有理由,不覆盖 */
|
|
886
|
+
}
|
|
887
|
+
fail(`OWNED_${reason}`, `${kind} 已达上限 ${current.caps[kind]}`);
|
|
888
|
+
}
|
|
889
|
+
persist((ledgerNow) => ({ ...ledgerNow, counts: { ...ledgerNow.counts, [kind]: ledgerNow.counts[kind] + 1 } }));
|
|
890
|
+
};
|
|
891
|
+
// Core 预留必须发生在 bootstrap(Core/listener)之前。
|
|
892
|
+
reserve("core_starts");
|
|
893
|
+
const value = await options.bootstrap();
|
|
894
|
+
const readLedger = () => readJsonFile(ledgerPath);
|
|
895
|
+
const status = () => {
|
|
896
|
+
const current = readLedger();
|
|
897
|
+
return {
|
|
898
|
+
policy_id: current.policy_id,
|
|
899
|
+
window_id: current.window_id,
|
|
900
|
+
window_start_utc: current.window_start_utc,
|
|
901
|
+
window_end_utc: current.window_end_utc,
|
|
902
|
+
counts: { ...current.counts },
|
|
903
|
+
caps: { ...current.caps },
|
|
904
|
+
process_boots: current.process_boots,
|
|
905
|
+
terminal: current.terminal,
|
|
906
|
+
terminal_reason: current.terminal_reason,
|
|
907
|
+
};
|
|
908
|
+
};
|
|
909
|
+
const closeInternal = async (reason) => {
|
|
910
|
+
if (confirmedStop !== undefined)
|
|
911
|
+
return { result: { status: "CLOSED", terminal: true } };
|
|
912
|
+
if (stopping)
|
|
913
|
+
return { result: { status: "HOLD", code: "OWNED_RUNTIME_STOPPING" } };
|
|
914
|
+
if (closing)
|
|
915
|
+
return { result: { status: "CLOSED", terminal: readLedger().terminal } };
|
|
916
|
+
closing = true;
|
|
917
|
+
forwarding = false;
|
|
918
|
+
try {
|
|
919
|
+
let ledgerAfter;
|
|
920
|
+
if (reason !== undefined)
|
|
921
|
+
ledgerAfter = terminal(reason);
|
|
922
|
+
if (options.closeInstance)
|
|
923
|
+
await options.closeInstance(value);
|
|
924
|
+
releaseOwner();
|
|
925
|
+
return { result: { status: "CLOSED", terminal: ledgerAfter?.terminal ?? readLedger().terminal }, ledger: ledgerAfter };
|
|
926
|
+
}
|
|
927
|
+
catch (error) {
|
|
928
|
+
// 关闭失败:保持非转发,暴露 UNKNOWN/HOLD,不宣称成功。
|
|
929
|
+
return { result: { status: "HOLD", code: error.code ?? "OWNED_CLOSE_UNKNOWN" } };
|
|
930
|
+
}
|
|
931
|
+
};
|
|
932
|
+
let stopping = false;
|
|
933
|
+
let stopInFlight;
|
|
934
|
+
let confirmedStop;
|
|
935
|
+
const handle = {
|
|
936
|
+
value,
|
|
937
|
+
status,
|
|
938
|
+
isClosing: () => closing,
|
|
939
|
+
forwardingEnabled: () => forwarding,
|
|
940
|
+
reserveBusiness: () => reserve("business_requests"),
|
|
941
|
+
reserveMcp: () => reserve("mcp_calls"),
|
|
942
|
+
reserveCore: () => reserve("core_starts"),
|
|
943
|
+
async close() {
|
|
944
|
+
const { result } = await closeInternal();
|
|
945
|
+
return result;
|
|
946
|
+
},
|
|
947
|
+
stopPermanently() {
|
|
948
|
+
if (confirmedStop !== undefined)
|
|
949
|
+
return Promise.resolve(confirmedStop);
|
|
950
|
+
if (stopInFlight !== undefined)
|
|
951
|
+
return stopInFlight;
|
|
952
|
+
if (closing || stopping)
|
|
953
|
+
return Promise.resolve({ status: "HOLD", code: "OWNED_RUNTIME_STOPPING" });
|
|
954
|
+
stopping = true;
|
|
955
|
+
stopInFlight = (async () => {
|
|
956
|
+
// 1) 停新请求 2) 校验未决状态 3) 单次时钟样本(到期优先)
|
|
957
|
+
forwarding = false;
|
|
958
|
+
try {
|
|
959
|
+
clock.read();
|
|
960
|
+
}
|
|
961
|
+
catch (error) {
|
|
962
|
+
return { status: "HOLD", code: error.code ?? "OWNED_CLOCK_IDENTITY_UNKNOWN" };
|
|
963
|
+
}
|
|
964
|
+
const state = journal.state();
|
|
965
|
+
if (state?.pending_json !== null && state?.pending_json !== undefined) {
|
|
966
|
+
return { status: "HOLD", code: "OWNED_RUNTIME_STATE_UNKNOWN" };
|
|
967
|
+
}
|
|
968
|
+
if (state?.dispatch_json !== null && state?.dispatch_json !== undefined) {
|
|
969
|
+
return { status: "HOLD", code: "OWNED_RUNTIME_STATE_UNKNOWN" };
|
|
970
|
+
}
|
|
971
|
+
const atMs = now();
|
|
972
|
+
const expired = atMs >= Date.parse(policy.window_end_utc);
|
|
973
|
+
const requestedReason = expired ? "RUNTIME_WINDOW_ENDED" : "OWNER_STOPPED_PERMANENTLY";
|
|
974
|
+
let ledgerAfter;
|
|
975
|
+
const existing = readJsonFile(layout.ledger);
|
|
976
|
+
let reason = requestedReason;
|
|
977
|
+
if (existing.terminal) {
|
|
978
|
+
try {
|
|
979
|
+
assertLedgerSemantic(existing, policy, atMs);
|
|
980
|
+
}
|
|
981
|
+
catch (error) {
|
|
982
|
+
return { status: "HOLD", code: error.code ?? "OWNED_RUNTIME_STATE_UNKNOWN" };
|
|
983
|
+
}
|
|
984
|
+
// 自然终态已经是权威结果:stop 只读回并复用实际 reason,不重写账本。
|
|
985
|
+
reason = existing.terminal_reason;
|
|
986
|
+
ledgerAfter = existing;
|
|
987
|
+
}
|
|
988
|
+
else {
|
|
989
|
+
try {
|
|
990
|
+
ledgerAfter = terminal(requestedReason);
|
|
991
|
+
}
|
|
992
|
+
catch (error) {
|
|
993
|
+
return { status: "HOLD", code: error.code ?? "OWNED_STOP_UNKNOWN" };
|
|
994
|
+
}
|
|
995
|
+
}
|
|
996
|
+
// 读回校验:账本字节、理由、revision、计数、journal ledger sha 必须一致。
|
|
997
|
+
const bytes = readFileSync(layout.ledger);
|
|
998
|
+
const readBack = readJsonFile(layout.ledger);
|
|
999
|
+
const journalState = journal.state();
|
|
1000
|
+
const consistent = canonical(readBack).equals(bytes) &&
|
|
1001
|
+
readBack.terminal === true &&
|
|
1002
|
+
readBack.terminal_reason === reason &&
|
|
1003
|
+
readBack.revision === ledgerAfter.revision &&
|
|
1004
|
+
journalState?.pending_json === null &&
|
|
1005
|
+
journalState?.last_ledger_sha256 === sha256(bytes);
|
|
1006
|
+
if (!consistent)
|
|
1007
|
+
return { status: "HOLD", code: "OWNED_TERMINAL_READBACK_MISMATCH" };
|
|
1008
|
+
// 终态已持久且读回一致;资源释放失败也不能 reject 或谎称仍转发。
|
|
1009
|
+
if (options.closeInstance) {
|
|
1010
|
+
try {
|
|
1011
|
+
await options.closeInstance(value);
|
|
1012
|
+
}
|
|
1013
|
+
catch (error) {
|
|
1014
|
+
releaseOwner();
|
|
1015
|
+
return {
|
|
1016
|
+
status: "HOLD",
|
|
1017
|
+
code: error.code ?? "OWNED_CLOSE_FAILED",
|
|
1018
|
+
reason,
|
|
1019
|
+
revision: readBack.revision,
|
|
1020
|
+
ledger_sha256: sha256(bytes),
|
|
1021
|
+
};
|
|
1022
|
+
}
|
|
1023
|
+
}
|
|
1024
|
+
releaseOwner();
|
|
1025
|
+
return { status: "TERMINAL_CONFIRMED", reason, revision: readBack.revision, ledger_sha256: sha256(bytes) };
|
|
1026
|
+
})().then((result) => {
|
|
1027
|
+
if (result.status === "TERMINAL_CONFIRMED")
|
|
1028
|
+
confirmedStop = result;
|
|
1029
|
+
return result;
|
|
1030
|
+
}, (error) => ({ status: "HOLD", code: error.code ?? "OWNED_STOP_UNKNOWN" }));
|
|
1031
|
+
return stopInFlight;
|
|
1032
|
+
},
|
|
1033
|
+
};
|
|
1034
|
+
return handle;
|
|
1035
|
+
}
|
|
1036
|
+
catch (error) {
|
|
1037
|
+
releaseOwner();
|
|
1038
|
+
throw error;
|
|
1039
|
+
}
|
|
1040
|
+
}
|
|
1041
|
+
//# sourceMappingURL=owned-runtime.js.map
|