failproofai 1.0.10 → 1.0.11-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 +6 -6
- 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 +4 -4
- 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.meta +8 -0
- package/.next/standalone/.next/server/app/_global-error.rsc +7 -7
- package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +6 -6
- package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +7 -7
- 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 +4 -4
- 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.meta +8 -0
- package/.next/standalone/.next/server/app/_not-found.rsc +14 -14
- package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +14 -14
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +13 -13
- 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 +4 -4
- 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 +4 -4
- 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 +1 -1
- 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 +2 -2
- 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 +4 -4
- 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 +3 -3
- 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 +3 -3
- 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 +1 -1
- 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.meta +8 -0
- package/.next/standalone/.next/server/app/index.rsc +14 -14
- package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +13 -13
- package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +14 -14
- 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 +4 -4
- 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 +8 -8
- 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 +5 -5
- 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 +5 -5
- 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 +5 -5
- 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 +9 -9
- 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]__0qxhecv._.js → [externals]__0d7i9ea._.js} +2 -2
- package/.next/standalone/.next/server/chunks/{[externals]__0sg9-3p._.js → [externals]__0hjaw70._.js} +1 -1
- package/.next/standalone/.next/server/chunks/[externals]__1_9ze9b._.js +3 -0
- package/.next/standalone/.next/server/chunks/[externals]__1oenfmn._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__08dchfu._.js +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0ga9hs7._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0l3yhx4._.js +2 -2
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0moxohc._.js +22 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0o07qi9._.js +1 -1
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0z2ll-a._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1adacul._.js +11 -11
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1autwno._.js +3 -0
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1v25n-6._.js +3 -0
- package/.next/standalone/.next/server/chunks/_09dz7xv._.js +1 -1
- package/.next/standalone/.next/server/chunks/_0tovk6q._.js +1 -1
- package/.next/standalone/.next/server/chunks/_0trp3yc._.js +1 -1
- package/.next/standalone/.next/server/chunks/_1ek68ln._.js +2 -2
- package/.next/standalone/.next/server/chunks/_1fz8m31._.js +1 -1
- package/.next/standalone/.next/server/chunks/_1jrv3hg._.js +3 -0
- package/.next/standalone/.next/server/chunks/_1nx8fim._.js +3 -0
- package/.next/standalone/.next/server/chunks/_1ogwigf._.js +1 -1
- package/.next/standalone/.next/server/chunks/{_1q5i8mb._.js → _1q27azx._.js} +2 -2
- package/.next/standalone/.next/server/chunks/lib_telemetry_ts_0dctyyw._.js +1 -1
- package/.next/standalone/.next/server/chunks/{node_modules_posthog-node_dist_entrypoints_index_node_mjs_0el6rg8._.js → node_modules_posthog-node_dist_entrypoints_index_node_mjs_0ol5pa3._.js} +2 -2
- package/.next/standalone/.next/server/chunks/{node_modules_posthog-node_dist_entrypoints_index_node_mjs_04op_ou._.js → node_modules_posthog-node_dist_entrypoints_index_node_mjs_1rqmk27._.js} +2 -2
- package/.next/standalone/.next/server/chunks/{node_modules_posthog-node_dist_entrypoints_index_node_mjs_0dr20uz._.js → node_modules_posthog-node_dist_entrypoints_index_node_mjs_1w7tiq4._.js} +2 -2
- package/.next/standalone/.next/server/chunks/package_json_[json]_cjs_1nxcc4v._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0oqrl71._.js → [root-of-the-server]__042u-jn._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__04usis8._.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__1-bm5zf._.js → [root-of-the-server]__0502lat._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0_gn5iz._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0f765xr._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__01bmjsj._.js → [root-of-the-server]__0h38gzz._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0hoaz1g._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__1ouobn4._.js → [root-of-the-server]__0mxmwtx._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__19evfi8._.js → [root-of-the-server]__0uescqv._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__13d-wb6._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1484zv2._.js +3 -0
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__1mf3zp6._.js → [root-of-the-server]__19dutr7._.js} +4 -4
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__1u6sn69._.js → [root-of-the-server]__1ab4ifb._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1fbrk56._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1pprgri._.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1um4yxn._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1wb4yt2._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1y3n3cn._.js +4 -0
- package/.next/standalone/.next/server/chunks/ssr/_08x1r5t._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_0bqoto4._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{_0yq5_3a._.js → _1ffxwxz._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_1gb0ifp._.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{_042cgl1._.js → _1o95rf0._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{_1zopuov._.js → _1thr5rf._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/{_16pa9ht._.js → _1v1o2ya._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/_next-internal_server_app_policies_page_actions_1sp2-yo.js +12 -14
- package/.next/standalone/.next/server/chunks/ssr/app_actions_get-scheduled-audit_ts_0ei9sni._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_audit__components_audit-dashboard_tsx_0p9ud47._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_global-error_tsx_1kp6l3x._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_policies_hooks-client_tsx_19dqvpc._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/app_settings_02tf1h4._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/node_modules_1hl81y4._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_0nkkbfv._.js +6 -0
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_fp-config_ts_04t589g._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/src_hooks_fp-home_ts_0je3xkv._.js +1 -1
- package/.next/standalone/.next/server/middleware-build-manifest.js +6 -6
- package/.next/standalone/.next/server/middleware.js +1 -1
- 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/server-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/server-reference-manifest.json +23 -23
- package/.next/standalone/.next/static/chunks/08tmc_7n-rba1.js +1 -0
- package/.next/standalone/.next/static/chunks/{3mjfvng11xnoo.js → 09tlrmucn6oq3.js} +1 -1
- package/.next/standalone/.next/static/chunks/{078dofaxvjgpd.js → 0i69k917myh7b.js} +1 -1
- package/.next/standalone/.next/static/chunks/{03h3b-uomi7_d.js → 0u_nhsujkactp.js} +1 -1
- package/.next/standalone/.next/static/chunks/{2j92xul6y24_v.js → 0zp51hzx62i-u.js} +1 -1
- package/.next/standalone/.next/static/chunks/{3u1s8dsqiean5.js → 1fz7q0gtnmeod.js} +1 -1
- package/.next/standalone/.next/static/chunks/{3ob2161ap37ul.js → 1j75le8wln-26.js} +1 -1
- package/.next/standalone/.next/static/chunks/{2kj826h1w9r47.js → 1z4km7tw0_50h.js} +1 -1
- package/.next/standalone/.next/static/chunks/{1fqukzzowjflt.js → 239ay_80-xr8z.js} +1 -1
- package/.next/standalone/.next/static/chunks/{3nkc2jlgyygda.js → 2c9pc5xco6rnu.js} +1 -1
- package/.next/standalone/.next/static/chunks/{3i8rg2fv9nd6e.js → 3n46e45atic-m.js} +1 -1
- package/.next/standalone/.next/static/chunks/{0542cuk_va8g1.js → 3sg07wnn969xq.js} +1 -1
- package/.next/standalone/.next/static/chunks/{turbopack-11dn2pegmg9_9.js → turbopack-1opxka4dtjbc5.js} +1 -1
- package/.next/standalone/app/actions/install-hooks-web.ts +10 -2
- 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/next/dist/build/swc/index.js +1 -1
- package/.next/standalone/node_modules/next/dist/compiled/hash.js/sha256/256.js +1 -0
- package/.next/standalone/node_modules/next/dist/compiled/hash.js/sha256/package.json +1 -0
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js +17 -17
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo.runtime.prod.js +18 -18
- package/.next/standalone/node_modules/next/dist/compiled/next-server/app-route-turbo.runtime.prod.js +3 -3
- package/.next/standalone/node_modules/next/dist/compiled/next-server/pages-turbo.runtime.prod.js +13 -13
- package/.next/standalone/node_modules/next/dist/lib/patch-incorrect-lockfile.js +3 -3
- package/.next/standalone/node_modules/next/dist/server/base-server.js +1 -2
- 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/image-optimizer.js +265 -53
- package/.next/standalone/node_modules/next/dist/server/lib/app-info-log.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/lib/incremental-cache/file-system-cache.js +177 -19
- package/.next/standalone/node_modules/next/dist/server/lib/incremental-cache/index.js +36 -17
- package/.next/standalone/node_modules/next/dist/server/lib/incremental-cache/shared-cache-controls.external.js +14 -6
- package/.next/standalone/node_modules/next/dist/server/lib/match-next-data-pathname.js +3 -1
- package/.next/standalone/node_modules/next/dist/server/lib/node-fs-methods.js +14 -0
- package/.next/standalone/node_modules/next/dist/server/lib/route-cache-key.js +77 -0
- package/.next/standalone/node_modules/next/dist/server/lib/router-utils/block-cross-site-dev.js +9 -11
- package/.next/standalone/node_modules/next/dist/server/lib/start-server.js +1 -1
- package/.next/standalone/node_modules/next/dist/server/mcp/get-mcp-middleware.js +4 -2
- package/.next/standalone/node_modules/next/dist/server/next-server.js +7 -3
- package/.next/standalone/node_modules/next/dist/server/response-cache/index.js +32 -16
- package/.next/standalone/node_modules/next/dist/server/route-matcher-providers/app-page-route-matcher-provider.js +2 -2
- package/.next/standalone/node_modules/next/dist/server/route-modules/pages/pages-handler.js +6 -1
- package/.next/standalone/node_modules/next/dist/server/route-modules/route-module.js +9 -2
- package/.next/standalone/node_modules/next/dist/server/use-cache/use-cache-wrapper.js +30 -29
- package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/app-paths.js +18 -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 +10 -10
- package/.next/standalone/package.json +14 -11
- package/.next/standalone/sdk/python/README.md +41 -0
- package/.next/standalone/sdk/python/docs/README.md +1 -0
- package/.next/standalone/sdk/python/docs/otel/README.md +36 -0
- package/.next/standalone/sdk/python/docs/otel/examples/agent_trace.py +30 -0
- package/.next/standalone/sdk/python/docs/otel/examples/quickstart.py +22 -0
- package/.next/standalone/sdk/python/failproofai_sdk/__init__.py +8 -0
- package/.next/standalone/sdk/python/failproofai_sdk/integrations/__init__.py +3 -0
- package/.next/standalone/sdk/python/failproofai_sdk/integrations/otel.py +189 -0
- package/.next/standalone/sdk/python/pyproject.toml +2 -1
- package/.next/standalone/sdk/python/tests/test_docs.py +16 -3
- package/.next/standalone/sdk/python/tests/test_integrations.py +1 -1
- package/.next/standalone/sdk/python/tests/test_otel.py +147 -0
- package/.next/standalone/sdk/python/tests/test_zero_dependencies.py +4 -1
- package/.next/standalone/sdk/python/uv.lock +258 -147
- package/.next/standalone/sdk/typescript/README.md +43 -0
- package/.next/standalone/sdk/typescript/integration/ai.test.ts +9 -2
- package/.next/standalone/sdk/typescript/package-lock.json +57 -5
- package/.next/standalone/sdk/typescript/package.json +2 -0
- package/.next/standalone/sdk/typescript/src/edge/index.ts +9 -0
- package/.next/standalone/sdk/typescript/src/index.ts +2 -0
- package/.next/standalone/sdk/typescript/src/integrations/index.ts +4 -1
- package/.next/standalone/sdk/typescript/src/integrations/otel.ts +204 -0
- package/.next/standalone/sdk/typescript/test/integrations.test.ts +1 -1
- package/.next/standalone/sdk/typescript/test/otel.test.ts +125 -0
- package/.next/standalone/server.js +1 -1
- package/bin/failproofai.mjs +653 -1077
- package/dist/cli.mjs +8174 -3930
- package/dist/worker.mjs +170 -62
- package/hermes-plugin/plugin.yaml +1 -1
- package/package.json +14 -11
- package/scripts/launch-facts.ts +157 -0
- package/scripts/launch-ready.ts +228 -0
- package/scripts/launch-screen.ts +202 -0
- package/scripts/launch.ts +106 -49
- package/scripts/skew-log-filter.ts +42 -0
- package/src/audit/cli-login.ts +39 -59
- package/src/audit/cli.ts +308 -228
- package/src/audit/index.ts +45 -2
- package/src/audit/schedule-cli.ts +83 -120
- package/src/audit/types.ts +31 -0
- package/src/hooks/agent-selection.ts +155 -0
- package/src/hooks/backfill-cli.ts +151 -137
- package/src/hooks/backfill-request.ts +149 -0
- package/src/hooks/cloud-connection.ts +1 -1
- package/src/hooks/cloud-enrollment-cli.ts +78 -28
- package/src/hooks/cloud-introspect.ts +3 -0
- package/src/hooks/collector-config.ts +10 -1
- package/src/hooks/config-status.ts +606 -0
- package/src/hooks/configure-wizard.ts +915 -989
- package/src/hooks/daemon-service.ts +16 -6
- package/src/hooks/did-you-mean.ts +185 -0
- package/src/hooks/flush-cli.ts +33 -7
- package/src/hooks/fp-config.ts +96 -0
- package/src/hooks/fp-home.ts +11 -0
- package/src/hooks/fp-reset.ts +102 -95
- package/src/hooks/handler.ts +4 -0
- package/src/hooks/harness-cli.ts +87 -138
- package/src/hooks/install-prompt.ts +38 -477
- package/src/hooks/integrations.ts +1 -1
- package/src/hooks/jev-cli.ts +183 -196
- package/src/hooks/manager.ts +554 -358
- package/src/hooks/onboarding-attempt.ts +11 -9
- package/src/hooks/otel-cli.ts +344 -0
- package/src/hooks/otel-output.ts +24 -0
- package/src/hooks/otel-writers.ts +225 -0
- package/src/hooks/pack-cli.ts +219 -204
- package/src/hooks/report-body.ts +50 -0
- package/src/hooks/safe-config-write.ts +4 -2
- package/src/hooks/session-pause-cli.ts +93 -73
- package/src/hooks/tui.ts +849 -389
- package/src/hooks/uninstall-cli.ts +136 -149
- package/src/hooks/untraced-note.ts +52 -0
- package/.next/standalone/.next/server/chunks/[externals]__19_pzeq._.js +0 -3
- package/.next/standalone/.next/server/chunks/[externals]__20kzpkf._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__01eqny5._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__05ja_05._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0igxt32._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__0zyc_nm._.js +0 -3
- package/.next/standalone/.next/server/chunks/[root-of-the-server]__1ttrwnd._.js +0 -22
- package/.next/standalone/.next/server/chunks/_0bs-v8p._.js +0 -3
- package/.next/standalone/.next/server/chunks/_185gyk9._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__056wjo4._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0n0xg95._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0rwtwpm._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0yrsbd_._.js +0 -3
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__11mayhe._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__15578wp._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1m_svbe._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1q4p5b8._.js +0 -4
- package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_1n3w9lb._.js +0 -6
- package/.next/standalone/.next/static/chunks/1lyg_puttohbc.js +0 -1
- /package/.next/standalone/.next/static/{ECs8__hcNabYV58WfDh-3 → UZKCiP4Q2TeU8zOB-h9Xj}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{ECs8__hcNabYV58WfDh-3 → UZKCiP4Q2TeU8zOB-h9Xj}/_clientMiddlewareManifest.js +0 -0
- /package/.next/standalone/.next/static/{ECs8__hcNabYV58WfDh-3 → UZKCiP4Q2TeU8zOB-h9Xj}/_ssgManifest.js +0 -0
|
@@ -53,6 +53,8 @@ export function configBackupPath(path: string): string {
|
|
|
53
53
|
|
|
54
54
|
/** Hooks for tests to simulate an interruption at the one step that matters. */
|
|
55
55
|
export interface AtomicWriteDeps {
|
|
56
|
+
/** Explicit permissions for a newly credential-bearing file. */
|
|
57
|
+
mode?: number;
|
|
56
58
|
rename?: (from: string, to: string) => void;
|
|
57
59
|
/** Keep `<name>.failproofai-backup` of the previous version (default true). */
|
|
58
60
|
backup?: boolean;
|
|
@@ -144,9 +146,9 @@ export function writeConfigFileAtomic(path: string, content: string, deps: Atomi
|
|
|
144
146
|
let mode: number | undefined;
|
|
145
147
|
try {
|
|
146
148
|
// A link being replaced lends nothing: its target's mode is someone else's.
|
|
147
|
-
mode = replacingLink ? undefined : statSync(target).mode & 0o777;
|
|
149
|
+
mode = deps.mode ?? (replacingLink ? undefined : statSync(target).mode & 0o777);
|
|
148
150
|
} catch {
|
|
149
|
-
mode =
|
|
151
|
+
mode = deps.mode; // otherwise the process umask decides, as writeFileSync would
|
|
150
152
|
}
|
|
151
153
|
|
|
152
154
|
const temporary = join(dir, `.${basename(target)}.failproofai-${process.pid}-${randomBytes(4).toString("hex")}.tmp`);
|
|
@@ -1,26 +1,38 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* `failproofai config --pause | --resume
|
|
2
|
+
* `failproofai config --pause | --resume`.
|
|
3
3
|
*
|
|
4
4
|
* Lives on `config` rather than as its own verb because `config` is the single
|
|
5
5
|
* place this product configures anything. The state it writes is NOT config
|
|
6
6
|
* though — see session-pause.ts for why a pause must never reach a file that
|
|
7
7
|
* gets committed.
|
|
8
|
+
*
|
|
9
|
+
* `--status` used to be answered here too. It is a whole-machine screen now
|
|
10
|
+
* (config-status.ts), which lists every pause among the rest of the machine's
|
|
11
|
+
* state; this module keeps the two commands that change a pause.
|
|
8
12
|
*/
|
|
9
13
|
import {
|
|
10
14
|
PAUSE_CEILING_MS,
|
|
11
15
|
clearPause,
|
|
12
|
-
formatDuration,
|
|
13
16
|
listActivePauses,
|
|
14
17
|
parsePauseDuration,
|
|
15
18
|
readActivePause,
|
|
16
19
|
resolveSessionForCwd,
|
|
17
20
|
writePause,
|
|
18
|
-
type ActivePause,
|
|
19
21
|
} from "./session-pause";
|
|
20
|
-
import {
|
|
22
|
+
import { INDENT, optsFor, screenKit, type RenderOpts } from "./tui";
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* How a clock time is written. Both default to the machine's own, which is what
|
|
26
|
+
* a person reading their terminal expects; tests pin them so the output does not
|
|
27
|
+
* depend on where the suite runs.
|
|
28
|
+
*/
|
|
29
|
+
export interface PauseClock {
|
|
30
|
+
locale?: string;
|
|
31
|
+
timeZone?: string;
|
|
32
|
+
}
|
|
21
33
|
|
|
22
34
|
export interface PauseCommandOptions {
|
|
23
|
-
action: "pause" | "resume"
|
|
35
|
+
action: "pause" | "resume";
|
|
24
36
|
/** Raw `--pause <duration>` argument, if any. */
|
|
25
37
|
duration?: string;
|
|
26
38
|
/** Explicit `--session <id>`. */
|
|
@@ -29,24 +41,14 @@ export interface PauseCommandOptions {
|
|
|
29
41
|
all?: boolean;
|
|
30
42
|
cwd?: string;
|
|
31
43
|
now?: number;
|
|
44
|
+
/** Width and colour. Defaults to the stream the result is printed on. */
|
|
45
|
+
render?: RenderOpts;
|
|
46
|
+
clock?: PauseClock;
|
|
32
47
|
}
|
|
33
48
|
|
|
34
49
|
export interface PauseCommandResult {
|
|
35
50
|
exitCode: number;
|
|
36
51
|
lines: string[];
|
|
37
|
-
/**
|
|
38
|
-
* The `--status` facts unrendered, so `config --status` can align them into
|
|
39
|
-
* the SAME label column as the connection block above them rather than each
|
|
40
|
-
* block computing its own. Absent for pause/resume, which are confirmations
|
|
41
|
-
* rather than readouts.
|
|
42
|
-
*/
|
|
43
|
-
rows?: Array<[string, string]>;
|
|
44
|
-
/**
|
|
45
|
-
* Lines that are NOT rows — the note and the resume command. A caller merging
|
|
46
|
-
* `rows` into a wider readout must still print these; dropping them took the
|
|
47
|
-
* only instruction telling a paused user how to get unpaused.
|
|
48
|
-
*/
|
|
49
|
-
trailer?: string[];
|
|
50
52
|
/** For telemetry; never the session id itself. */
|
|
51
53
|
affected: number;
|
|
52
54
|
}
|
|
@@ -70,53 +72,58 @@ export function effectiveCeilingMs(): number {
|
|
|
70
72
|
return PAUSE_CEILING_MS;
|
|
71
73
|
}
|
|
72
74
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
75
|
+
/**
|
|
76
|
+
* `14:32`, or `2:32 PM` — the locale's own clock, to the minute.
|
|
77
|
+
*
|
|
78
|
+
* Seconds are dropped: a pause is minutes long, and `14:32:07` puts the one
|
|
79
|
+
* number a reader wants among two they do not.
|
|
80
|
+
*/
|
|
81
|
+
export function pauseClockTime(epochMs: number, clock: PauseClock = {}): string {
|
|
82
|
+
return new Date(epochMs).toLocaleTimeString(clock.locale, {
|
|
83
|
+
hour: "numeric",
|
|
84
|
+
minute: "2-digit",
|
|
85
|
+
...(clock.timeZone ? { timeZone: clock.timeZone } : {}),
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/** `30 minutes`, `1 hour 30 minutes`, `45 seconds` — a duration in words. */
|
|
90
|
+
export function pauseDurationWords(ms: number): string {
|
|
91
|
+
if (ms < 60_000) {
|
|
92
|
+
const seconds = Math.max(1, Math.round(ms / 1000));
|
|
93
|
+
return `${seconds} second${seconds === 1 ? "" : "s"}`;
|
|
94
|
+
}
|
|
95
|
+
const minutes = Math.round(ms / 60_000);
|
|
96
|
+
const hours = Math.floor(minutes / 60);
|
|
97
|
+
const rest = minutes % 60;
|
|
98
|
+
const parts: string[] = [];
|
|
99
|
+
if (hours > 0) parts.push(`${hours} hour${hours === 1 ? "" : "s"}`);
|
|
100
|
+
if (rest > 0) parts.push(`${rest} minute${rest === 1 ? "" : "s"}`);
|
|
101
|
+
return parts.join(" ");
|
|
79
102
|
}
|
|
80
103
|
|
|
81
104
|
export function runPauseCommand(opts: PauseCommandOptions): PauseCommandResult {
|
|
82
105
|
const now = opts.now ?? Date.now();
|
|
83
106
|
const cwd = opts.cwd ?? process.cwd();
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
// different command.
|
|
91
|
-
if (active.length === 0) {
|
|
92
|
-
const pairs: Array<[string, string]> = [["enforcement", "active — nothing is paused"]];
|
|
93
|
-
return { exitCode: 0, lines: rows(pairs, renderOpts), rows: pairs, affected: 0 };
|
|
94
|
-
}
|
|
95
|
-
const pairs: Array<[string, string]> = [
|
|
96
|
-
["enforcement", `paused for ${active.length} session${active.length === 1 ? "" : "s"}`],
|
|
97
|
-
...active.map((p) => [p.sessionId, describe(p, now).trim()] as [string, string]),
|
|
98
|
-
];
|
|
99
|
-
const trailer = stack(
|
|
100
|
-
note("Cloud-managed policies keep enforcing regardless.", renderOpts),
|
|
101
|
-
nextStep("failproofai config --resume", "Resume early with:", renderOpts),
|
|
102
|
-
);
|
|
103
|
-
return {
|
|
104
|
-
exitCode: 0,
|
|
105
|
-
rows: pairs,
|
|
106
|
-
trailer,
|
|
107
|
-
lines: stack(rows(pairs, renderOpts), trailer),
|
|
108
|
-
affected: active.length,
|
|
109
|
-
};
|
|
110
|
-
}
|
|
107
|
+
// Painted for the stream it lands on: a result goes to stdout and a refusal to
|
|
108
|
+
// stderr, and only one of the two may be a terminal.
|
|
109
|
+
const kitFor = (ok: boolean) => screenKit(opts.render ?? optsFor(ok ? process.stdout : process.stderr));
|
|
110
|
+
// "this session" is the one resolved from this directory; a session named on
|
|
111
|
+
// the command line is named back, so a pause set from elsewhere says whose it is.
|
|
112
|
+
const target = (explicit: string | undefined) => (explicit ? `session ${explicit}` : "this session");
|
|
111
113
|
|
|
112
114
|
if (opts.action === "resume") {
|
|
115
|
+
const kit = kitFor(true);
|
|
113
116
|
if (opts.all) {
|
|
114
117
|
const active = listActivePauses(now);
|
|
115
118
|
let cleared = 0;
|
|
116
119
|
for (const pause of active) if (clearPause(pause.sessionId)) cleared++;
|
|
117
120
|
return {
|
|
118
121
|
exitCode: 0,
|
|
119
|
-
lines: [
|
|
122
|
+
lines: [
|
|
123
|
+
cleared === 0
|
|
124
|
+
? "Nothing was paused."
|
|
125
|
+
: kit.ok(`Resumed enforcement for ${cleared} session${cleared === 1 ? "" : "s"}.`),
|
|
126
|
+
],
|
|
120
127
|
affected: cleared,
|
|
121
128
|
};
|
|
122
129
|
}
|
|
@@ -127,7 +134,11 @@ export function runPauseCommand(opts: PauseCommandOptions): PauseCommandResult {
|
|
|
127
134
|
const cleared = clearPause(sessionId);
|
|
128
135
|
return {
|
|
129
136
|
exitCode: 0,
|
|
130
|
-
lines: [
|
|
137
|
+
lines: [
|
|
138
|
+
cleared
|
|
139
|
+
? kit.ok(`Resumed enforcement for ${target(opts.sessionId)}.`)
|
|
140
|
+
: `Nothing was paused for ${opts.sessionId ? `session ${opts.sessionId}` : "that session"}.`,
|
|
141
|
+
],
|
|
131
142
|
affected: cleared ? 1 : 0,
|
|
132
143
|
};
|
|
133
144
|
}
|
|
@@ -137,46 +148,55 @@ export function runPauseCommand(opts: PauseCommandOptions): PauseCommandResult {
|
|
|
137
148
|
try {
|
|
138
149
|
durationMs = parsePauseDuration(opts.duration, effectiveCeilingMs());
|
|
139
150
|
} catch (err) {
|
|
140
|
-
return {
|
|
151
|
+
return {
|
|
152
|
+
exitCode: 1,
|
|
153
|
+
lines: [kitFor(false).fail(err instanceof Error ? err.message : String(err))],
|
|
154
|
+
affected: 0,
|
|
155
|
+
};
|
|
141
156
|
}
|
|
142
157
|
|
|
143
158
|
const sessionId = opts.sessionId ?? resolveSessionForCwd(cwd, undefined, now);
|
|
144
159
|
if (!sessionId) {
|
|
145
160
|
// Deliberately an error, not a guess. Pausing the wrong session would leave
|
|
146
161
|
// the user believing enforcement is off while it is on, or vice versa.
|
|
162
|
+
const kit = kitFor(false);
|
|
163
|
+
const retry = `failproofai config --pause${opts.duration ? ` ${opts.duration}` : ""} --session <id>`;
|
|
147
164
|
return {
|
|
148
165
|
exitCode: 1,
|
|
149
166
|
lines: [
|
|
150
|
-
"No recent agent session found for this directory.",
|
|
151
|
-
|
|
152
|
-
"A pause applies to one agent session, and the session id only appears once",
|
|
153
|
-
"an agent has run at least one tool call here. Either run your agent first,",
|
|
154
|
-
"or name the session explicitly:",
|
|
155
|
-
"",
|
|
156
|
-
" failproofai config --pause --session <id>",
|
|
157
|
-
"",
|
|
158
|
-
"Session ids are listed in the dashboard's activity view.",
|
|
167
|
+
kit.fail("No recent agent session found for this directory."),
|
|
168
|
+
`${INDENT}Name one from the dashboard's activity view: ${kit.cmd(retry)}`,
|
|
159
169
|
],
|
|
160
170
|
affected: 0,
|
|
161
171
|
};
|
|
162
172
|
}
|
|
163
173
|
|
|
174
|
+
const kit = kitFor(true);
|
|
164
175
|
const existing = readActivePause(sessionId, now);
|
|
165
176
|
const pause = writePause({ sessionId, durationMs, cwd, setBy: "cli", now });
|
|
166
|
-
|
|
177
|
+
// What was actually granted, not what was asked for: a renewal is capped at 8h
|
|
178
|
+
// from the FIRST pause in the run, so it can be shorter than requested, and a
|
|
179
|
+
// line repeating the request would misstate when enforcement comes back.
|
|
180
|
+
const granted = Math.max(0, pause.expiresAt - now);
|
|
181
|
+
const capped = pause.expiresAt < now + durationMs;
|
|
182
|
+
const when = `until ${pauseClockTime(pause.expiresAt, opts.clock)} (${pauseDurationWords(granted)})`;
|
|
183
|
+
const resume = opts.sessionId
|
|
184
|
+
? `failproofai config --resume --session ${opts.sessionId}`
|
|
185
|
+
: "failproofai config --resume";
|
|
167
186
|
|
|
168
187
|
return {
|
|
169
188
|
exitCode: 0,
|
|
170
189
|
lines: [
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
190
|
+
kit.ok(
|
|
191
|
+
existing
|
|
192
|
+
? `Extended the pause for ${target(opts.sessionId)} ${when}.`
|
|
193
|
+
: `Paused enforcement for ${target(opts.sessionId)} ${when}.`,
|
|
194
|
+
),
|
|
195
|
+
...(capped
|
|
196
|
+
? [`${INDENT}Capped at ${pauseDurationWords(PAUSE_CEILING_MS)} from when this pause began.`]
|
|
197
|
+
: []),
|
|
198
|
+
`${INDENT}Cloud-managed policies keep enforcing.`,
|
|
199
|
+
`${INDENT}Resume early: ${kit.cmd(resume)}`,
|
|
180
200
|
],
|
|
181
201
|
affected: 1,
|
|
182
202
|
};
|