Skip to content

Commit c34b011

Browse files
committed
Use pydantic model name as default title value
1 parent bf9a8e8 commit c34b011

File tree

1 file changed

+1
-1
lines changed
  • instrumentation/opentelemetry-instrumentation-tortoiseorm/src/opentelemetry/instrumentation/tortoiseorm

1 file changed

+1
-1
lines changed

instrumentation/opentelemetry-instrumentation-tortoiseorm/src/opentelemetry/instrumentation/tortoiseorm/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ async def _from_queryset(self, func, modelcls, args, kwargs):
300300

301301
model_config = getattr(modelcls, "Config", None)
302302
if model_config:
303-
model_title = getattr(modelcls.Config, "title")
303+
model_title = getattr(modelcls.Config, "title", modelcls.__name__)
304304
if model_title:
305305
span_attributes["pydantic.model"] = model_title
306306

0 commit comments

Comments
 (0)