Skip to content

Commit

Permalink
Mark 'already encoding' as warning (#2234)
Browse files Browse the repository at this point in the history
  • Loading branch information
Brainicism authored Oct 7, 2024
1 parent c35687f commit 81778ba
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions src/structures/session.ts
Original file line number Diff line number Diff line change
Expand Up @@ -951,11 +951,20 @@ export default abstract class Session {
return;
}

logger.error(
`${getDebugLogHeader(
messageContext,
)} | Unknown error with stream dispatcher. song = ${this.getDebugSongDetails(round)}. err = ${err}`,
);
if ((err as Error).message.includes("Already encoding")) {
logger.warn(
`${getDebugLogHeader(
messageContext,
)} | Already encoding. song = ${this.getDebugSongDetails(round)}. err = ${err}`,
);
} else {
logger.error(
`${getDebugLogHeader(
messageContext,
)} | Unknown error with stream dispatcher. song = ${this.getDebugSongDetails(round)}. err = ${err}`,
);
}

await this.errorRestartRound();
});

Expand Down

0 comments on commit 81778ba

Please sign in to comment.