diff --git a/src/instana/__init__.py b/src/instana/__init__.py index 24f96b56f..e6ae417b0 100644 --- a/src/instana/__init__.py +++ b/src/instana/__init__.py @@ -20,6 +20,7 @@ import importlib from .version import VERSION +from instana.collector.helpers.runtime import is_autowrapt_instrumented, is_webhook_instrumented __author__ = 'Instana Inc.' __copyright__ = 'Copyright 2020 Instana Inc.' @@ -186,7 +187,7 @@ def boot_agent(): else: # Automatic gevent monkey patching # unless auto instrumentation is off, then the customer should do manual gevent monkey patching - if ("instana" in os.environ.get("AUTOWRAPT_BOOTSTRAP", "") and + if ((is_autowrapt_instrumented() or is_webhook_instrumented()) and "INSTANA_DISABLE_AUTO_INSTR" not in os.environ and importlib.util.find_spec("gevent")): apply_gevent_monkey_patch() diff --git a/src/instana/version.py b/src/instana/version.py index 493d688f6..83bfbd1c2 100644 --- a/src/instana/version.py +++ b/src/instana/version.py @@ -3,4 +3,4 @@ # Module version file. Used by setup.py and snapshot reporting. -VERSION = "2.5.0" +VERSION = "2.5.1"