Skip to content

ROB-3921 - Add user_email field to Holmes chat params#2084

Merged
alonelish merged 1 commit into
masterfrom
claude/crazy-hodgkin-e2a4cc
May 19, 2026
Merged

ROB-3921 - Add user_email field to Holmes chat params#2084
alonelish merged 1 commit into
masterfrom
claude/crazy-hodgkin-e2a4cc

Conversation

@alonelish
Copy link
Copy Markdown
Collaborator

Summary

  • Declare user_email: Optional[str] = None on HolmesChatParams (frontend → runner) and HolmesChatRequest (runner → Holmes), placed next to request_source to match the sibling pattern.
  • HolmesIssueChatParams / HolmesIssueChatRequest inherit from these, so they pick up the field automatically.

Why

The frontend has started sending user_email on chat requests. Both models already have class Config: extra = "allow" and the runner forwards params via params.dict()HolmesChatRequest(**params_dict), so the field would already flow through transparently to Holmes without code changes. However, every sibling field (request_type, request_source, conversation_id, source_ref, …) is declared explicitly, and adding user_email to that list gives:

  • type validation (Optional[str])
  • grep-ability / IDE autocomplete
  • a documented contract for readers of the model

Test plan

  • Confirm runner accepts a chat request with user_email and forwards it to Holmes unchanged
  • Confirm requests without user_email still work (field is optional, defaults to None)

🤖 Generated with Claude Code

Declare user_email explicitly on HolmesChatParams and HolmesChatRequest
to match the existing pattern for sibling fields like request_type and
request_source. The frontend has started sending user_email; while the
extra="allow" config would forward it transparently, an explicit field
gives validation, IDE hints, and a documented contract.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 19, 2026

Docker image ready for 177e1f2 (built in 2m 58s)

⚠️ Warning: does not support ARM (ARM images are built on release only - not on every PR)

Use this tag to pull the image for testing.

📋 Copy commands

⚠️ Temporary images are deleted after 30 days. Copy to a permanent registry before using them:

gcloud auth configure-docker us-central1-docker.pkg.dev
docker pull us-central1-docker.pkg.dev/robusta-development/temporary-builds/robusta-runner:177e1f2
docker tag us-central1-docker.pkg.dev/robusta-development/temporary-builds/robusta-runner:177e1f2 me-west1-docker.pkg.dev/robusta-development/development/robusta-runner-dev:177e1f2
docker push me-west1-docker.pkg.dev/robusta-development/development/robusta-runner-dev:177e1f2

Patch Helm values in one line:

helm upgrade --install robusta robusta/robusta \
  --reuse-values \
  --set runner.image=me-west1-docker.pkg.dev/robusta-development/development/robusta-runner-dev:177e1f2

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 19, 2026

Review Change Stack

Walkthrough

This PR adds an optional user_email field to two related Holmes chat Pydantic models: HolmesChatParams in the base parameters module and HolmesChatRequest in the Holmes reporting module, each defaulting to None.

Changes

Holmes Chat User Email Field

Layer / File(s) Summary
Add user_email field to Holmes chat schemas
src/robusta/core/model/base_params.py, src/robusta/core/reporting/holmes.py
Extended HolmesChatParams and HolmesChatRequest Pydantic models with optional user_email field (Optional[str] = None).

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

  • robusta-dev/robusta#2058: Both PRs modify the same Holmes chat Pydantic schemas (HolmesChatParams and HolmesChatRequest) to extend Holmes chat schema fields.

Suggested reviewers

  • moshemorad
  • naomi-robusta
  • Avi-Robusta
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description check ✅ Passed The description is well-related to the changeset, explaining the rationale, implementation details, and testing approach for the new user_email field.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title accurately and specifically describes the main change: adding a user_email field to Holmes chat params models.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/crazy-hodgkin-e2a4cc

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@alonelish alonelish changed the title Add user_email field to Holmes chat params ROB-3921 - Add user_email field to Holmes chat params May 19, 2026
@alonelish alonelish merged commit 6c65f92 into master May 19, 2026
7 checks passed
@alonelish alonelish deleted the claude/crazy-hodgkin-e2a4cc branch May 19, 2026 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants