Skip to content

Commit e2631d5

Browse files
committed
fix(core): Don't call "logs" twice in wait_for_logs
1 parent 08bf23f commit e2631d5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

core/testcontainers/core/waiting_utils.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,9 @@ def wait_for_logs(
110110
start = time.time()
111111
while True:
112112
duration = time.time() - start
113-
stdout = container.get_logs()[0].decode()
114-
stderr = container.get_logs()[1].decode()
113+
stdout, stderr = container.get_logs()
114+
stdout = stdout.decode()
115+
stderr = stderr.decode()
115116
predicate_result = (
116117
predicate(stdout) or predicate(stderr)
117118
if predicate_streams_and is False

0 commit comments

Comments
 (0)