Skip to content

Commit a418497

Browse files
author
waleed
committed
added parsing for local file storage during execution
1 parent cf26cf7 commit a418497

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

apps/sim/lib/uploads/utils/file-utils.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,13 @@ export function inferContextFromKey(key: string): StorageContext {
255255
return 'workspace'
256256
}
257257

258+
// Local execution files: UUID segments separated by underscores/hyphens
259+
// Pattern: {uuid}-{uuid}_{uuid}_{uuid}_{filename} (local storage format)
260+
// This handles execution files stored locally without cloud storage
261+
if (key.match(/^[a-f0-9-]{36}-[a-f0-9-]{36}_[a-f0-9-]{36}_[a-f0-9-]{36}_/)) {
262+
return 'execution'
263+
}
264+
258265
// Copilot/General files: timestamp-random-filename (no path segments)
259266
// Pattern: {timestamp}-{random}-{filename}
260267
// NOTE: This is ambiguous - prefer explicit context parameter

0 commit comments

Comments
 (0)