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

Tiny logging clarity improvement #2985

Merged
merged 1 commit into from
Oct 29, 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 backend/danswer/utils/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,11 @@ def process(
) -> tuple[str, MutableMapping[str, Any]]:
# If this is an indexing job, add the attempt ID to the log message
# This helps filter the logs for this specific indexing
attempt_id = IndexAttemptSingleton.get_index_attempt_id()
index_attempt_id = IndexAttemptSingleton.get_index_attempt_id()
cc_pair_id = IndexAttemptSingleton.get_connector_credential_pair_id()

if attempt_id is not None:
msg = f"[Attempt: {attempt_id}] {msg}"
if index_attempt_id is not None:
msg = f"[Index Attempt: {index_attempt_id}] {msg}"

if cc_pair_id is not None:
msg = f"[CC Pair: {cc_pair_id}] {msg}"
Expand Down
Loading