File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed
pydantic_ai_slim/pydantic_ai/agent Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -717,14 +717,11 @@ def _run_span_end_attributes(
717717 attrs ['pydantic_ai.variable_instructions' ] = True
718718
719719 extra_attributes : dict [str , str ] = {}
720- span_attrs_setting = settings .span_attributes
721- if span_attrs_setting :
722- if callable (span_attrs_setting ):
723- resolved_attrs = span_attrs_setting (run_ctx )
724- if resolved_attrs :
725- extra_attributes = dict (resolved_attrs )
720+ if settings .span_attributes :
721+ if callable (settings .span_attributes ):
722+ extra_attributes = settings .span_attributes (run_ctx )
726723 else :
727- extra_attributes = dict ( span_attrs_setting )
724+ extra_attributes = settings . span_attributes
728725
729726 return {
730727 ** usage .opentelemetry_attributes (),
You can’t perform that action at this time.
0 commit comments