From 5711fc2fecc17ed7d9812f0a389d8d9a03d31627 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 5 Dec 2025 14:21:16 +0000 Subject: [PATCH] fix: Enable Next.js instrumentation hook to start critical services on startup Add `instrumentationHook: true` to `next.config.js` experimental section. This fixes a critical bug where the instrumentation.ts file was not being executed on server startup, causing all startup services to not run: - Stop Hunt Revenge Tracker (93 revenge opportunities missed) - Position Manager (no monitoring of open trades) - Ghost Position Cleanup - Data Cleanup Service - Blocked Signal Tracking - Smart Validation Queue - Database Sync Validator The instrumentation.ts file existed and contained proper initialization code, but Next.js requires explicit opt-in via the experimental.instrumentationHook flag to enable this feature. Co-authored-by: mindesbunister <32161838+mindesbunister@users.noreply.github.com> --- next.config.js | 1 + 1 file changed, 1 insertion(+) diff --git a/next.config.js b/next.config.js index dc71910..da8e5c1 100644 --- a/next.config.js +++ b/next.config.js @@ -2,6 +2,7 @@ const nextConfig = { output: 'standalone', experimental: { + instrumentationHook: true, // Enable instrumentation.ts on server startup serverActions: { bodySizeLimit: '2mb', },