Skip to content

Commit e4ec031

Browse files
alonelishclaude
andcommitted
Fix validate_toolset: use event.response, add light action, update status field
- Fix AttributeError by using event.response instead of event.ws() - Add holmes_validate_toolset to lightActions in Helm values - Update status field description to 'valid'/'invalid' Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 4122b14 commit e4ec031

3 files changed

Lines changed: 3 additions & 2 deletions

File tree

helm/robusta/values.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ lightActions:
9797
- holmes_conversation
9898
- holmes_issue_chat
9999
- holmes_chat
100+
- holmes_validate_toolset
100101
- list_pods
101102
- kubectl_describe
102103
- fetch_resource_yaml

src/robusta/core/playbooks/internal/ai_integration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ def holmes_validate_toolset(event: ExecutionBaseEvent, params: HolmesValidateToo
403403
result = requests.post(url, data=holmes_req.json())
404404
result.raise_for_status()
405405
holmes_response = HolmesValidateToolsetResponse(**json.loads(result.text))
406-
event.ws(data=json.dumps(holmes_response.dict()))
406+
event.response = {"success": True, **holmes_response.dict()}
407407

408408
except Exception as e:
409409
logging.exception("Failed to validate toolset via Holmes", exc_info=True)

src/robusta/core/reporting/holmes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ class HolmesValidateToolsetRequest(BaseModel):
103103

104104
class HolmesValidateToolsetResult(BaseModel):
105105
toolset_name: str
106-
status: str = Field(description="Toolset status: 'enabled' or 'failed'")
106+
status: str = Field(description="Toolset status: 'valid' or 'invalid'")
107107
error: Optional[str] = None
108108
description: Optional[str] = None
109109

0 commit comments

Comments
 (0)