Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Tracker] update error tracker log #2715

Merged
merged 1 commit into from
Aug 22, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions octobot/community/errors_upload/sentry_tracker.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ def init_sentry_tracker():
"""
Will upload errors to octobot.constants.ERROR_TRACKER_DSN if its value is set
"""
logger = octobot_commons.logging.get_logger(__name__)
logger = octobot_commons.logging.get_logger("sentry_tracker")
if not octobot.constants.ERROR_TRACKER_DSN:
logger.debug(f"Skipping error tracker: error tracker dsn is '{octobot.constants.ERROR_TRACKER_DSN}'")
logger.debug(f"Error tracker disabled")
return
environment = "cloud" if octobot.constants.IS_CLOUD_ENV else "self hosted"
app_name = f"{octobot.constants.PROJECT_NAME} open source"
Expand Down Expand Up @@ -72,7 +72,7 @@ def init_sentry_tracker():
def flush_tracker():
if octobot.constants.ERROR_TRACKER_DSN:
delay = 2
octobot_commons.logging.get_logger(__name__).info(f"Flushing trackers: shutting down in {delay} seconds ...")
octobot_commons.logging.get_logger("sentry_tracker").info(f"Flushing trackers: shutting down in {delay} seconds ...")
sentry_sdk.flush()
# let trackers upload errors
time.sleep(delay)
Expand Down
Loading