Skip to content

Commit 39f4d8f

Browse files
authored
fix nemesis test report (#20506)
1 parent f0fd91b commit 39f4d8f

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

ydb/tests/olap/load/lib/conftest.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -628,20 +628,20 @@ def _handle_final_status(self, result, workload_name, node_errors):
628628
if "coredump" not in err.lower() and "oom" not in err.lower():
629629
workload_errors.append(err)
630630

631-
# --- Прикладываем логи, если есть проблемы с нодами или ошибки workload ---
632-
if node_issues > 0 or workload_errors:
633-
# Используем универсальный подход с getattr для вызова приватного метода
634-
attach_logs = getattr(self, "__attach_logs", None)
635-
if attach_logs:
636-
try:
637-
attach_logs(
631+
# --- Переключатель: если cluster_log=all, то всегда прикладываем логи ---
632+
cluster_log_mode = get_external_param('cluster_log', 'default')
633+
attach_logs_method = getattr(type(self), "_LoadSuiteBase__attach_logs", None)
634+
if attach_logs_method:
635+
try:
636+
if cluster_log_mode == 'all' or node_issues > 0 or workload_errors:
637+
attach_logs_method(
638638
start_time=getattr(result, "start_time", None),
639639
attach_name="kikimr",
640640
query_text="",
641641
ignore_roles=True # Собираем логи со всех уникальных хостов
642642
)
643-
except Exception as e:
644-
logging.warning(f"Failed to attach kikimr logs: {e}")
643+
except Exception as e:
644+
logging.warning(f"Failed to attach kikimr logs: {e}")
645645

646646
# --- FAIL TEST IF CORES OR OOM FOUND ---
647647
if node_issues > 0:

0 commit comments

Comments
 (0)