Repository navigation
Conversation
…the exact recipient set
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Normalize and match recipients packages/gooddata-eval/src/gooddata_eval/core/agentic/alert_skill.py, packages/gooddata-eval/tests/test_agentic_alert_skill.py |
The evaluator normalizes recipient arguments and checks external addresses and resolved internal IDs for exact matches. Tests cover JSON-encoded values, delimited external recipients, per-email lookups, and malformed internal entries. |
Priority:
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix
Possibly related PRs
- gooddata/gooddata-python-sdk#1902: Both changes modify alert evaluation in
alert_skill.py; that PR adds other alert checks and centralizes alert check handling.
Merge Risk: 
Minimal · up to af14e
-
The recipient-matching change is ready to merge after normal checks.
Pre-merge checks: 
4 · 
1
-
Failed checks: 1 warning Passed checks: 4 passed -
Finishing Touches: 💡 1
-
📝 Generate docstrings: 💡
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
A rabbit sorts the names with care,
And checks each address in the pair.
The commas part, the JSON’s read,
Each user ID is checked for need.
Exact matches make the list complete,
Then hops away on quiet feet.
Comment @coderabbitai help to get the list of available commands.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1904 +/- ##
==========================================
+ Coverage 85.65% 85.74% +0.08%
==========================================
Files 343 343
Lines 25069 25155 +86
==========================================
+ Hits 21472 21568 +96
+ Misses 3597 3587 -10 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Summary
agent_alert_skillwas 0/21 on every haiku leg (anthropic and bedrock, medium and high) in nightly run 40229016049. Every run failed onlyrecipients_correct. The agent and gen-ai were correct; the agentic checker (core/agentic/alert_skill.py) graded them wrong.JSON-encoded recipients
'internal_recipients': '["admin"]'(a string); OpenAI models send['admin']. The tool schema allows both (anyOf: [array of string, string, null]), and gen-ai decodes the string before calling the server (_as_listingdc_mcp_client_factory.py).external_recipients, but wrapped a stringinternal_recipientsas one id, so["admin"]never matched the current useradmin._recipient_list, that mirrors gen-ai: empty or"null"means none, a JSON list of strings is that list, anything else is a bare value. A non-string list entry now scores False instead of raisingTypeError.Exact recipient set for email-only alerts
recipients_correct=True.Not changed: the single-shot scorer
core/evaluators/alert_skill.pyalso fails"Recipient(s)": "me"for correct arguments. It reads onlyrecipients/externalRecipientsand has no current-user id. Nightly does not use it (tavern-e2e calls the agentic path), and fixing it needs the evaluator interface to carry the current user, so it is left for a separate change.Test Plan
TEST_ENVS=py314 make -C packages/gooddata-eval test: 2439 passed, 1 skipped. Also with this commit applied on current master (after fix(gooddata-eval): assert alert comparison, title and dashboard #1902): 2482 passed, 1 skipped.make -C packages/gooddata-eval format lint type-check: clean.'["admin"]','admin'and['admin']pass for expectedme;'["someone_else"]','[]','null'and''fail; JSON-stringme+ email; everyexternal_recipientsshape; and missing, extra and duplicate recipients on the email-only path. The JSON-string and strict email cases fail on the previous code.recipients_correct=True, and no other check failed in them. The one logged gpt6luna record is unchanged. Thethreshold: 20run of gpt6luna item 16 is not in the log, but the threshold check is untouched and still failsthreshold=20.Risk
nonprod. This changes only the eval package's scoring. Items that expect "me" (all of
agent_alert_skill) now pass when the model JSON-encodes the recipient. An email-only item now fails when the agent leaves out a recipient or adds one.JIRA: QA-29902
🤖 Generated with Claude Code
Summary by CodeRabbit