Commit d081ab2
fix(logs): relax fileSchema so execution logs with files render again (#4495)
* fix(logs): relax fileSchema so execution logs with files render again
* improvement(logs): align fileSchema with shared UserFile type
- contracts/logs.ts: replace local fileSchema with mediaUserFileSchema (the established UserFile boundary schema with .passthrough())
- file-download.tsx: drop local FileData interface, use UserFile from @/executor/types
* improvement(contracts): promote userFileSchema to primitives
Move the canonical UserFile boundary schema out of tools/media/shared.ts
(where it didn't belong — logs aren't media tools) into primitives.ts as
userFileSchema. Update logs, stt, and video contracts to import from the
shared primitive.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>1 parent 98f8e85 commit d081ab2
6 files changed
Lines changed: 34 additions & 48 deletions
File tree
- apps/sim
- app/workspace/[workspaceId]/logs/components/log-details/components/file-download
- lib/api/contracts
- tools/media
Lines changed: 6 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
8 | 9 | | |
| 10 | + | |
9 | 11 | | |
10 | 12 | | |
11 | 13 | | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | 14 | | |
26 | | - | |
| 15 | + | |
27 | 16 | | |
28 | 17 | | |
29 | 18 | | |
30 | 19 | | |
31 | 20 | | |
32 | | - | |
| 21 | + | |
33 | 22 | | |
34 | 23 | | |
35 | 24 | | |
| |||
157 | 146 | | |
158 | 147 | | |
159 | 148 | | |
160 | | - | |
| 149 | + | |
161 | 150 | | |
162 | 151 | | |
163 | 152 | | |
| |||
220 | 209 | | |
221 | 210 | | |
222 | 211 | | |
223 | | - | |
| 212 | + | |
224 | 213 | | |
225 | 214 | | |
226 | 215 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
2 | 3 | | |
3 | 4 | | |
4 | 5 | | |
| |||
66 | 67 | | |
67 | 68 | | |
68 | 69 | | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | 70 | | |
83 | 71 | | |
84 | 72 | | |
| |||
237 | 225 | | |
238 | 226 | | |
239 | 227 | | |
240 | | - | |
| 228 | + | |
241 | 229 | | |
242 | 230 | | |
243 | 231 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
62 | 82 | | |
63 | 83 | | |
64 | 84 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | 6 | | |
20 | 7 | | |
21 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
8 | | - | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
22 | | - | |
| 23 | + | |
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
| |||
0 commit comments