fix(diagnosis): return BlameTarget.NONE for healthy items instead of UNKNOWN#216
Merged
himanshu231204 merged 3 commits intoJul 23, 2026
Merged
Conversation
…UNKNOWN When no failures are detected, blame attribution now returns NONE with confidence 1.0 instead of UNKNOWN with confidence 0.0. This separates 'analysis succeeded, no issues' from 'could not determine blame'. Fixes OpenAgentHQ#67
|
🎉 Congratulations @syf2211! Your pull request has been successfully merged into main. 🚀 Thank you for contributing to OpenAgentHQ and helping improve the project. We truly appreciate your contribution and hope to see you back with more amazing PRs! Happy Open Sourcing! ❤️ |
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
When blame attribution finds no failures, it now returns
BlameTarget.NONE(confidence 1.0) instead ofBlameTarget.UNKNOWN(confidence 0.0). This separates "analysis succeeded, no issues" from "could not determine blame".Fixes #67
Motivation
BlameTarget.UNKNOWNimplied indeterminate analysis, but was returned for healthy items with no failures. This semantic mismatch causedDiagnosisAnalyzerto count healthy items by checkingUNKNOWN, which is confusing for API consumers and report readers.Changes
BlameTarget.NONE = "none"enum value with docstring clarifying NONE vs UNKNOWN semanticsBlameAttribution._determine_blame()returnsNONEwith confidence 1.0 when no failures are detectedDiagnosisAnalyzercounts healthy items viaBlameTarget.NONEinstead ofUNKNOWN[green]Healthy[/green]for NONE targetsTests
Notes
BlameTarget.UNKNOWNis retained for future genuinely indeterminate cases but is not returned byBlameAttribution.analyze()todaytarget == BlameTarget.UNKNOWNto detect healthy items; they should now checkBlameTarget.NONE