Trace if run tree set (#12444)

This code path is hit in the following case:
- Start in langchain code and manually provide a tracer
- Handoff to the traceable
- Hand back to langchain code.

Which happens for evaluating `@traceable` functions unfortunately
pull/12445/head
William FH 11 months ago committed by GitHub
parent c2a0a6b6df
commit 5d40e36c75
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1956,7 +1956,9 @@ def _configure(
tracer_v2 = tracing_v2_callback_var.get()
tracing_v2_enabled_ = (
env_var_is_set("LANGCHAIN_TRACING_V2") or tracer_v2 is not None
env_var_is_set("LANGCHAIN_TRACING_V2")
or tracer_v2 is not None
or run_tree is not None
)
tracer_project = getattr(
run_tree,

Loading…
Cancel
Save