fix(engine): include fairnessAnalytics in parseFocusManifest's emptiness check - #8414
Conversation
…ess check
parseFocusManifest's aggregate condition deciding whether to emit a "no
recognized focus fields" warning and force manifest.present = false
checks !manifest.X.present for every other optional block (gate,
publicStats, draftFlow, ... federatedIntelligence), but omitted
fairnessAnalytics even though it's parsed and assigned identically to
every sibling. A .loopover.yml containing only a populated
fairnessAnalytics: block was correctly parsed into
{ present: true, enabled: true } but then incorrectly forced back to
manifest.present = false with a misleading empty-manifest warning,
since the aggregate check never saw it.
Added the missing !manifest.fairnessAnalytics.present term in the same
position the field is parsed in (between publicStats and draftFlow).
Added a dedicated fairnessAnalytics: test block mirroring the existing
publicStats: suite -- this block had no test coverage at all before,
including the specific regression case (fairnessAnalytics-only manifest
stays present with no spurious warning).
Fixes JSONbored#8366
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8414 +/- ##
=======================================
Coverage 92.42% 92.42%
=======================================
Files 791 791
Lines 79259 79259
Branches 23948 23947 -1
=======================================
Hits 73252 73252
+ Misses 4868 4866 -2
- Partials 1139 1141 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
|
|
Tip ✅ LoopOver review result - approve/merge recommendedReview updated: 2026-07-24 12:45:55 UTC
Review summary Nits — 2 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
Summary
parseFocusManifest's aggregate condition (deciding whether to emit a "no recognized focus fields" warning and forcemanifest.present = false) checks!manifest.X.presentfor every other optional block (gate,publicStats,draftFlow, ...federatedIntelligence), but omittedfairnessAnalyticseven though it's parsed and assigned identically to every sibling block.Concrete failure: a
.loopover.ymlcontaining only a populatedfairnessAnalytics:block (e.g.fairnessAnalytics: { enabled: true }) was correctly parsed intomanifest.fairnessAnalytics = { present: true, enabled: true }, but the aggregate check never saw it, so the manifest was still incorrectly forced topresent: falsewith a misleading "no recognized focus fields" warning.Fix
Added the missing
!manifest.fairnessAnalytics.presentterm, in the same relative positionfairnessAnalyticsis parsed in (betweenpublicStatsanddraftFlow). No other block's condition orparseFairnessAnalyticsConfigitself was touched.Added a dedicated
fairnessAnalytics:test block mirroring the existingpublicStats:suite exactly -- this block had zero test coverage before this PR (confirmed: no existing test referencedparseFairnessAnalyticsConfigor thefairnessAnalyticsfield at all beyond an unrelated settings-alias fixture), including the specific regression case this issue describes.Scope
type(scope): short summaryConventional Commit format.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Fixes #8366
Validation
git diff --checknpm run actionlint(no workflow changes)npm run typecheck(clean)npx vitest run test/unit/focus-manifest.test.ts-- 792/792 passing (9 new tests)--coverage.include="packages/loopover-engine/src/focus-manifest.ts": the new line is not in the uncovered-lines list; all pre-existing uncovered lines are unrelated to this diffnpm run docs:drift-check-- passes (102 FocusManifest fields all documented, unchanged field count since this adds a check, not a new field)npm run ui:openapi:check(no API/schema changes)npm audit --audit-level=moderate(no dependency changes)If any required check was skipped, explain why: no workflow, API, OpenAPI, or dependency surface is touched -- this is a one-line condition fix plus its own dedicated test block in
packages/loopover-engine.Safety
UI Evidencesection below with JPG/JPEG or PNG screenshots. (N/A -- zeroapps/loopover-ui/**or any visual-surface changes in this PR.)