failproofai 1.0.11 → 1.0.12-beta.1
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/.next/standalone/.next/BUILD_ID +1 -1
- package/.next/standalone/.next/build-manifest.json +23 -23
- package/.next/standalone/.next/prerender-manifest.json +4 -4
- package/.next/standalone/.next/required-server-files.json +1 -1
- package/.next/standalone/.next/server/app/_global-error/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/_global-error/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/_global-error/page.js +2 -2
- package/.next/standalone/.next/server/app/_global-error/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_global-error.html +1 -1
- package/.next/standalone/.next/server/app/_global-error.rsc +2 -2
- package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/_not-found/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/_not-found/page.js +3 -3
- package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_not-found.html +1 -1
- package/.next/standalone/.next/server/app/_not-found.rsc +3 -3
- package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/api/audit/invite/route.js +5 -6
- package/.next/standalone/.next/server/app/api/audit/invite/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/audit/run/route.js +24 -24
- package/.next/standalone/.next/server/app/api/audit/run/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/audit/status/route.js +2 -2
- package/.next/standalone/.next/server/app/api/audit/status/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/auth/login-request/route.js +4 -5
- package/.next/standalone/.next/server/app/api/auth/login-request/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/auth/login-verify/route.js +6 -7
- package/.next/standalone/.next/server/app/api/auth/login-verify/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/auth/logout/route.js +6 -7
- package/.next/standalone/.next/server/app/api/auth/logout/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/auth/status/route.js +5 -6
- package/.next/standalone/.next/server/app/api/auth/status/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/download/[project]/[session]/route.js +2 -2
- package/.next/standalone/.next/server/app/api/download/[project]/[session]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/audit/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/audit/page/server-reference-manifest.json +2 -2
- package/.next/standalone/.next/server/app/audit/page.js +4 -4
- package/.next/standalone/.next/server/app/audit/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/audit/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/index.html +1 -1
- package/.next/standalone/.next/server/app/index.rsc +3 -3
- package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/page.js +2 -2
- package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/policies/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/policies/page/server-reference-manifest.json +14 -14
- package/.next/standalone/.next/server/app/policies/page.js +7 -7
- package/.next/standalone/.next/server/app/policies/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/policies/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/project/[name]/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/project/[name]/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/project/[name]/page.js +7 -7
- package/.next/standalone/.next/server/app/project/[name]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/project/[name]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/react-loadable-manifest.json +2 -2
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page/server-reference-manifest.json +2 -2
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page.js +8 -8
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/project/[name]/session/[sessionId]/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/projects/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/projects/page/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/server/app/projects/page.js +3 -3
- package/.next/standalone/.next/server/app/projects/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/projects/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/settings/page/build-manifest.json +3 -3
- package/.next/standalone/.next/server/app/settings/page/server-reference-manifest.json +8 -8
- package/.next/standalone/.next/server/app/settings/page.js +10 -10
- package/.next/standalone/.next/server/app/settings/page.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/settings/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/chunks/{[externals]__0qkp92tjfvw8r._.js → [externals]__0vt9i6fqinjne._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[externals]__1x24dzcbbq6-g._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__02vous7mpi2xm._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__03i5o4a840guz._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0__a_je8fsn65._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0_hsnj_a2mvl_._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__1izwqj_ij_9x_._.js → [root-of-the-server]__0f_4g-vazrvxv._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0l-oi4gdtmlo5._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__0swiyzbmvja2d._.js → [root-of-the-server]__0t9ufnv5hi2hq._.js} +5 -5
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0wg9dk8x8bnau._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__12kq3x-h7t7i1._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1a5zkndjwlc13._.js +3 -0
- package/.next/standalone/.next/server/chunks/{[root-of-the-server]__1r7kbfkiw2xmu._.js → [root-of-the-server]__1aaw59g-5uty7._.js} +12 -12
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1hqpg6vgmfexv._.js +3 -0
- package/.next/standalone/.next/server/chunks/_09dz7xva4ce_2._.js +1 -1
- package/.next/standalone/.next/server/chunks/_0hf5q4xzyg40j._.js +1 -1
- package/.next/standalone/.next/server/chunks/_0tovk6q0miud6._.js +1 -1
- package/.next/standalone/.next/server/chunks/_0trp3ycqv17cl._.js +1 -1
- package/.next/standalone/.next/server/chunks/_19011-u44143j._.js +1 -1
- package/.next/standalone/.next/server/chunks/_1ek68lnh2daur._.js +1 -1
- package/.next/standalone/.next/server/chunks/_1vslkoe35wok6._.js +1 -1
- package/.next/standalone/.next/server/chunks/{_1ixl-kxq_ctsa._.js → _1y590mjzpkbos._.js} +2 -2
- package/.next/standalone/.next/server/chunks/package_json_[json]_cjs_1nxcc4vkpxxu7._.js +1 -1
- package/.next/standalone/.next/server/chunks/src_hooks_0_em82s16zfym._.js +5 -0
- package/.next/standalone/.next/server/chunks/src_hooks_builtin-policies_ts_1yq5ybgx1v98e._.js +3 -0
- package/.next/standalone/.next/server/chunks/src_hooks_custom-hooks-loader_ts_0lnb3n3h94wnn._.js +1 -1
- package/.next/standalone/.next/server/chunks/src_hooks_daemon-client_ts_0il_yu1zc0291._.js +1 -1
- package/.next/standalone/.next/server/chunks/src_hooks_fp-home_ts_09kv0bn_4twyh._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__01j58mdcdw0vn._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0588st-tpiuia._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__08ch3staq3ejw._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0_a8z2ldp2v3n._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0vcyntk4snf0f._.js → [root-of-the-server]__0b78b0j8iyv6l._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0bigvy9xmv2ka._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ffu2-38y03ic._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0g8b0kyorya-t._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0h86bl2qf0k_o._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__1_xbg2kx30wp-._.js → [root-of-the-server]__0naevg4bcoh54._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0pia5h3p8re4c._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__075uro8t92s0_._.js → [root-of-the-server]__0pwj2h2efe5f-._.js} +3 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0zn1d4blhd3bu._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1-ey9fgesfbc0._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__15usvs-ms-0hf._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__16gb3_92zvk5x._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__17r4zrwanhp6r._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1avi2kypusyb_._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1lnfv02ucky7m._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1mc9-zlnh656_._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1r7drlqli-ado._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1s2-ck3k3rsoo._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__1l1qgu5mfapkh._.js → [root-of-the-server]__1vx7o8ukefudh._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_0eoura3_9gjb-._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_0pedwblqdoh58._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_128ebxr83nk6g._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/_1_ozgifqv1ssi._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{_1gb0ifpkowwub._.js → _1a3tubds7s7ow._.js} +10 -9
- package/.next/standalone/.next/server/chunks/ssr/_1djqs9i27e4kg._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_next-internal_server_app_policies_page_actions_1sp2-yo5_vm5f.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/app_actions_get-scheduled-audit_ts_0ei9snixb5fd-._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_audit__components_audit-dashboard_tsx_0p9ud47q0xq5w._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_1kp6l3x33jqb6._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_policies_hooks-client_tsx_19dqvpcz0uxur._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_settings_02tf1h47jmhhd._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{node_modules_html-to-image_es_index_1f_ymmaonkksc.js → node_modules_html-to-image_es_index_1i8oid1gc7s1f.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/package_json_[json]_cjs_013tntikdft59._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_06kzv9ddabn3_._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_0agdmptetetdt._.js +5 -0
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_0mdwgjisv4fub._.js +5 -0
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_1cv9_c4l1tzrm._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_daemon-client_ts_0k41_i7jg6ndv._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_pack-cli_ts_0t7me658zqmh_._.js +1 -1
- package/.next/standalone/.next/server/middleware-build-manifest.js +23 -23
- package/.next/standalone/.next/server/middleware.js +2 -2
- package/.next/standalone/.next/server/pages/404.html +1 -1
- package/.next/standalone/.next/server/pages/500.html +1 -1
- package/.next/standalone/.next/server/preview-props.json +3 -3
- package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/server-reference-manifest.json +23 -23
- package/.next/standalone/.next/static/chunks/{0frxv4_m-m2u5.js → 063al_q720fkj.js} +1 -1
- package/.next/standalone/.next/static/chunks/0_zfad4co-t2z.js +1 -0
- package/.next/standalone/.next/static/chunks/0jutamwqz8pg5.js +1 -0
- package/.next/standalone/.next/static/chunks/114hbolvrv94e.js +1 -0
- package/.next/standalone/.next/static/chunks/{37stoe-_yd852.js → 18433qz-8njv3.js} +1 -1
- package/.next/standalone/.next/static/chunks/{1kwj8uqxuv85t.js → 1b32-afqacaen.js} +1 -1
- package/.next/standalone/.next/static/chunks/{44a7k2_62qc-9.js → 1p-hsi58i-6h0.js} +2 -2
- package/.next/standalone/.next/static/chunks/{302llgh97ce6w.js → 2-tf6_7u623kd.js} +1 -1
- package/.next/standalone/.next/static/chunks/{1_c0dc7zqj1n7.js → 24w3x2da9sk49.js} +1 -1
- package/.next/standalone/.next/static/chunks/2tjfp9dirxnku.js +1 -0
- package/.next/standalone/.next/static/chunks/{16z6_d7sp61jm.js → 3-pku9qwv1yfu.js} +1 -1
- package/.next/standalone/.next/static/chunks/{15rm15u5a6dua.js → 42e8zab314654.js} +1 -1
- package/.next/standalone/fp-cloud-cli/CHANGELOG.md +41 -0
- package/.next/standalone/fp-cloud-cli/README.md +42 -1
- package/.next/standalone/fp-cloud-cli/fp_cli/client.py +117 -12
- package/.next/standalone/fp-cloud-cli/fp_cli/commands/fleet_cmds.py +285 -19
- package/.next/standalone/fp-cloud-cli/fp_cli/commands/policies_cmds.py +84 -18
- package/.next/standalone/fp-cloud-cli/fp_cli/enforcement.py +170 -6
- package/.next/standalone/fp-cloud-cli/fp_cli/models.py +89 -6
- package/.next/standalone/fp-cloud-cli/fp_cli/output.py +259 -21
- package/.next/standalone/fp-cloud-cli/fp_cli/policy_check.py +8 -5
- package/.next/standalone/fp-cloud-cli/skill/SKILL.md +2 -2
- package/.next/standalone/fp-cloud-cli/skill/references/commands.md +17 -9
- package/.next/standalone/fp-cloud-cli/tests/test_cloud_jev.py +692 -0
- package/.next/standalone/fp-cloud-cli/tests/test_enforcement_logic.py +46 -0
- package/.next/standalone/fp-cloud-cli/tests/test_output.py +23 -0
- package/.next/standalone/fp-cloud-cli/uv.lock +6 -6
- package/.next/standalone/hermes-plugin/README.md +6 -4
- package/.next/standalone/hermes-plugin/__init__.py +16 -0
- package/.next/standalone/hermes-plugin/client.py +5 -1
- package/.next/standalone/hermes-plugin/plugin.yaml +1 -1
- package/.next/standalone/node_modules/@next/env/package.json +1 -1
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/api/context.js +72 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/api/diag.js +84 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/api/metrics.js +50 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/api/propagation.js +80 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/api/trace.js +70 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/baggage/context-helpers.js +52 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/baggage/internal/baggage-impl.js +44 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/baggage/internal/symbol.js +12 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/baggage/utils.js +41 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/context/NoopContextManager.js +27 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/context/context.js +52 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/context-api.js +16 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/diag/ComponentLogger.js +47 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/diag/consoleLogger.js +73 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/diag/internal/logLevelLogger.js +34 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/diag/types.js +33 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/diag-api.js +20 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/index.js +71 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/internal/global-utils.js +60 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/internal/semver.js +111 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/metrics/Metric.js +18 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/metrics/NoopMeter.js +118 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/metrics/NoopMeterProvider.js +20 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/metrics-api.js +17 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/propagation/NoopTextMapPropagator.js +23 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/propagation/TextMapPropagator.js +36 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/propagation-api.js +17 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/NonRecordingSpan.js +58 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/NoopTracer.js +68 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/NoopTracerProvider.js +21 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/ProxyTracer.js +46 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/ProxyTracerProvider.js +46 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/SamplingResult.js +33 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/context-utils.js +71 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-impl.js +94 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/internal/tracestate-validators.js +35 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/internal/utils.js +16 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/invalid-span-constants.js +25 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/span_kind.js +38 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/spancontext-utils.js +66 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/status.js +29 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace/trace_flags.js +18 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/trace-api.js +17 -0
- package/.next/standalone/node_modules/@opentelemetry/api/build/src/version.js +10 -0
- package/.next/standalone/node_modules/@opentelemetry/api/package.json +96 -0
- package/.next/standalone/node_modules/next/dist/build/swc/index.js +1 -1
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js +2 -2
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo.runtime.prod.js +2 -2
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-route-turbo.runtime.prod.js +1 -1
- package/.next/standalone/node_modules/next/dist/lib/patch-incorrect-lockfile.js +3 -3
- package/.next/standalone/node_modules/next/dist/server/app-render/async-local-storage.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/config.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-turbopack.js +2 -2
- package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-webpack.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/lib/app-info-log.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/lib/generate-agent-files.js +3 -3
- package/.next/standalone/node_modules/next/dist/server/lib/router-server.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/lib/start-server.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/lib/trace/tracer.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/typescript/rules/config.js +2 -2
- package/.next/standalone/node_modules/next/dist/server/use-cache/use-cache-wrapper.js +1 -1
- package/.next/standalone/node_modules/next/dist/telemetry/anonymous-meta.js +1 -1
- package/.next/standalone/node_modules/next/dist/telemetry/events/swc-load-failure.js +1 -1
- package/.next/standalone/node_modules/next/dist/telemetry/events/version.js +2 -2
- package/.next/standalone/node_modules/next/package.json +11 -11
- package/.next/standalone/package.json +11 -11
- package/.next/standalone/sdk/python/CHANGELOG.md +7 -0
- package/.next/standalone/sdk/python/failproofai_sdk/_version.py +1 -1
- package/.next/standalone/sdk/python/pyproject.toml +19 -0
- package/.next/standalone/sdk/python/uv.lock +520 -301
- package/.next/standalone/sdk/typescript/CHANGELOG.md +13 -0
- package/.next/standalone/sdk/typescript/integration/fixtures/mastra-1/package-lock.json +4 -13
- package/.next/standalone/sdk/typescript/integration/fixtures/mastra-1/package.json +2 -1
- package/.next/standalone/sdk/typescript/integration/fixtures/nextjs/package-lock.json +4 -13
- package/.next/standalone/sdk/typescript/integration/fixtures/nextjs/package.json +3 -0
- package/.next/standalone/sdk/typescript/package-lock.json +178 -162
- package/.next/standalone/sdk/typescript/package.json +1 -1
- package/.next/standalone/sdk/typescript/src/version.ts +1 -1
- package/.next/standalone/server.js +1 -1
- package/bin/failproofai.mjs +17 -1
- package/dist/cli.mjs +2866 -1124
- package/dist/worker.mjs +1450 -145
- package/hermes-plugin/README.md +6 -4
- package/hermes-plugin/__init__.py +16 -0
- package/hermes-plugin/client.py +5 -1
- package/hermes-plugin/plugin.yaml +1 -1
- package/package.json +11 -11
- package/src/hooks/agent-roster.ts +172 -0
- package/src/hooks/agent-targets.ts +60 -0
- package/src/hooks/cloud-connection.ts +97 -27
- package/src/hooks/cloud-enrollment-cli.ts +7 -4
- package/src/hooks/cloud-managed-policies.ts +380 -20
- package/src/hooks/cloud-policy-errors.ts +481 -0
- package/src/hooks/config-status.ts +1 -1
- package/src/hooks/custom-hooks-loader.ts +26 -3
- package/src/hooks/daemon-client.ts +9 -4
- package/src/hooks/daemon-service.ts +2 -1
- package/src/hooks/effective-reviewers.ts +22 -1
- package/src/hooks/fp-home.ts +6 -0
- package/src/hooks/handler.ts +235 -18
- package/src/hooks/health-probe.ts +15 -0
- package/src/hooks/integrations.ts +18 -11
- package/src/hooks/jev-cli.ts +197 -0
- package/src/hooks/jev-cloud-connection.ts +92 -0
- package/src/hooks/manager.ts +122 -16
- package/src/hooks/pack-failclosed.ts +2 -0
- package/src/hooks/pack-manifest.ts +8 -1
- package/src/hooks/policy-evaluator.ts +5 -1
- package/src/hooks/policy-registry.ts +3 -2
- package/src/hooks/policy-reviewability.ts +21 -5
- package/src/hooks/semantic/cloud-jev-health.ts +227 -0
- package/src/hooks/semantic/cloud-jev.ts +677 -0
- package/src/hooks/semantic/jev-client.ts +18 -1
- package/src/hooks/semantic/jev-config.ts +173 -3
- package/src/hooks/semantic/jev-review.ts +129 -10
- package/src/hooks/semantic/pack-policies.ts +2 -1
- package/src/hooks/semantic/types.ts +8 -0
- package/src/hooks/session-pause-cli.ts +1 -1
- package/src/hooks/worker-server.ts +5 -1
- package/.next/standalone/.next/server/chunks/[externals]__0hjaw70fchx66._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__07l68zv0hqdiu._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0car70pylmvor._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0u3i025_setk_._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__10a2f6s636yc7._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1qt5u58xrcuk6._.js +0 -3
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_077n_4ip5__fu._.js +0 -3
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_0mqvvxcn6v0op._.js +0 -3
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_0pb7ds5g0vzgn._.js +0 -3
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_1gasm5xkeqmm3._.js +0 -3
- package/.next/standalone/.next/server/chunks/node_modules_posthog-node_dist_entrypoints_index_node_mjs_1q1heqmkhh8l4._.js +0 -3
- package/.next/standalone/.next/server/chunks/src_hooks_1aveq0uhs2t1b._.js +0 -5
- package/.next/standalone/.next/server/chunks/src_hooks_1eem5a7cyqlb2._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0888k4s6spfmh._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0_bflu046ep5j._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0_lbstb5x2t15._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0fdwgktjfhedo._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0s4deza787asx._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__18qe-hu0gwqm4._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1_p_9xe520fex._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1fmhm8_s9i4re._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1g76awtnmimd1._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1pczevlpk5lxh._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/_0dc-of_bn0cim._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_effective-reviewers_ts_1h4wtvo55j16x._.js +0 -5
- package/.next/standalone/.next/static/chunks/0m-tv1y6ghhtk.js +0 -1
- package/.next/standalone/.next/static/chunks/0ol2gj4ntfn56.js +0 -1
- package/.next/standalone/.next/static/chunks/3hj5_7i3nw4zj.js +0 -1
- package/.next/standalone/.next/static/chunks/3iyoapeoq_hup.js +0 -1
- /package/.next/standalone/.next/static/{kEFP3ybXwZdriNEQmWwlH → xq8UgF5yFxty1VWxY2hyn}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{kEFP3ybXwZdriNEQmWwlH → xq8UgF5yFxty1VWxY2hyn}/_clientMiddlewareManifest.js +0 -0
- /package/.next/standalone/.next/static/{kEFP3ybXwZdriNEQmWwlH → xq8UgF5yFxty1VWxY2hyn}/_ssgManifest.js +0 -0
|
@@ -536,6 +536,14 @@ export interface NativeTransportOptions {
|
|
|
536
536
|
allowUnreported?: boolean;
|
|
537
537
|
/** The base URL came from a connection, not from the person (FailproofAI Cloud). */
|
|
538
538
|
derivedBase?: boolean;
|
|
539
|
+
/**
|
|
540
|
+
* FailproofAI Cloud: the reply's `cloud` block (its verdict for the Cloud
|
|
541
|
+
* checks deployed to this machine, CONTRACT C10.4) is carried through as
|
|
542
|
+
* `JevResponse.cloud`, unvalidated — `parseCloudReply` in `cloud-jev.ts`
|
|
543
|
+
* validates it field by field. A reply that carries one may come without
|
|
544
|
+
* `answers` (Cloud's short-circuit asked nothing), which reads as none.
|
|
545
|
+
*/
|
|
546
|
+
cloudReply?: boolean;
|
|
539
547
|
}
|
|
540
548
|
|
|
541
549
|
/**
|
|
@@ -545,7 +553,12 @@ export interface NativeTransportOptions {
|
|
|
545
553
|
*/
|
|
546
554
|
function normalizeNative(body: unknown, sentModel: string, opts: NativeTransportOptions): JevResponse {
|
|
547
555
|
if (!body || typeof body !== "object" || Array.isArray(body)) throw new JevError("malformed", "Jev returned no object");
|
|
548
|
-
const b = body as { model?: unknown; answers?: unknown; usage?: unknown; error?: unknown };
|
|
556
|
+
const b = body as { model?: unknown; answers?: unknown; usage?: unknown; error?: unknown; cloud?: unknown };
|
|
557
|
+
const cloud = opts.cloudReply && b.cloud !== undefined ? { cloud: b.cloud } : {};
|
|
558
|
+
if ((typeof b.answers !== "object" || b.answers === null) && "cloud" in cloud && b.error === undefined) {
|
|
559
|
+
// Cloud's short-circuit: nothing was asked, so there is nothing to answer.
|
|
560
|
+
return { model: typeof b.model === "string" ? scrubSecret(b.model, opts.apiKey) : "", answers: {}, ...cloud };
|
|
561
|
+
}
|
|
549
562
|
if (typeof b.answers !== "object" || b.answers === null) {
|
|
550
563
|
// Gateways sometimes report an upstream failure inside a 200.
|
|
551
564
|
if (b.error !== undefined) {
|
|
@@ -576,6 +589,7 @@ function normalizeNative(body: unknown, sentModel: string, opts: NativeTransport
|
|
|
576
589
|
answers: b.answers as JevResponse["answers"],
|
|
577
590
|
...(usage ? { usage } : {}),
|
|
578
591
|
...(unverified ? { modelUnverified: true } : {}),
|
|
592
|
+
...cloud,
|
|
579
593
|
};
|
|
580
594
|
}
|
|
581
595
|
|
|
@@ -1146,6 +1160,9 @@ export function transportForConfig(input: JevConfig): { transport: JevTransport;
|
|
|
1146
1160
|
// `readAnswers` then holds the reported id to the 1.13 family.
|
|
1147
1161
|
allowUnreported: false,
|
|
1148
1162
|
derivedBase: true,
|
|
1163
|
+
// Cloud's verdict for its own checks, when the request asked for
|
|
1164
|
+
// it (a `cloud` block, CONTRACT C10.3).
|
|
1165
|
+
cloudReply: true,
|
|
1149
1166
|
}),
|
|
1150
1167
|
),
|
|
1151
1168
|
via: "failproofai",
|
|
@@ -89,8 +89,8 @@
|
|
|
89
89
|
*/
|
|
90
90
|
import { closeSync, constants as fsConstants, fstatSync, openSync, readSync, statSync } from "node:fs";
|
|
91
91
|
import { dirname } from "node:path";
|
|
92
|
-
import { readJevCloudCredential, type JevCloudCredential } from "../fp-config";
|
|
93
|
-
import { jevConfigFile } from "../fp-home";
|
|
92
|
+
import { readConfig, readCredentials, readJevCloudCredential, type JevCloudCredential } from "../fp-config";
|
|
93
|
+
import { configFile, credentialsFile, jevConfigFile } from "../fp-home";
|
|
94
94
|
|
|
95
95
|
export type { JevCloudCredential } from "../fp-config";
|
|
96
96
|
|
|
@@ -179,6 +179,15 @@ export const JEV_API_KEY_ENV = "FAILPROOFAI_JEV_API_KEY";
|
|
|
179
179
|
* the evaluator; the two are pinned equal by a test.
|
|
180
180
|
*/
|
|
181
181
|
export const JEV_CONFIG_DEFAULT_TIMEOUT_MS = 3_000;
|
|
182
|
+
/**
|
|
183
|
+
* How long one call waits for FailproofAI Cloud when Cloud's Jev mode asks
|
|
184
|
+
* (CONTRACT C10.2). Longer than the local default above: the call makes one
|
|
185
|
+
* more hop (Cloud selects this machine's checks, forwards to Jev, and decides
|
|
186
|
+
* them) before it answers. A local BYOK `jev.json` keeps its own `timeoutMs`
|
|
187
|
+
* or the default; this one is fixed, because under a Cloud mode `jev.json` is
|
|
188
|
+
* not read at all. Past it, the regex decides alone, as for any fallback.
|
|
189
|
+
*/
|
|
190
|
+
export const CLOUD_JEV_TIMEOUT_MS = 5_000;
|
|
182
191
|
/** Bounds on `timeoutMs`. Every millisecond of it can be added to a tool call. */
|
|
183
192
|
export const MIN_JEV_TIMEOUT_MS = 100;
|
|
184
193
|
export const MAX_JEV_TIMEOUT_MS = 10_000;
|
|
@@ -618,7 +627,15 @@ export function validateJevConfig(
|
|
|
618
627
|
};
|
|
619
628
|
}
|
|
620
629
|
|
|
621
|
-
|
|
630
|
+
// The FailproofAI Cloud provider waits as long as a Cloud Jev mode does (B9):
|
|
631
|
+
// the same extra hop, and `jev setup --provider failproofai` printing 3000 ms
|
|
632
|
+
// misstated what FailproofAI Cloud is given.
|
|
633
|
+
const cfg: JevConfig = {
|
|
634
|
+
provider: kind,
|
|
635
|
+
apiKey,
|
|
636
|
+
mode: DEFAULT_JEV_MODE,
|
|
637
|
+
timeoutMs: kind === JEV_CLOUD_PROVIDER ? CLOUD_JEV_TIMEOUT_MS : JEV_CONFIG_DEFAULT_TIMEOUT_MS,
|
|
638
|
+
};
|
|
622
639
|
|
|
623
640
|
if (o.baseUrl !== undefined) {
|
|
624
641
|
const r = validateBaseUrl(o.baseUrl);
|
|
@@ -1090,6 +1107,159 @@ export function loadJevConfig(): JevConfig | null {
|
|
|
1090
1107
|
}
|
|
1091
1108
|
}
|
|
1092
1109
|
|
|
1110
|
+
// ── FailproofAI Cloud sets the mode ──────────────────────────────────────────
|
|
1111
|
+
|
|
1112
|
+
export interface CloudModeJevConfig {
|
|
1113
|
+
/**
|
|
1114
|
+
* The config to run with: provider `failproofai` on the Cloud Jev
|
|
1115
|
+
* credential, with Cloud's mode — or null: Jev does not run.
|
|
1116
|
+
*/
|
|
1117
|
+
config: JevConfig | null;
|
|
1118
|
+
/**
|
|
1119
|
+
* This machine's FailproofAI Cloud machine id (`credentials.json`
|
|
1120
|
+
* `cloud.machine_id`), sent in the request's `cloud` block so Cloud can find
|
|
1121
|
+
* the checks deployed to this machine. Null when there is none.
|
|
1122
|
+
*/
|
|
1123
|
+
machineId: string | null;
|
|
1124
|
+
/**
|
|
1125
|
+
* Why Jev cannot run in Cloud's mode, for `errors.json` — null when it runs,
|
|
1126
|
+
* and null for `off`, which is not a problem:
|
|
1127
|
+
* - `transcripts_disabled`: connected for decisions only (`--no-transcripts`);
|
|
1128
|
+
* - `jev_unconfigured`: no Cloud Jev credential at all;
|
|
1129
|
+
* - `jev_unconfigured: <detail>`: one exists and cannot be used.
|
|
1130
|
+
*/
|
|
1131
|
+
problem: string | null;
|
|
1132
|
+
}
|
|
1133
|
+
|
|
1134
|
+
/** The contract's message for "Cloud set a Jev mode and this machine has no Cloud Jev credential". */
|
|
1135
|
+
export const JEV_UNCONFIGURED_PROBLEM = "jev_unconfigured";
|
|
1136
|
+
/** The contract's message for "Cloud set a Jev mode on a decisions-only connection" (CONTRACT C10.2). */
|
|
1137
|
+
export const TRANSCRIPTS_DISABLED_PROBLEM = "transcripts_disabled";
|
|
1138
|
+
|
|
1139
|
+
/**
|
|
1140
|
+
* The config to run when FailproofAI Cloud sets this machine's Jev mode
|
|
1141
|
+
* (`active.json` `jevMode`) to `observe` or `enforce` (CONTRACT C10.2).
|
|
1142
|
+
*
|
|
1143
|
+
* The provider is ALWAYS FailproofAI Cloud, on the Cloud Jev credential
|
|
1144
|
+
* (`credentials.json` `jev {url,key}`, only while its connection is still on
|
|
1145
|
+
* this machine), at `<cloud base>/enforcement/v1/jev` — the checks Cloud
|
|
1146
|
+
* deployed to this machine live there, and the verdict for them is computed
|
|
1147
|
+
* there. A local `jev.json` is NOT used while Cloud sets a mode, BYOK provider
|
|
1148
|
+
* or not: Cloud wins, a local `off` included.
|
|
1149
|
+
*
|
|
1150
|
+
* Jev does not run, and `problem` says why, when:
|
|
1151
|
+
* 1. the machine was connected for decisions only (`collector.sessions` is not
|
|
1152
|
+
* `true` in `config.json` — what `--no-transcripts` writes): the standing
|
|
1153
|
+
* rule is that such a connection never switches Jev on, because a Jev call
|
|
1154
|
+
* sends the tool call and the recent prompt;
|
|
1155
|
+
* 2. there is no Cloud Jev credential, or it cannot be used;
|
|
1156
|
+
* 3. there is no FailproofAI Cloud machine id to name.
|
|
1157
|
+
*
|
|
1158
|
+
* Asked twice per gate event on a machine whose Cloud mode asks — once for the
|
|
1159
|
+
* review, once for `errors.json` — and on every event in the warm worker, so
|
|
1160
|
+
* the answer is kept until an input changes (see `jevInputsVersion`).
|
|
1161
|
+
*
|
|
1162
|
+
* Never throws.
|
|
1163
|
+
*/
|
|
1164
|
+
export function loadJevConfigForCloudMode(mode: JevConfigMode): CloudModeJevConfig {
|
|
1165
|
+
if (mode === "off") return { config: null, machineId: null, problem: null };
|
|
1166
|
+
const key = `${mode}\u0000${jevInputsVersion()}`;
|
|
1167
|
+
if (cloudModeMemo?.key === key) return cloudModeMemo.value;
|
|
1168
|
+
const value = computeCloudModeConfig(mode);
|
|
1169
|
+
cloudModeMemo = { key, value };
|
|
1170
|
+
return value;
|
|
1171
|
+
}
|
|
1172
|
+
|
|
1173
|
+
let cloudModeMemo: { key: string; value: CloudModeJevConfig } | null = null;
|
|
1174
|
+
|
|
1175
|
+
/** Forget the memoised answer. Tests only. */
|
|
1176
|
+
export function _resetJevConfigMemoForTest(): void {
|
|
1177
|
+
cloudModeMemo = null;
|
|
1178
|
+
}
|
|
1179
|
+
|
|
1180
|
+
/**
|
|
1181
|
+
* Everything a Cloud-mode config load reads, as one version string: the
|
|
1182
|
+
* credentials file and its directory (whose modes the loader checks), and
|
|
1183
|
+
* `config.json` (the decisions-only switch), plus where those paths point. A
|
|
1184
|
+
* file's version is its device, inode, mode, size and modification and change
|
|
1185
|
+
* times to the nanosecond — an edit, a chmod and a replace-by-rename all move
|
|
1186
|
+
* it, and the change time cannot be set back by the user.
|
|
1187
|
+
*/
|
|
1188
|
+
function jevInputsVersion(): string {
|
|
1189
|
+
const credentials = credentialsFile();
|
|
1190
|
+
const config = configFile();
|
|
1191
|
+
return [
|
|
1192
|
+
process.platform,
|
|
1193
|
+
credentials,
|
|
1194
|
+
statVersion(credentials),
|
|
1195
|
+
statVersion(dirname(credentials)),
|
|
1196
|
+
config,
|
|
1197
|
+
statVersion(config),
|
|
1198
|
+
].join("\u0000");
|
|
1199
|
+
}
|
|
1200
|
+
|
|
1201
|
+
function statVersion(path: string): string {
|
|
1202
|
+
try {
|
|
1203
|
+
const st = statSync(path, { bigint: true });
|
|
1204
|
+
return `${st.dev}:${st.ino}:${st.mode}:${st.size}:${st.mtimeNs}:${st.ctimeNs}`;
|
|
1205
|
+
} catch (err) {
|
|
1206
|
+
return `-${(err as NodeJS.ErrnoException).code ?? "error"}`;
|
|
1207
|
+
}
|
|
1208
|
+
}
|
|
1209
|
+
|
|
1210
|
+
function computeCloudModeConfig(mode: JevConfigMode): CloudModeJevConfig {
|
|
1211
|
+
try {
|
|
1212
|
+
// Decisions only: checked first, because no credential would change it.
|
|
1213
|
+
if (readConfig().collector.sessions !== true) {
|
|
1214
|
+
return { config: null, machineId: null, problem: TRANSCRIPTS_DISABLED_PROBLEM };
|
|
1215
|
+
}
|
|
1216
|
+
const credential = readJevCloudCredential();
|
|
1217
|
+
if (credential.status === "absent") return { config: null, machineId: null, problem: JEV_UNCONFIGURED_PROBLEM };
|
|
1218
|
+
if (credential.status === "refused") {
|
|
1219
|
+
return {
|
|
1220
|
+
config: null,
|
|
1221
|
+
machineId: null,
|
|
1222
|
+
problem: `${JEV_UNCONFIGURED_PROBLEM}: the FailproofAI Cloud Jev credential is refused — ${credential.problem}`,
|
|
1223
|
+
};
|
|
1224
|
+
}
|
|
1225
|
+
const machineId = readCredentials().cloud?.machineId || null;
|
|
1226
|
+
if (!machineId) {
|
|
1227
|
+
return {
|
|
1228
|
+
config: null,
|
|
1229
|
+
machineId: null,
|
|
1230
|
+
problem: `${JEV_UNCONFIGURED_PROBLEM}: this machine has no FailproofAI Cloud machine id (no policy connection in credentials.json)`,
|
|
1231
|
+
};
|
|
1232
|
+
}
|
|
1233
|
+
const raw = {
|
|
1234
|
+
provider: JEV_CLOUD_PROVIDER,
|
|
1235
|
+
baseUrl: jevCloudBaseUrl(cloudBaseFor(credential.credential)),
|
|
1236
|
+
mode,
|
|
1237
|
+
timeoutMs: CLOUD_JEV_TIMEOUT_MS,
|
|
1238
|
+
};
|
|
1239
|
+
const r = validateJevConfig(raw, null, credential.credential);
|
|
1240
|
+
return r.ok
|
|
1241
|
+
? { config: r.value, machineId, problem: null }
|
|
1242
|
+
: { config: null, machineId, problem: `${JEV_UNCONFIGURED_PROBLEM}: the FailproofAI Cloud Jev credential — ${r.problem}` };
|
|
1243
|
+
} catch (err) {
|
|
1244
|
+
return { config: null, machineId: null, problem: `${JEV_UNCONFIGURED_PROBLEM}: ${err instanceof Error ? err.message : String(err)}` };
|
|
1245
|
+
}
|
|
1246
|
+
}
|
|
1247
|
+
|
|
1248
|
+
/**
|
|
1249
|
+
* The Cloud base URL the Jev route hangs off: the connection's own URL when it
|
|
1250
|
+
* is on the credential's origin (so a Cloud served under a path prefix keeps
|
|
1251
|
+
* it, as `config --token` writes it), else the credential's origin.
|
|
1252
|
+
*/
|
|
1253
|
+
function cloudBaseFor(credential: JevCloudCredential): string {
|
|
1254
|
+
try {
|
|
1255
|
+
const cloud = readCredentials().cloud;
|
|
1256
|
+
if (cloud?.url && new URL(cloud.url).origin === new URL(credential.url).origin) return cloud.url;
|
|
1257
|
+
} catch {
|
|
1258
|
+
// Fall through to the origin.
|
|
1259
|
+
}
|
|
1260
|
+
return credential.url;
|
|
1261
|
+
}
|
|
1262
|
+
|
|
1093
1263
|
export interface JevConfigFileForUpdate {
|
|
1094
1264
|
raw: Record<string, unknown>;
|
|
1095
1265
|
/** The file's permission bits (null where they mean nothing). */
|
|
@@ -7,6 +7,13 @@
|
|
|
7
7
|
* `jev.json` never loads the semantic evaluator at all, and its hook path is
|
|
8
8
|
* exactly what it was before two tiers existed.
|
|
9
9
|
*
|
|
10
|
+
* Or once FailproofAI Cloud sets this machine's Jev mode to `observe` or
|
|
11
|
+
* `enforce` (CONTRACT C10): then the call goes to FailproofAI Cloud on the
|
|
12
|
+
* Cloud Jev credential (`JevCallContext.cloud`), Cloud decides the checks it
|
|
13
|
+
* deployed here, and `evaluateCloudSemantic` merges that verdict with the
|
|
14
|
+
* machine's own. Cloud's outcomes are filed as their policy's OWN reviewers
|
|
15
|
+
* (`reviewerKey`), so a `both` policy is cleared by its Cloud checks alone.
|
|
16
|
+
*
|
|
10
17
|
* Everything the request needs comes through the §7 contracts:
|
|
11
18
|
* `transportForConfig` (T1) for the provider, `throttleTransport` (T5) for the
|
|
12
19
|
* cache and rate limit (scoped to the config's provider, endpoint and model;
|
|
@@ -44,17 +51,28 @@
|
|
|
44
51
|
* it distinguishes, which is what `toReview` below does.
|
|
45
52
|
*/
|
|
46
53
|
import { BUILTIN_POLICIES } from "../builtin-policies";
|
|
54
|
+
import { cloudReviewerName } from "../cloud-managed-policies";
|
|
55
|
+
import type { AgentIdentity } from "../agent-targets";
|
|
56
|
+
import { recordJevBudgetDrops } from "../cloud-policy-errors";
|
|
47
57
|
import { normalizePolicyName } from "../policy-registry";
|
|
48
58
|
import { effectiveAuthority, type PolicyAuthority, type RegisteredPolicy } from "../policy-types";
|
|
49
59
|
import type { JevMode, JevReview, TwoTierReview } from "./combine";
|
|
50
60
|
import { DEFAULT_THRESHOLDS_V1 } from "./decide";
|
|
61
|
+
import { evaluateCloudSemantic, type CloudSemanticOutcome } from "./cloud-jev";
|
|
62
|
+
import {
|
|
63
|
+
BREAKER_SKIP_REASON,
|
|
64
|
+
classifyCloudJevReview,
|
|
65
|
+
cloudJevGate,
|
|
66
|
+
recordCloudJevResult,
|
|
67
|
+
reportCloudJevHealth,
|
|
68
|
+
} from "./cloud-jev-health";
|
|
51
69
|
import { DEFAULT_JEV_TIMEOUT_MS, appendVerdictLog, evaluateSemantic, verdictLogRow, type SemanticOutcome } from "./evaluator";
|
|
52
70
|
import * as intentStore from "./intent";
|
|
53
71
|
import { JevError, transportForConfig, type JevTransport } from "./jev-client";
|
|
54
72
|
import { DEFAULT_JEV_MODE, type JevConfig } from "./jev-config";
|
|
55
73
|
import * as jevThrottle from "./jev-throttle";
|
|
56
74
|
import { sessionProjectRoot } from "./session-root";
|
|
57
|
-
import type { SemanticInput } from "./types";
|
|
75
|
+
import type { PolicyOutcome, SemanticInput } from "./types";
|
|
58
76
|
|
|
59
77
|
/**
|
|
60
78
|
* T5's throttle as this file calls it. §7 declares only
|
|
@@ -149,6 +167,18 @@ export interface JevCallContext {
|
|
|
149
167
|
permissionMode?: string;
|
|
150
168
|
sessionId?: string;
|
|
151
169
|
cli: string;
|
|
170
|
+
/**
|
|
171
|
+
* Set when FailproofAI Cloud's Jev mode asks (CONTRACT C10.2): the call goes
|
|
172
|
+
* to Cloud with this machine's id, and the deployment it was made under
|
|
173
|
+
* scopes the answer cache (a new deployment can change Cloud's checks).
|
|
174
|
+
*/
|
|
175
|
+
cloud?: { machineId: string; deployment: number | null; mode: "observe" | "enforce"; agent?: AgentIdentity | null };
|
|
176
|
+
/**
|
|
177
|
+
* A session pause is active. It suspends local policy, so no installed
|
|
178
|
+
* pack's check is asked; FailproofAI Cloud's checks are exempt from a pause
|
|
179
|
+
* (as Cloud JS assignments are) and still are. Only meaningful with `cloud`.
|
|
180
|
+
*/
|
|
181
|
+
localPaused?: boolean;
|
|
152
182
|
}
|
|
153
183
|
|
|
154
184
|
export function resolveMode(cfg: JevConfig): JevMode {
|
|
@@ -177,6 +207,24 @@ export function resolveTimeout(cfg: JevConfig): number {
|
|
|
177
207
|
return Math.min(MAX_JEV_TIMEOUT_MS, Math.max(MIN_JEV_TIMEOUT_MS, t));
|
|
178
208
|
}
|
|
179
209
|
|
|
210
|
+
/**
|
|
211
|
+
* The reviewer an outcome answers for: a FailproofAI Cloud check's is
|
|
212
|
+
* `cloud:<policyId>/<name>` (its outcome's own `origin.cloudPolicyId`, carried
|
|
213
|
+
* pack-shaped as `cloud:<id>`), which is what a Cloud `both` policy registers
|
|
214
|
+
* its `reviewedBy` as — so only that policy's own Cloud outcomes can clear it,
|
|
215
|
+
* and a Cloud outcome never clears an installed pack's policy (CONTRACT C10.5).
|
|
216
|
+
* An installed pack's check is its plain name, as it always was.
|
|
217
|
+
*/
|
|
218
|
+
export function reviewerKey(o: Pick<PolicyOutcome, "policy" | "origin">): string {
|
|
219
|
+
const packId = o.origin?.packId;
|
|
220
|
+
return packId !== undefined && packId.startsWith("cloud:") ? cloudReviewerName(packId.slice("cloud:".length), o.policy) : o.policy;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
/** Whether an outcome came from FailproofAI Cloud (its `cloud:<id>` origin; see `parseCloudReply`). */
|
|
224
|
+
function isCloudOutcome(o: Pick<PolicyOutcome, "origin">): boolean {
|
|
225
|
+
return o.origin?.packId?.startsWith("cloud:") === true;
|
|
226
|
+
}
|
|
227
|
+
|
|
180
228
|
/** The semantic policy an attributable Jev verdict is filed under. */
|
|
181
229
|
function jevDecider(outcome: Extract<SemanticOutcome, { status: "ok" }>) {
|
|
182
230
|
const wanted = outcome.verdict.decision === "deny" ? "deny" : "instruct";
|
|
@@ -215,6 +263,15 @@ export function toReview(outcome: SemanticOutcome, cached = false): JevReview {
|
|
|
215
263
|
const latencyMs = sent && !cached ? outcome.latencyMs : null;
|
|
216
264
|
const model = sent ? outcome.model : null;
|
|
217
265
|
const outcomes = outcome.verdict.outcomes;
|
|
266
|
+
// A FailproofAI Cloud outcome is trusted only for a check the reply's own
|
|
267
|
+
// `asked` names. `parseCloudReply` already refuses a reply that contradicts
|
|
268
|
+
// itself; this keeps the review from relying on that alone, because a Cloud
|
|
269
|
+
// outcome is what clears a `both` policy's regex half. One it cannot vouch
|
|
270
|
+
// for — or a Cloud-origin outcome with no Cloud reply at all — means the
|
|
271
|
+
// picture is not one to clear anything on: the regex decides alone.
|
|
272
|
+
const cloudAsked = "cloud" in outcome ? new Set((outcome as CloudSemanticOutcome & { status: "ok" }).cloud.asked) : null;
|
|
273
|
+
const unvouched = outcomes.some((o) => isCloudOutcome(o) && !(cloudAsked?.has(o.policy) ?? false));
|
|
274
|
+
if (unvouched) return { kind: "fallback", reason: "malformed", latencyMs, model: null };
|
|
218
275
|
// `null` when the injection probe was not in the request, which now means
|
|
219
276
|
// only that no request was made: v1 asks it on every call it sends, with or
|
|
220
277
|
// without a recorded human message (see `compile.ts`).
|
|
@@ -232,11 +289,11 @@ export function toReview(outcome: SemanticOutcome, cached = false): JevReview {
|
|
|
232
289
|
// Every selected policy's questions were in the request, and `readAnswers`
|
|
233
290
|
// refuses a response missing any of them — so selected == asked, and only
|
|
234
291
|
// when a request was actually made.
|
|
235
|
-
asked: sent ? outcomes.map(
|
|
292
|
+
asked: sent ? outcomes.map(reviewerKey) : [],
|
|
236
293
|
// `none` found nothing, `overridden` is what the human asked for, and a
|
|
237
294
|
// deny the human's task softened to a warning is that task's consent — all
|
|
238
295
|
// three clear. A `deny`, or a warning nobody consented to, keeps the block.
|
|
239
|
-
notDenied: sent ? outcomes.filter((o) => o.verdict !== "deny" && !warned(o)).map(
|
|
296
|
+
notDenied: sent ? outcomes.filter((o) => o.verdict !== "deny" && !warned(o)).map(reviewerKey) : [],
|
|
240
297
|
injectionAsked: injection !== null,
|
|
241
298
|
injected: injection !== null && injection >= DEFAULT_THRESHOLDS_V1.injection,
|
|
242
299
|
// A check that CAN deny warned without consent: nothing may be cleared on
|
|
@@ -297,12 +354,30 @@ export function startJevReview(cfg: JevConfig, call: JevCallContext): TwoTierRev
|
|
|
297
354
|
let throttled: JevTransport;
|
|
298
355
|
try {
|
|
299
356
|
route = transportForConfig(cfg);
|
|
300
|
-
|
|
357
|
+
// A Cloud answer also depends on what Cloud deployed to this machine, which
|
|
358
|
+
// the request does not show: a new deployment is a new cache scope.
|
|
359
|
+
const scope = call.cloud
|
|
360
|
+
? `${throttleScope(cfg, route)}\u0000cloud\u0000${call.cloud.machineId}\u0000${call.cloud.deployment ?? "-"}`
|
|
361
|
+
: throttleScope(cfg, route);
|
|
362
|
+
throttled = throttle.throttleTransport(route.transport, { scope });
|
|
301
363
|
} catch (err) {
|
|
302
364
|
const reason = err instanceof JevError ? err.code : "config";
|
|
303
365
|
return handle(Promise.resolve({ kind: "fallback", reason, latencyMs: null, model: null }));
|
|
304
366
|
}
|
|
305
367
|
|
|
368
|
+
// FailproofAI Cloud Jev that keeps failing is skipped for a while, so every
|
|
369
|
+
// tool call does not wait out its timeout (`cloud-jev-health.ts`).
|
|
370
|
+
const cloud = call.cloud;
|
|
371
|
+
const healthScope = cloud ? JSON.stringify([cfg.baseUrl ?? null, cloud.machineId]) : "";
|
|
372
|
+
let probe = false;
|
|
373
|
+
if (cloud) {
|
|
374
|
+
const gate = cloudJevGate(healthScope);
|
|
375
|
+
if (!gate.ask) {
|
|
376
|
+
return handle(Promise.resolve({ kind: "fallback", reason: BREAKER_SKIP_REASON, latencyMs: null, model: null }));
|
|
377
|
+
}
|
|
378
|
+
probe = gate.probe;
|
|
379
|
+
}
|
|
380
|
+
|
|
306
381
|
let intent: ReturnType<IntentStore["readIntent"]>;
|
|
307
382
|
try {
|
|
308
383
|
intent = intentReader.readIntent(call.sessionId);
|
|
@@ -326,6 +401,8 @@ export function startJevReview(cfg: JevConfig, call: JevCallContext): TwoTierRev
|
|
|
326
401
|
|
|
327
402
|
/** Set when the answer came from T5's cache (a hit carries the original `usage` and no real latency). */
|
|
328
403
|
let cached = false;
|
|
404
|
+
/** A local inert allow or a cached reply cannot prove Cloud is healthy now. */
|
|
405
|
+
let reachedCloud = false;
|
|
329
406
|
const transport: JevTransport = async (request, signal) => {
|
|
330
407
|
const response = await throttled(request, signal);
|
|
331
408
|
cached = servedFromCache(response);
|
|
@@ -335,21 +412,51 @@ export function startJevReview(cfg: JevConfig, call: JevCallContext): TwoTierRev
|
|
|
335
412
|
const timeoutMs = resolveTimeout(cfg);
|
|
336
413
|
/** Set once the backstop below gave up on the answer: a late one is logged, never applied. */
|
|
337
414
|
let abandoned = false;
|
|
338
|
-
const
|
|
415
|
+
const options = {
|
|
339
416
|
transport,
|
|
340
417
|
cli: call.cli,
|
|
341
418
|
via: route.via,
|
|
342
419
|
model: route.model,
|
|
343
420
|
timeoutMs,
|
|
344
|
-
intent: "v1",
|
|
421
|
+
intent: "v1" as const,
|
|
345
422
|
v1: { thresholds: DEFAULT_THRESHOLDS_V1 },
|
|
346
423
|
signal: controller.signal,
|
|
347
424
|
// No `contextTruncated`: nothing reports a store cut out of band, so the
|
|
348
425
|
// evaluator's own (narrower) guess stands. See `IntentStore` above.
|
|
349
|
-
}
|
|
426
|
+
};
|
|
427
|
+
const evaluated: Promise<SemanticOutcome | CloudSemanticOutcome> = cloud
|
|
428
|
+
? evaluateCloudSemantic(input, {
|
|
429
|
+
...options,
|
|
430
|
+
machineId: cloud.machineId,
|
|
431
|
+
agent: cloud.agent,
|
|
432
|
+
// Paused: no installed pack's check is sent, only the globals, and
|
|
433
|
+
// Cloud's own checks are selected and decided on Cloud as ever.
|
|
434
|
+
...(call.localPaused ? { policies: [] } : {}),
|
|
435
|
+
})
|
|
436
|
+
: evaluateSemantic(input, options);
|
|
437
|
+
const answered = evaluated
|
|
350
438
|
.then((outcome): JevReview => {
|
|
351
439
|
const hit = cached && outcome.status === "ok";
|
|
440
|
+
reachedCloud = outcome.status === "ok" && !hit && outcome.via !== "none";
|
|
352
441
|
const review = toReview(outcome, hit);
|
|
442
|
+
// The machine's own pack checks Cloud dropped from this request
|
|
443
|
+
// (CONTRACT C10.5), reported for the deployment it happened under. Only
|
|
444
|
+
// from an answer that arrived in time: one the backstop abandoned is not
|
|
445
|
+
// applied, and neither is anything it said. A group dropped because a
|
|
446
|
+
// Cloud check of the same name was selected (Cloud wins the name, D-S-2)
|
|
447
|
+
// is told apart from a budget drop: that Cloud check is in `asked`, or in
|
|
448
|
+
// `droppedCloud` when the budget then dropped it too.
|
|
449
|
+
if (cloud && !abandoned && outcome.status === "ok" && "cloud" in outcome && outcome.cloud.droppedLocal.length > 0) {
|
|
450
|
+
const cloudNames = new Set([...outcome.cloud.asked, ...outcome.cloud.droppedCloud]);
|
|
451
|
+
recordJevBudgetDrops(
|
|
452
|
+
{ machineId: cloud.machineId, deployment: cloud.deployment, jevMode: cloud.mode },
|
|
453
|
+
outcome.cloud.droppedLocal.map((d) => ({
|
|
454
|
+
packId: d.packId ?? "unknown",
|
|
455
|
+
name: d.name,
|
|
456
|
+
...(cloudNames.has(d.name) ? { clash: true } : {}),
|
|
457
|
+
})),
|
|
458
|
+
);
|
|
459
|
+
}
|
|
353
460
|
// An aborted request has nothing worth replaying; everything else goes
|
|
354
461
|
// to the local verdict log (never shipped), so any verdict can be
|
|
355
462
|
// re-derived offline from its recorded probabilities. A cache hit is
|
|
@@ -361,7 +468,8 @@ export function startJevReview(cfg: JevConfig, call: JevCallContext): TwoTierRev
|
|
|
361
468
|
eventType: call.eventType,
|
|
362
469
|
applied: abandoned || review.kind !== "answered" ? "legacy-fallback" : mode === "observe" ? "observe" : "two-tier",
|
|
363
470
|
});
|
|
364
|
-
|
|
471
|
+
const withCloud = outcome.status === "ok" && "cloud" in outcome ? { ...row, cloud: outcome.cloud } : row;
|
|
472
|
+
appendVerdictLog(hit ? { ...withCloud, cached: true } : withCloud);
|
|
365
473
|
}
|
|
366
474
|
return review;
|
|
367
475
|
})
|
|
@@ -381,9 +489,20 @@ export function startJevReview(cfg: JevConfig, call: JevCallContext): TwoTierRev
|
|
|
381
489
|
resolve({ kind: "fallback", reason: "timeout", latencyMs: timeoutMs + JEV_DEADLINE_GRACE_MS, model: null });
|
|
382
490
|
}, timeoutMs + JEV_DEADLINE_GRACE_MS);
|
|
383
491
|
});
|
|
492
|
+
const raced = Promise.race([answered, expired]).finally(() => {
|
|
493
|
+
if (deadline !== undefined) clearTimeout(deadline);
|
|
494
|
+
});
|
|
495
|
+
if (!cloud) return handle(raced);
|
|
384
496
|
return handle(
|
|
385
|
-
|
|
386
|
-
|
|
497
|
+
raced.then((review) => {
|
|
498
|
+
recordCloudJevResult(
|
|
499
|
+
healthScope,
|
|
500
|
+
classifyCloudJevReview(review, { reachedCloud }),
|
|
501
|
+
review.kind === "fallback" ? review.reason : null,
|
|
502
|
+
probe,
|
|
503
|
+
);
|
|
504
|
+
reportCloudJevHealth();
|
|
505
|
+
return review;
|
|
387
506
|
}),
|
|
388
507
|
);
|
|
389
508
|
}
|
|
@@ -142,7 +142,8 @@ export interface ResolvedSemanticPolicies {
|
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
/** Turn one validated manifest entry into a policy the compiler can use. */
|
|
145
|
-
|
|
145
|
+
/** Exported for the FailproofAI Cloud Jev parity replay (`__tests__/hooks/cloud-jev-parity.test.ts`). */
|
|
146
|
+
export function toSemanticPolicy(entry: SemanticManifestEntry, pack: { id: string; version?: string }): SemanticPolicy {
|
|
146
147
|
// An unknown precondition name DROPS the policy (the caller catches this),
|
|
147
148
|
// rather than compiling it with no gate at all. Ungating would be the wider
|
|
148
149
|
// direction, not the weaker one, but it is not what the author asked for: a
|
|
@@ -21,6 +21,12 @@ export interface JevRequest {
|
|
|
21
21
|
model: string;
|
|
22
22
|
state: Record<string, unknown>;
|
|
23
23
|
questions: Record<string, NoulQuestion>;
|
|
24
|
+
/**
|
|
25
|
+
* FailproofAI Cloud only: the tool-call metadata Cloud decides this
|
|
26
|
+
* machine's deployed Jev checks on (CONTRACT C10.3, `cloud-jev.ts`). Cloud
|
|
27
|
+
* strips it before anything reaches TypeSafe.
|
|
28
|
+
*/
|
|
29
|
+
cloud?: Record<string, unknown>;
|
|
24
30
|
}
|
|
25
31
|
|
|
26
32
|
export interface JevNoulAnswer {
|
|
@@ -34,6 +40,8 @@ export interface JevResponse {
|
|
|
34
40
|
usage?: { input_tokens?: number; output_tokens?: number };
|
|
35
41
|
/** Set when the provider did not report which Jev version answered (Cloudflare's unversioned alias). */
|
|
36
42
|
modelUnverified?: boolean;
|
|
43
|
+
/** FailproofAI Cloud only: its verdict for this machine's Cloud checks, unvalidated (`parseCloudReply`). */
|
|
44
|
+
cloud?: unknown;
|
|
37
45
|
}
|
|
38
46
|
|
|
39
47
|
/** A yes/no probe. A policy fires only when every one of its probes holds. */
|
|
@@ -195,7 +195,7 @@ export function runPauseCommand(opts: PauseCommandOptions): PauseCommandResult {
|
|
|
195
195
|
...(capped
|
|
196
196
|
? [`${INDENT}Capped at ${pauseDurationWords(PAUSE_CEILING_MS)} from when this pause began.`]
|
|
197
197
|
: []),
|
|
198
|
-
`${INDENT}Cloud-managed policies keep enforcing.`,
|
|
198
|
+
`${INDENT}Cloud-managed policies, and FailproofAI Cloud's Jev checks, keep enforcing.`,
|
|
199
199
|
`${INDENT}Resume early: ${kit.cmd(resume)}`,
|
|
200
200
|
],
|
|
201
201
|
affected: 1,
|
|
@@ -36,6 +36,7 @@ interface WorkerHookRequest {
|
|
|
36
36
|
cli: IntegrationType;
|
|
37
37
|
stdin: string;
|
|
38
38
|
cwd?: string;
|
|
39
|
+
agentSettingsPath?: string;
|
|
39
40
|
}
|
|
40
41
|
|
|
41
42
|
function isWorkerHookRequest(msg: unknown): msg is WorkerHookRequest {
|
|
@@ -54,7 +55,9 @@ function isWorkerHookRequest(msg: unknown): msg is WorkerHookRequest {
|
|
|
54
55
|
// `failproofai config` aborted with "its worker process could not be run"
|
|
55
56
|
// against a daemon and worker that were both perfectly healthy. On a
|
|
56
57
|
// daemonConfigured machine the same mismatch denies the tool call.
|
|
57
|
-
(m.cwd === undefined || m.cwd === null || typeof m.cwd === "string")
|
|
58
|
+
(m.cwd === undefined || m.cwd === null || typeof m.cwd === "string") &&
|
|
59
|
+
(m.agentSettingsPath === undefined || m.agentSettingsPath === null ||
|
|
60
|
+
typeof m.agentSettingsPath === "string")
|
|
58
61
|
);
|
|
59
62
|
}
|
|
60
63
|
|
|
@@ -278,6 +281,7 @@ function handleConnection(socket: Socket, shutdown: () => void): void {
|
|
|
278
281
|
// Normalised here so no consumer has to know the wire spells
|
|
279
282
|
// "absent" as null.
|
|
280
283
|
fallbackCwd: request.cwd ?? undefined,
|
|
284
|
+
agentSettingsPath: request.agentSettingsPath ?? undefined,
|
|
281
285
|
releaseRegistry: release,
|
|
282
286
|
});
|
|
283
287
|
deliver(
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
module.exports=[54799,(e,r,t)=>{r.exports=e.x("crypto",()=>require("crypto"))},70406,(e,r,t)=>{r.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,r,t)=>{r.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},20635,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},24725,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},56704,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(e,r,t)=>{r.exports=e.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},78500,(e,r,t)=>{r.exports=e.x("node:async_hooks",()=>require("node:async_hooks"))},50227,(e,r,t)=>{r.exports=e.x("node:path",()=>require("node:path"))},81111,(e,r,t)=>{r.exports=e.x("node:stream",()=>require("node:stream"))},14747,(e,r,t)=>{r.exports=e.x("path",()=>require("path"))}];
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=%5Bexternals%5D__0hjaw70fchx66._.js.map
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
module.exports=[54799,(s,e,r)=>{e.exports=s.x("crypto",()=>require("crypto"))},22734,(s,e,r)=>{e.exports=s.x("fs",()=>require("fs"))},24868,(s,e,r)=>{e.exports=s.x("fs/promises",()=>require("fs/promises"))},70406,(s,e,r)=>{e.exports=s.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(s,e,r)=>{e.exports=s.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},20635,(s,e,r)=>{e.exports=s.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},24725,(s,e,r)=>{e.exports=s.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},56704,(s,e,r)=>{e.exports=s.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(s,e,r)=>{e.exports=s.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(s,e,r)=>{e.exports=s.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},93695,(s,e,r)=>{e.exports=s.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},12714,(s,e,r)=>{e.exports=s.x("node:fs/promises",()=>require("node:fs/promises"))},50227,(s,e,r)=>{e.exports=s.x("node:path",()=>require("node:path"))},81111,(s,e,r)=>{e.exports=s.x("node:stream",()=>require("node:stream"))},46786,(s,e,r)=>{e.exports=s.x("os",()=>require("os"))},14747,(s,e,r)=>{e.exports=s.x("path",()=>require("path"))},91301,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__08d8xc5bifn8z._.js","server/chunks/lib_antigravity-projects_ts_0hdx6fkrln72c._.js","server/chunks/lib_antigravity-sessions_ts_0jayregp7h3h5._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(30441)))},16341,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__105ihae9i2b_d._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/lib_antigravity-sessions_ts_0jayregp7h3h5._.js"].map(e=>s.l(e))).then(()=>e(93114)))},37352,s=>{s.v(e=>Promise.all(["server/chunks/[externals]_node_os_0by37l-11q5ls._.js","server/chunks/lib_codex-projects_ts_0di6zenec7h7n._.js"].map(e=>s.l(e))).then(()=>e(36203)))},18944,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__105ihae9i2b_d._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/src_hooks_fp-home_ts_09kv0bn_4twyh._.js","server/chunks/lib_codex-sessions_ts_17znrhpys8lz9._.js"].map(e=>s.l(e))).then(()=>e(57232)))},71809,s=>{"use strict";async function e(s,e){let r=Array(s.length),n=0;async function _(){for(;n<s.length;){let e=n++;try{r[e]={status:"fulfilled",value:await s[e]()}}catch(s){r[e]={status:"rejected",reason:s}}}}let t=Array.from({length:Math.min(e,s.length)},()=>_());return await Promise.all(t),r}s.s(["f",0,e])},5807,s=>{s.v(e=>Promise.all(["server/chunks/[externals]_node_os_0by37l-11q5ls._.js","server/chunks/lib_copilot-projects_ts_00-tojoja20ke._.js"].map(e=>s.l(e))).then(()=>e(55851)))},21476,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__105ihae9i2b_d._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/lib_copilot-sessions_ts_200_qjwcll3_i._.js"].map(e=>s.l(e))).then(()=>e(78166)))},97452,s=>{s.v(e=>Promise.all(["server/chunks/[externals]_node_os_0by37l-11q5ls._.js","server/chunks/lib_cursor-projects_ts_1carno5mv3ix_._.js"].map(e=>s.l(e))).then(()=>e(46413)))},23414,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__105ihae9i2b_d._.js","server/chunks/lib_cursor-sessions_ts_1lq8fkhczl3_y._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(72094)))},52400,s=>{s.v(e=>Promise.all(["server/chunks/[root-of-the-server]__0jz5xqu-p_lfc._.js","server/chunks/lib_devin-sessions_ts_0kirblxnhsnmd._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(79364)))},53229,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__08d8xc5bifn8z._.js","server/chunks/lib_devin-sessions_ts_0kirblxnhsnmd._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(40375)))},62998,s=>{s.v(e=>Promise.all(["server/chunks/[root-of-the-server]__1ey11fel2q2qw._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/lib_factory-sessions_ts_0lwe8buimuthh._.js"].map(e=>s.l(e))).then(()=>e(69391)))},95231,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__105ihae9i2b_d._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/lib_factory-sessions_ts_0lwe8buimuthh._.js"].map(e=>s.l(e))).then(()=>e(28246)))},31854,s=>{s.v(e=>Promise.all(["server/chunks/[root-of-the-server]__1ztigqa01tigq._.js","server/chunks/lib_goose-sessions_ts_15jnf4alr5isl._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(69164)))},49081,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__08d8xc5bifn8z._.js","server/chunks/lib_goose-sessions_ts_15jnf4alr5isl._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(36618)))},67347,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__08d8xc5bifn8z._.js","server/chunks/lib_hermes-projects_ts_0h9ny-woruqft._.js","server/chunks/lib_hermes-profiles_ts_0jki1620x7wxh._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_hermes-sessions_ts_1bo14h38efuti._.js"].map(e=>s.l(e))).then(()=>e(64828)))},32359,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__08d8xc5bifn8z._.js","server/chunks/lib_hermes-profiles_ts_0jki1620x7wxh._.js","server/chunks/lib_hermes-sessions_ts_1bo14h38efuti._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(3605)))},3959,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__1k8s9m68ew993._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_openclaw-db_ts_0nax8ld9h9ii8._.js"].map(e=>s.l(e))).then(()=>e(96878)))},38978,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__08d8xc5bifn8z._.js","server/chunks/lib_openclaw-projects_ts_0gc-p24z7gzy8._.js","server/chunks/lib_openclaw-db_ts_0nax8ld9h9ii8._.js","server/chunks/lib_openclaw-sessions_ts_06lc8rgfj4huq._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(90624)))},26435,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__08d8xc5bifn8z._.js","server/chunks/lib_openclaw-db_ts_0nax8ld9h9ii8._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/lib_openclaw-sessions_ts_06lc8rgfj4huq._.js"].map(e=>s.l(e))).then(()=>e(64199)))},82978,s=>{s.v(e=>Promise.all(["server/chunks/[root-of-the-server]__168oo8wb5n23f._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_opencode-projects_ts_1r-bu98cz4660._.js"].map(e=>s.l(e))).then(()=>e(35435)))},82859,s=>{s.v(e=>Promise.all(["server/chunks/[root-of-the-server]__168oo8wb5n23f._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js","server/chunks/_1vslkoe35wok6._.js","server/chunks/lib_opencode-sessions_ts_0fdxj6q_np7ll._.js"].map(e=>s.l(e))).then(()=>e(99440)))},45093,s=>{s.v(e=>Promise.all(["server/chunks/[externals]_node_os_0by37l-11q5ls._.js","server/chunks/lib_pi-projects_ts_1_cy5lfxd21kv._.js"].map(e=>s.l(e))).then(()=>e(19791)))},41330,s=>{s.v(e=>Promise.all(["server/chunks/[externals]__105ihae9i2b_d._.js","server/chunks/lib_pi-sessions_ts_09ha0x-gi38y1._.js","server/chunks/lib_log-entries_ts_0e1mnh5npsol1._.js"].map(e=>s.l(e))).then(()=>e(85116)))}];
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=%5Broot-of-the-server%5D__07l68zv0hqdiu._.js.map
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
module.exports=[24868,(e,t,s)=>{t.exports=e.x("fs/promises",()=>require("fs/promises"))},66680,(e,t,s)=>{t.exports=e.x("node:crypto",()=>require("node:crypto"))},2157,(e,t,s)=>{t.exports=e.x("node:fs",()=>require("node:fs"))},12714,(e,t,s)=>{t.exports=e.x("node:fs/promises",()=>require("node:fs/promises"))},60526,(e,t,s)=>{t.exports=e.x("node:os",()=>require("node:os"))},50227,(e,t,s)=>{t.exports=e.x("node:path",()=>require("node:path"))},46786,(e,t,s)=>{t.exports=e.x("os",()=>require("os"))},14747,(e,t,s)=>{t.exports=e.x("path",()=>require("path"))},71809,e=>{"use strict";async function t(e,t){let s=Array(e.length),i=0;async function r(){for(;i<e.length;){let t=i++;try{s[t]={status:"fulfilled",value:await e[t]()}}catch(e){s[t]={status:"rejected",reason:e}}}}let o=Array.from({length:Math.min(t,e.length)},()=>r());return await Promise.all(o),s}e.s(["f",0,t])},79364,e=>{"use strict";var t=e.i(79708),s=e.i(40375),i=e.i(81580),r=e.i(83534),o=e.i(28557);async function n(){let e=await (0,t.f)((0,s.devinDbPath)());if(!e)return[];try{return e.query("SELECT id, working_directory, title, created_at, last_activity_at, hidden FROM sessions ORDER BY last_activity_at DESC").filter(e=>!e.hidden).map(e=>{let t=e.working_directory??void 0;return{sessionId:e.id,cwd:t,title:e.title??void 0,projectName:t?(0,i.f)(t):"devin",mtimeMs:(0,s.devinEpochToMs)(e.last_activity_at??e.created_at)}})}catch{return[]}finally{e.close()}}let a=(0,r.f)(n,2);async function d(){let e=await n(),t=new Map;for(let s of e){if(!s.cwd)continue;let e=t.get(s.projectName);(!e||s.mtimeMs>e.latest)&&t.set(s.projectName,{latest:s.mtimeMs,cwd:s.cwd,name:s.projectName})}let s=[];for(let{name:e,cwd:i,latest:r}of t.values()){let t=new Date(r);s.push({name:e,path:i,isDirectory:!0,lastModified:t,lastModifiedFormatted:(0,o.f)(t),cli:["devin"]})}return s.sort((e,t)=>t.lastModified.getTime()-e.lastModified.getTime()),s}async function l(e){let t=(await n()).filter(t=>t.cwd&&t.projectName===e);if(0===t.length)return{cwd:null,sessions:[]};let s=[...t].sort((e,t)=>t.mtimeMs-e.mtimeMs);return{cwd:s[0].cwd??null,sessions:s.map(e=>{let t=new Date(e.mtimeMs);return{name:e.title??e.sessionId,path:`devin-db://${e.sessionId}`,lastModified:t,lastModifiedFormatted:(0,o.f)(t),sessionId:e.sessionId,cli:"devin"}})}}let c=(0,r.f)(d,2),f=(0,r.f)(e=>l(e),2,{maxSize:50});e.s(["getCachedDevinProjects",0,c,"getCachedDevinSessions",0,a,"getCachedDevinSessionsByEncodedName",0,f,"getDevinProjects",0,d,"getDevinSessions",0,n,"getDevinSessionsByEncodedName",0,l])}];
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=%5Broot-of-the-server%5D__0car70pylmvor._.js.map
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
module.exports=[54799,(e,r,t)=>{r.exports=e.x("crypto",()=>require("crypto"))},70406,(e,r,t)=>{r.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,r,t)=>{r.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},20635,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},24725,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},56704,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(e,r,t)=>{r.exports=e.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},93695,(e,r,t)=>{r.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},74533,(e,r,t)=>{r.exports=e.x("node:child_process",()=>require("node:child_process"))},66680,(e,r,t)=>{r.exports=e.x("node:crypto",()=>require("node:crypto"))},2157,(e,r,t)=>{r.exports=e.x("node:fs",()=>require("node:fs"))},60526,(e,r,t)=>{r.exports=e.x("node:os",()=>require("node:os"))},50227,(e,r,t)=>{r.exports=e.x("node:path",()=>require("node:path"))},81111,(e,r,t)=>{r.exports=e.x("node:stream",()=>require("node:stream"))},14747,(e,r,t)=>{r.exports=e.x("path",()=>require("path"))},94930,e=>{"use strict";var r=e.i(2157),t=e.i(50227),s=e.i(66680);e.s(["f",0,function(e,n,o={}){let a=o.mode??384,i=o.dirMode??448,x=(0,t.dirname)(e);(0,r.existsSync)(x)||(0,r.mkdirSync)(x,{recursive:!0,mode:i});let p=`${e}.${process.pid}.${(0,s.randomBytes)(6).toString("hex")}.tmp`;try{(0,r.writeFileSync)(p,JSON.stringify(n,null,2),{mode:a});try{(63&(0,r.statSync)(p).mode)!=0&&(0,r.chmodSync)(p,a)}catch{}(0,r.renameSync)(p,e);try{(63&(0,r.statSync)(e).mode)!=0&&(0,r.chmodSync)(e,a)}catch{}}catch(e){try{(0,r.rmSync)(p,{force:!0})}catch{}throw e}}])}];
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=%5Broot-of-the-server%5D__0u3i025_setk_._.js.map
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
module.exports=[54799,(e,r,t)=>{r.exports=e.x("crypto",()=>require("crypto"))},70406,(e,r,t)=>{r.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,r,t)=>{r.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},20635,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},24725,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},56704,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,r,t)=>{r.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(e,r,t)=>{r.exports=e.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},93695,(e,r,t)=>{r.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},66680,(e,r,t)=>{r.exports=e.x("node:crypto",()=>require("node:crypto"))},2157,(e,r,t)=>{r.exports=e.x("node:fs",()=>require("node:fs"))},60526,(e,r,t)=>{r.exports=e.x("node:os",()=>require("node:os"))},50227,(e,r,t)=>{r.exports=e.x("node:path",()=>require("node:path"))},81111,(e,r,t)=>{r.exports=e.x("node:stream",()=>require("node:stream"))},14747,(e,r,t)=>{r.exports=e.x("path",()=>require("path"))},94930,e=>{"use strict";var r=e.i(2157),t=e.i(50227),s=e.i(66680);e.s(["f",0,function(e,n,o={}){let a=o.mode??384,i=o.dirMode??448,x=(0,t.dirname)(e);(0,r.existsSync)(x)||(0,r.mkdirSync)(x,{recursive:!0,mode:i});let p=`${e}.${process.pid}.${(0,s.randomBytes)(6).toString("hex")}.tmp`;try{(0,r.writeFileSync)(p,JSON.stringify(n,null,2),{mode:a});try{(63&(0,r.statSync)(p).mode)!=0&&(0,r.chmodSync)(p,a)}catch{}(0,r.renameSync)(p,e);try{(63&(0,r.statSync)(e).mode)!=0&&(0,r.chmodSync)(e,a)}catch{}}catch(e){try{(0,r.rmSync)(p,{force:!0})}catch{}throw e}}])}];
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=%5Broot-of-the-server%5D__10a2f6s636yc7._.js.map
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
module.exports=[[94930,e=>{var t=e.i(2157),r=e.i(50227),s=e.i(66680);e.s(["f",0,function(e,n,o={}){let i=o.mode??384,a=o.dirMode??448,d=(0,r.dirname)(e);(0,t.existsSync)(d)||(0,t.mkdirSync)(d,{recursive:!0,mode:a});let c=`${e}.${process.pid}.${(0,s.randomBytes)(6).toString("hex")}.tmp`;try{(0,t.writeFileSync)(c,JSON.stringify(n,null,2),{mode:i});try{(63&(0,t.statSync)(c).mode)!=0&&(0,t.chmodSync)(c,i)}catch{}(0,t.renameSync)(c,e);try{(63&(0,t.statSync)(e).mode)!=0&&(0,t.chmodSync)(e,i)}catch{}}catch(e){try{(0,t.rmSync)(c,{force:!0})}catch{}throw e}}])},69164,e=>{var t=e.i(79708),r=e.i(36618),s=e.i(81580),n=e.i(83534),o=e.i(28557);async function i(){let e=await (0,t.f)((0,r.gooseDbPath)());if(!e)return[];try{return e.query("SELECT id, working_dir, description, name, session_type, created_at, updated_at FROM sessions ORDER BY updated_at DESC").filter(e=>"hidden"!==e.session_type).map(e=>{let t=e.working_dir??void 0,n=(e.description&&e.description.length>0?e.description:e.name)??void 0;return{sessionId:e.id,cwd:t,title:n&&n.length>0?n:void 0,projectName:t?(0,s.f)(t):"goose",mtimeMs:(0,r.gooseTimestampToMs)(e.updated_at??e.created_at)}})}catch{return[]}finally{e.close()}}let a=(0,n.f)(i,2);async function d(){let e=await i(),t=new Map;for(let r of e){if(!r.cwd)continue;let e=t.get(r.projectName);(!e||r.mtimeMs>e.latest)&&t.set(r.projectName,{latest:r.mtimeMs,cwd:r.cwd,name:r.projectName})}let r=[];for(let{name:e,cwd:s,latest:n}of t.values()){let t=new Date(n);r.push({name:e,path:s,isDirectory:!0,lastModified:t,lastModifiedFormatted:(0,o.f)(t),cli:["goose"]})}return r.sort((e,t)=>t.lastModified.getTime()-e.lastModified.getTime()),r}async function c(e){let t=(await i()).filter(t=>t.cwd&&t.projectName===e);if(0===t.length)return{cwd:null,sessions:[]};let r=[...t].sort((e,t)=>t.mtimeMs-e.mtimeMs);return{cwd:r[0].cwd??null,sessions:r.map(e=>{let t=new Date(e.mtimeMs);return{name:e.title??e.sessionId,path:`goose-db://${e.sessionId}`,lastModified:t,lastModifiedFormatted:(0,o.f)(t),sessionId:e.sessionId,cli:"goose"}})}}let l=(0,n.f)(d,2),p=(0,n.f)(e=>c(e),2,{maxSize:50});e.s(["getCachedGooseProjects",0,l,"getCachedGooseSessions",0,a,"getCachedGooseSessionsByEncodedName",0,p,"getGooseProjects",0,d,"getGooseSessions",0,i,"getGooseSessionsByEncodedName",0,c])},40759,e=>{var t=e.i(60526),r=e.i(50227),s=e.i(79708);async function n(e){let n=await (0,s.f)(function(){if(process.env.OPENCODE_DB_PATH)return process.env.OPENCODE_DB_PATH;let e=process.env.OPENCODE_HOME??(0,r.join)((0,t.homedir)(),".local","share","opencode");return(0,r.join)(e,"opencode.db")}());if(!n)return null;try{return e(n)}catch{return null}finally{try{n.close()}catch{}}}async function o(e,t=[]){return n(r=>r.query(e,t))}e.s(["h",0,o,"x",0,n])}],54799,(e,t,r)=>{t.exports=e.x("crypto",()=>require("crypto"))},70406,(e,t,r)=>{t.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,t,r)=>{t.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},20635,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},24725,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},56704,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},59043,(e,t,r)=>{t.exports=e.x("next/dist/server/runtime-reacts.external.js",()=>require("next/dist/server/runtime-reacts.external.js"))},93695,(e,t,r)=>{t.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},74533,(e,t,r)=>{t.exports=e.x("node:child_process",()=>require("node:child_process"))},81111,(e,t,r)=>{t.exports=e.x("node:stream",()=>require("node:stream"))}];
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=%5Broot-of-the-server%5D__1qt5u58xrcuk6._.js.map
|