failproofai 1.0.0-beta.13 → 1.0.0-beta.15
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 +3 -3
- package/.next/standalone/.next/prerender-manifest.json +3 -3
- package/.next/standalone/.next/required-server-files.json +1 -1
- 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.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 +7 -7
- 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 +7 -7
- package/.next/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- 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.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 +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/_head.segment.rsc +4 -4
- package/.next/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +9 -9
- 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/_not-found.segment.rsc +3 -3
- package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/audit/page/server-reference-manifest.json +2 -2
- 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 +14 -14
- package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +14 -14
- package/.next/standalone/.next/server/app/index.segments/_head.segment.rsc +4 -4
- package/.next/standalone/.next/server/app/index.segments/_index.segment.rsc +9 -9
- package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/page/server-reference-manifest.json +1 -1
- 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/server-reference-manifest.json +10 -10
- 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/server-reference-manifest.json +1 -1
- 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/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.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/server-reference-manifest.json +1 -1
- 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/server-reference-manifest.json +4 -4
- 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/[root-of-the-server]__1uyc-z4._.js +1 -1
- package/.next/standalone/.next/server/chunks/_0lxbzdq._.js +1 -1
- package/.next/standalone/.next/server/chunks/_1zuiiy3._.js +1 -1
- 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]__1dx-a-c._.js → [root-of-the-server]__0er51rw._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0spkm68._.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__17itmx-._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0eeipso._.js → [root-of-the-server]__1i-hxx5._.js} +2 -2
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1mmefsr._.js +2 -2
- package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__1rv-sc9._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_0rjgfln._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_0vo2qyt._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_0xej-0e._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_10399ge._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_149k9oy._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/{_166jvu8._.js → _17aso1e._.js} +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_1_hwp06._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_1mnhi_r._.js +1 -1
- package/.next/standalone/.next/server/chunks/ssr/_1ror7k9._.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/middleware-build-manifest.js +3 -3
- 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 +15 -15
- package/.next/standalone/.next/static/chunks/{3l4-fu3xt75j8.js → 010huwv917_8b.js} +1 -1
- package/.next/standalone/.next/static/chunks/{0zbcd_n8ku2ov.js → 01ow5ctk14a3m.js} +1 -1
- package/.next/standalone/.next/static/chunks/{3poscoxn69x9g.js → 0t1a790b2z9zg.js} +1 -1
- package/.next/standalone/.next/static/chunks/{23hnlzqx44vbe.js → 1g4yf15nu24nl.js} +1 -1
- package/.next/standalone/.next/static/chunks/{2y42ebzynyxdv.js → 1hohlism5o738.js} +1 -1
- package/.next/standalone/.next/static/chunks/{31_px0dfgdg9j.js → 27fu32-3jq61l.js} +1 -1
- package/.next/standalone/.next/static/chunks/{1erji0ratofla.js → 2jgru_vga6bt2.js} +1 -1
- package/.next/standalone/.next/static/chunks/{01s3vpzky_qew.js → 2u1auvctu_c9g.js} +1 -1
- package/.next/standalone/.next/static/chunks/{2cwsiyhc7d2cw.js → 37bhx_w0e5rja.js} +1 -1
- package/.next/standalone/.next/static/chunks/{315lncj7dsp9c.js → 3sd3fplldbaob.js} +1 -1
- package/.next/standalone/package.json +9 -9
- package/.next/standalone/server.js +1 -1
- package/bin/failproofai.mjs +15 -3
- package/dist/cli.mjs +29 -14
- package/dist/worker.mjs +1 -1
- package/package.json +9 -9
- package/src/hooks/collector-config.ts +1 -1
- package/src/hooks/configure-wizard.ts +1 -1
- package/src/hooks/daemon-service.ts +18 -1
- package/src/hooks/fp-config.ts +1 -1
- package/src/hooks/fp-home.ts +2 -2
- package/src/hooks/harness-cli.ts +5 -5
- /package/.next/standalone/.next/static/{ziAsXfNE0cH_S7LHK-Py3 → o2yNxSgw7WN_rtuWqOzIo}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{ziAsXfNE0cH_S7LHK-Py3 → o2yNxSgw7WN_rtuWqOzIo}/_clientMiddlewareManifest.js +0 -0
- /package/.next/standalone/.next/static/{ziAsXfNE0cH_S7LHK-Py3 → o2yNxSgw7WN_rtuWqOzIo}/_ssgManifest.js +0 -0
|
@@ -393,8 +393,25 @@ function systemdUnitName(user: string = serviceUser()): string {
|
|
|
393
393
|
return `failproofaid@${user}.service`;
|
|
394
394
|
}
|
|
395
395
|
|
|
396
|
+
/**
|
|
397
|
+
* The unit directory, redirectable for tests ONLY.
|
|
398
|
+
*
|
|
399
|
+
* It was hardcoded, which left a test asserting "a failed install writes
|
|
400
|
+
* nothing" checking the REAL `/etc/systemd/system` — so it passed in CI, where
|
|
401
|
+
* nothing is installed, and failed on the machine of anyone who actually uses
|
|
402
|
+
* failproofai, whose genuine unit file is sitting right there. That is the bug
|
|
403
|
+
* class `handler.test.ts`'s header already documents: CI is green, so the red is
|
|
404
|
+
* only ever seen locally, by exactly the people who most need to trust the suite.
|
|
405
|
+
*
|
|
406
|
+
* Read through a function rather than captured at module load, because a test
|
|
407
|
+
* sets it after importing this module.
|
|
408
|
+
*/
|
|
409
|
+
function systemdUnitDir(): string {
|
|
410
|
+
return process.env.FAILPROOFAI_SYSTEMD_DIR || "/etc/systemd/system";
|
|
411
|
+
}
|
|
412
|
+
|
|
396
413
|
function systemdUnitPath(user: string = serviceUser()): string {
|
|
397
|
-
return resolve(
|
|
414
|
+
return resolve(systemdUnitDir(), systemdUnitName(user));
|
|
398
415
|
}
|
|
399
416
|
|
|
400
417
|
/**
|
package/src/hooks/fp-config.ts
CHANGED
|
@@ -242,7 +242,7 @@ export interface FpConfig {
|
|
|
242
242
|
machineId?: string;
|
|
243
243
|
/**
|
|
244
244
|
* Extra locations to capture per harness, beyond the one each source ships
|
|
245
|
-
* with — `
|
|
245
|
+
* with — `collector.sources.<harness>.extra_paths` in `config.json`.
|
|
246
246
|
*
|
|
247
247
|
* Each entry is `label=path` or a bare `path`; the label becomes an agent-id
|
|
248
248
|
* namespace (`<label>-<agentId>`), which is what keeps two copies of one
|
package/src/hooks/fp-home.ts
CHANGED
|
@@ -269,7 +269,7 @@ export const sessionPauseDir = () => resolve(stateDir(), "sessions");
|
|
|
269
269
|
* The DAEMON is the sole writer (`crates/failproofaid/src/audit_lane.rs`, which
|
|
270
270
|
* mirrors this path in `paths.rs`) — it owns the schedule, and a second writer
|
|
271
271
|
* racing it could hand a machine two full scans back to back. Everything on this
|
|
272
|
-
* side reads it: the interval itself lives in `config.
|
|
272
|
+
* side reads it: the interval itself lives in `config.json`'s `audit` object,
|
|
273
273
|
* which a human edits, while this file is derived state a human never opens,
|
|
274
274
|
* which is why it sits under `state/` rather than beside the audit results.
|
|
275
275
|
*/
|
|
@@ -285,7 +285,7 @@ export const auditScheduleFile = (home?: string) => resolve(stateDir(home), "aud
|
|
|
285
285
|
* `x64` where Rust says `x86_64`), and a near-miss there does not fail, it
|
|
286
286
|
* silently files one machine under two PostHog persons — so this file is how the
|
|
287
287
|
* two agree. Derived state a human never opens, hence `state/` rather than
|
|
288
|
-
* beside `config.
|
|
288
|
+
* beside `config.json`.
|
|
289
289
|
*/
|
|
290
290
|
export const telemetryIdFile = (home?: string) => resolve(stateDir(home), "telemetry-id");
|
|
291
291
|
export const launcherMarker = (home?: string) => resolve(stateDir(home), "launcher-configured");
|
package/src/hooks/harness-cli.ts
CHANGED
|
@@ -18,13 +18,13 @@
|
|
|
18
18
|
* from the feature working.
|
|
19
19
|
*
|
|
20
20
|
* The one thing validated here is the HARNESS NAME, because that failure has no
|
|
21
|
-
* other detector: `
|
|
21
|
+
* other detector: `collector.sources.claud` is valid JSON, parses cleanly,
|
|
22
22
|
* captures nothing, and is mentioned nowhere else a user would look.
|
|
23
23
|
*
|
|
24
24
|
* # No restart, and no sudo
|
|
25
25
|
*
|
|
26
26
|
* This writes one file in the user's own home and nothing else. The daemon's
|
|
27
|
-
* collector manager re-reads `config.
|
|
27
|
+
* collector manager re-reads `config.json` on an interval and cycles the
|
|
28
28
|
* collector whenever the resolved `CollectorConfig` changes — the same path
|
|
29
29
|
* that already picks up `--connect`, a stream being switched off, and a
|
|
30
30
|
* verbosity change. `extra_paths` rides it for free by living inside
|
|
@@ -39,7 +39,7 @@ import { readConfig, updateConfig } from "./fp-config";
|
|
|
39
39
|
import { configFile } from "./fp-home";
|
|
40
40
|
|
|
41
41
|
/**
|
|
42
|
-
* Harness keys `
|
|
42
|
+
* Harness keys `collector.sources.<key>` accepts.
|
|
43
43
|
*
|
|
44
44
|
* MUST stay in step with `HARNESS_KEYS` in `crates/failproofaid/src/main.rs`,
|
|
45
45
|
* which is the side that actually registers the tasks. A name here that the
|
|
@@ -124,7 +124,7 @@ function writePaths(harness: string, paths: string[]): void {
|
|
|
124
124
|
/**
|
|
125
125
|
* No restart, and deliberately no instruction to perform one.
|
|
126
126
|
*
|
|
127
|
-
* The daemon's collector manager re-reads `config.
|
|
127
|
+
* The daemon's collector manager re-reads `config.json` on an interval and
|
|
128
128
|
* cycles the collector whenever the resolved `CollectorConfig` changes — the
|
|
129
129
|
* same path that already picks up `--connect`, a stream being switched off and
|
|
130
130
|
* a verbosity change. `extra_paths` rides that for free because it lives inside
|
|
@@ -266,7 +266,7 @@ export function listPaths(harness?: string): HarnessResult {
|
|
|
266
266
|
}
|
|
267
267
|
}
|
|
268
268
|
// Unknown tables are surfaced here as well as by the daemon: a user who
|
|
269
|
-
// hand-edited config.
|
|
269
|
+
// hand-edited config.json runs `list` to check it, and that is the moment the
|
|
270
270
|
// typo is cheapest to find.
|
|
271
271
|
if (unknown.length > 0) {
|
|
272
272
|
if (lines.length === 0) lines.push("No extra capture paths configured for any known harness.");
|
|
File without changes
|
|
File without changes
|
|
File without changes
|