Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions cmk/plugins/hp_proliant/agent_based/hp_proliant_da_cntlr.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,8 +187,9 @@ def parse_hp_proliant_da_cntlr(string_table: StringTable) -> ParsedSection:


def discovery_hp_proliant_da_cntlr(section: ParsedSection) -> DiscoveryResult:
if section:
yield from (Service(item=item) for item in section)
# Skip phantom placeholder rows (all-zero cells, parsed to ``None``): they
# are not real controllers and would produce a permanently UNKNOWN service.
yield from (Service(item=item) for item, data in section.items() if data is not None)


def check_hp_proliant_da_cntlr(item: ControllerID, section: ParsedSection) -> CheckResult:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ def test_discovery() -> None:
Service(item="0"),
Service(item="3"),
Service(item="6"),
Service(item="9"),
]


Expand Down
Loading