diff --git a/apps/workers/crawlerWorker.ts b/apps/workers/crawlerWorker.ts index 76348821..49e9495d 100644 --- a/apps/workers/crawlerWorker.ts +++ b/apps/workers/crawlerWorker.ts @@ -172,7 +172,9 @@ export class CrawlerWorker { }, onError: async (job) => { const jobId = job?.id ?? "unknown"; - logger.error(`[Crawler][${jobId}] Crawling job failed: ${job.error}`); + logger.error( + `[Crawler][${jobId}] Crawling job failed: ${job.error}\n${job.error.stack}`, + ); const bookmarkId = job.data?.bookmarkId; if (bookmarkId) { await changeBookmarkStatus(bookmarkId, "failure"); diff --git a/apps/workers/openaiWorker.ts b/apps/workers/openaiWorker.ts index 8bd2cf4a..9b352811 100644 --- a/apps/workers/openaiWorker.ts +++ b/apps/workers/openaiWorker.ts @@ -73,7 +73,7 @@ export class OpenAiWorker { onError: async (job) => { const jobId = job?.id ?? "unknown"; logger.error( - `[inference][${jobId}] inference job failed: ${job.error}`, + `[inference][${jobId}] inference job failed: ${job.error}\n${job.error.stack}`, ); await attemptMarkTaggingStatus(job?.data, "failure"); }, diff --git a/apps/workers/searchWorker.ts b/apps/workers/searchWorker.ts index 56c2aac4..fd0514d6 100644 --- a/apps/workers/searchWorker.ts +++ b/apps/workers/searchWorker.ts @@ -25,7 +25,9 @@ export class SearchIndexingWorker { }, onError: (job) => { const jobId = job?.id ?? "unknown"; - logger.error(`[search][${jobId}] search job failed: ${job.error}`); + logger.error( + `[search][${jobId}] search job failed: ${job.error}\n${job.error.stack}`, + ); return Promise.resolve(); }, },