From 5de260813b3308e0f8d11b13e8d6a59470efe395 Mon Sep 17 00:00:00 2001 From: a Date: Tue, 15 Jul 2025 23:20:58 -0500 Subject: [PATCH] noot --- ts/src/activities/discord.ts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/ts/src/activities/discord.ts b/ts/src/activities/discord.ts index 675f7d8..e6705e6 100644 --- a/ts/src/activities/discord.ts +++ b/ts/src/activities/discord.ts @@ -44,34 +44,34 @@ export const reply_to_interaction = async (props: { if (error.status === 404 || error.code === 10062) { // 10062 is Discord's "Unknown interaction" error code log.warn( - { - interactionId: ref.id, + { + interactionId: ref.id, error: error.message, code: error.code, - status: error.status + status: error.status }, 'Discord interaction expired (404) - not retrying' ) - + // Throw non-retryable error to prevent Temporal from retrying throw ApplicationFailure.nonRetryable( `Discord interaction ${ref.id} has expired and cannot be responded to`, 'DiscordInteractionExpired' ) } - + // Log other errors and re-throw them (these will be retried by Temporal) log.error( - { - interactionId: ref.id, + { + interactionId: ref.id, error: error.message, stack: error.stack, code: error.code, - status: error.status + status: error.status }, 'Failed to reply to Discord interaction' ) - + throw error } }