From 900443d0782f405ef16beeca0fe9d97a2fb7b7c9 Mon Sep 17 00:00:00 2001 From: Marko Djordjevic Date: Tue, 17 Feb 2026 20:01:09 +0100 Subject: [PATCH] fix: convert Unix epoch seconds to Date for span annotation start_time/end_time on insert --- src/app/api/span-annotations/route.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/app/api/span-annotations/route.ts b/src/app/api/span-annotations/route.ts index b39fee4..df0c1b3 100644 --- a/src/app/api/span-annotations/route.ts +++ b/src/app/api/span-annotations/route.ts @@ -65,8 +65,8 @@ export async function POST(request: NextRequest) { .insert(spanAnnotations) .values({ chart_id, - start_time: actualStartTime, - end_time: actualEndTime, + start_time: new Date(actualStartTime * 1000), + end_time: new Date(actualEndTime * 1000), label, confidence: confidence || null, outcome: outcome || null,