feat: add trace switcher

This commit is contained in:
qixinbo
2026-03-31 22:29:58 +08:00
parent 9a86dd2947
commit 03ac0408c9
188 changed files with 12 additions and 72713 deletions
+7
View File
@@ -88,6 +88,13 @@ class TraceService:
def initialize(self) -> bool:
if self._initialized:
return self._enabled
enable_tracing = os.getenv("ENABLE_TRACING", "false").lower() in ("true", "1", "t", "yes")
if not enable_tracing:
self._initialized = True
self._enabled = False
return False
self._initialized = True
cfg = self._read_config()
if not cfg["public_key"] or not cfg["secret_key"]: