mirror of
https://github.com/deepset-ai/haystack.git
synced 2025-09-19 21:23:37 +00:00
Disable telemetry logs per default (#2463)
This commit is contained in:
parent
7498c7c6fb
commit
cc1bb9ad73
@ -9,6 +9,7 @@ import os
|
|||||||
from typing import Any, Dict, List, Optional
|
from typing import Any, Dict, List, Optional
|
||||||
import uuid
|
import uuid
|
||||||
import logging
|
import logging
|
||||||
|
from logging import CRITICAL
|
||||||
from enum import Enum
|
from enum import Enum
|
||||||
from functools import wraps
|
from functools import wraps
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
@ -29,6 +30,10 @@ user_id: Optional[str] = None
|
|||||||
|
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
# disable posthog logging
|
||||||
|
logging.getLogger("posthog").setLevel(CRITICAL)
|
||||||
|
logging.getLogger("backoff").setLevel(CRITICAL)
|
||||||
|
|
||||||
|
|
||||||
class TelemetryFileType(Enum):
|
class TelemetryFileType(Enum):
|
||||||
LOG_FILE: str = "LOG_FILE"
|
LOG_FILE: str = "LOG_FILE"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user