Skip to content

Commit 64babc3

Browse files
fix(cli): honor errorLine return value in follow retry warning
1 parent d8cb97e commit 64babc3

1 file changed

Lines changed: 11 additions & 7 deletions

File tree

src/cli/logs-cli.ts

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -339,13 +339,17 @@ export function registerLogsCli(program: Command) {
339339
if (opts.follow && followRetryAttempt < MAX_FOLLOW_RETRIES && isTransientFollowError(err)) {
340340
followRetryAttempt += 1;
341341
const backoffMs = computeBackoff(FOLLOW_BACKOFF_POLICY, followRetryAttempt);
342-
errorLine(
343-
colorize(
344-
rich,
345-
theme.warn,
346-
`[logs] gateway disconnected, reconnecting in ${Math.round(backoffMs / 1_000)}s...`,
347-
),
348-
);
342+
if (
343+
!errorLine(
344+
colorize(
345+
rich,
346+
theme.warn,
347+
`[logs] gateway disconnected, reconnecting in ${Math.round(backoffMs / 1_000)}s...`,
348+
),
349+
)
350+
) {
351+
return;
352+
}
349353
await delay(backoffMs);
350354
continue;
351355
}

0 commit comments

Comments
 (0)