Skip to content

Commit

Permalink
fix: check tracer_provider type
Browse files Browse the repository at this point in the history
  • Loading branch information
zhengfeiwang committed Apr 11, 2024
1 parent 8df1c3d commit 10e7478
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/promptflow-devkit/promptflow/_sdk/_tracing.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,11 @@
def is_trace_feature_disabled() -> bool:
from promptflow._sdk._configuration import Configuration

return Configuration.get_instance().get_trace_provider().lower() == PF_CONFIG_TRACE_FEATURE_DISABLE
trace_provider = Configuration.get_instance().get_trace_provider()
if isinstance(trace_provider, str):
return Configuration.get_instance().get_trace_provider().lower() == PF_CONFIG_TRACE_FEATURE_DISABLE
else:
return False


def get_ws_tracing_base_url(ws_triad: AzureMLWorkspaceTriad) -> str:
Expand Down

0 comments on commit 10e7478

Please sign in to comment.