From a524db877a7fafc12c8c46133739c5e76bdf6074 Mon Sep 17 00:00:00 2001 From: marktech0813 Date: Fri, 24 Jul 2026 11:43:56 +0000 Subject: [PATCH] fix(config-lint): recognize fairnessAnalytics as a top-level field parseFocusManifest already supports fairnessAnalytics; omitting it from TOP_LEVEL_FIELDS caused a false unknown-field lint warning. Closes #8365 --- packages/loopover-engine/src/config-lint.ts | 1 + test/unit/selfhost-config-lint.test.ts | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/packages/loopover-engine/src/config-lint.ts b/packages/loopover-engine/src/config-lint.ts index 923e34fe7d..19c54ca5b4 100644 --- a/packages/loopover-engine/src/config-lint.ts +++ b/packages/loopover-engine/src/config-lint.ts @@ -28,6 +28,7 @@ const TOP_LEVEL_FIELDS = [ "activeReviewReconciliation", "loopEscalation", "federatedIntelligence", + "fairnessAnalytics", ] as const; const TOP_LEVEL_FIELD_SET = new Set(TOP_LEVEL_FIELDS); diff --git a/test/unit/selfhost-config-lint.test.ts b/test/unit/selfhost-config-lint.test.ts index 3728080874..f1cf6542d2 100644 --- a/test/unit/selfhost-config-lint.test.ts +++ b/test/unit/selfhost-config-lint.test.ts @@ -86,6 +86,16 @@ reviewRecap: expect(result.recognizedFields).toEqual(["experimental"]); }); + it("REGRESSION: recognizes a standalone fairnessAnalytics: block instead of flagging it as unknown (#8365)", () => { + // fairnessAnalytics is fully parsed by focus-manifest.ts but was missing from TOP_LEVEL_FIELDS, + // so operators got a spurious unknown-field warning for a supported config-as-code block. + const result = lintManifestText("fairnessAnalytics:\n enabled: true\n"); + + expect(result.ok).toBe(true); + expect(result.warnings).toEqual([]); + expect(result.recognizedFields).toEqual(["fairnessAnalytics"]); + }); + it("recognizes a standalone reviewRecap: block instead of flagging it as unknown (#1963)", () => { const result = lintManifestText("reviewRecap:\n enabled: true\n cadenceDays: 14\n");