Skip to content

Commit 8eec52e

Browse files
committed
skip instrumentations and avoid blocking other vendors
1 parent 232c862 commit 8eec52e

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/langtrace_python_sdk/langtrace.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,10 @@ def init_instrumentations(
222222
if disable_instrumentations is None:
223223
for name, v in all_instrumentations.items():
224224
if is_package_installed(name):
225-
v.instrument()
225+
try:
226+
v.instrument()
227+
except Exception as e:
228+
print(f"Skipping {name} due to error while instrumenting: {e}")
226229

227230
else:
228231

@@ -244,4 +247,7 @@ def init_instrumentations(
244247

245248
for name, v in filtered_dict.items():
246249
if is_package_installed(name):
247-
v.instrument()
250+
try:
251+
v.instrument()
252+
except Exception as e:
253+
print(f"Skipping {name} due to error while instrumenting: {e}")

0 commit comments

Comments
 (0)