Skip to content

chore(llmobs): make mlapp error message more helpful [backport 3.9] #13735

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
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 ddtrace/llmobs/_llmobs.py
Original file line number Diff line number Diff line change
Expand Up @@ -812,8 +812,9 @@ def _start_span(
ml_app = ml_app if ml_app is not None else _get_ml_app(span)
if ml_app is None:
raise ValueError(
"ML app is required for sending LLM Observability data. "
"Ensure this configuration is set before running your application."
"ml_app is required for sending LLM Observability data. "
"Ensure the name of your LLM application is set via `DD_LLMOBS_ML_APP` or `LLMObs.enable(ml_app='...')`"
"before running your application."
)
span._set_ctx_items({DECORATOR: _decorator, SPAN_KIND: operation_kind, ML_APP: ml_app})
return span
Expand Down
Loading