This is an automated email from the ASF dual-hosted git repository.

skrawcz pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/burr.git


The following commit(s) were added to refs/heads/main by this push:
     new a3e253ac fix: instantiate instrumentor class before calling 
instrument() (#684)
a3e253ac is described below

commit a3e253ac093574e4609dd6c82684b2e5501c58d3
Author: AndrĂ© Ahlert <[email protected]>
AuthorDate: Sat Mar 21 01:56:24 2026 -0300

    fix: instantiate instrumentor class before calling instrument() (#684)
    
    _init_instrument was accessing is_instrumented_by_opentelemetry and
    calling instrument() on the class instead of an instance. The property
    descriptor on the class is always truthy, causing instrumentation to
    be silently skipped.
    
    Closes #408
---
 burr/integrations/opentelemetry.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/burr/integrations/opentelemetry.py 
b/burr/integrations/opentelemetry.py
index 32dc4dd7..7a6970e8 100644
--- a/burr/integrations/opentelemetry.py
+++ b/burr/integrations/opentelemetry.py
@@ -665,7 +665,8 @@ def _init_instrument(
 
     try:
         instrumentation_module = 
importlib.import_module(instrumentation_module_name)
-        instrumentor = getattr(instrumentation_module, instrumentor_name)
+        instrumentor_cls = getattr(instrumentation_module, instrumentor_name)
+        instrumentor = instrumentor_cls()
         if instrumentor.is_instrumented_by_opentelemetry:
             logger.debug(f"`{module_name}` is already instrumented.")
         else:

Reply via email to