windmill-labs/windmill · error
Recording is too large (${total} bytes)
Error message
Recording is too large (${total} bytes) What it means
Thrown by fetchRecording while streaming once the recording's total size exceeds the download cap. App recordings can carry multi-megabyte snapshots, so the loader enforces a hard size limit instead of buffering an unbounded body into the page.
Source
Thrown at frontend/src/lib/components/recording/rawAppRecordingLoad.ts:615
// short enough to be a kind rather than a payload.
const named = typeof type === 'string' && type.length <= 32 ? ` (${type})` : ''
return {
ok: false,
error: `This recording is of an unknown kind${named} — it may need a newer Windmill.`
}
}
}
}
/** Fetch a recording from `url`, enforcing the download cap while streaming. */
export async function fetchRecording(
url: string,
onProgress?: (loaded: number, total: number) => void
): Promise<unknown> {
const res = await fetch(url)
if (!res.ok) throw new Error(`HTTP ${res.status} ${res.statusText}`)
const total = Number(res.headers.get('content-length')) || 0
if (total > MAX_RECORDING_BYTES) throw new Error(`Recording is too large (${total} bytes)`)
const reader = res.body?.getReader()
if (!reader) {
const text = await res.text()
if (text.length > MAX_RECORDING_BYTES) throw new Error('Recording exceeded the size limit')
return JSON.parse(text)
}
const chunks: Uint8Array[] = []
let loaded = 0
for (;;) {
const { done, value } = await reader.read()
if (done) break
if (!value) continue
chunks.push(value)
loaded += value.length
if (loaded > MAX_RECORDING_BYTES) {
await reader.cancel()
throw new Error('Recording exceeded the size limit')
}View on GitHub (pinned to e474e8803c)
Solutions
- Reduce the recording size (shorter capture, fewer snapshots) and re-export
- Serve the recording through a host that enforces the same limit so URLs stay valid
- Check that the URL points at the recording, not a larger artifact
Defensive patterns
Strategy: validation
Validate before calling
const head = await fetch(url, { method: 'HEAD' })
const size = Number(head.headers.get('content-length')) || 0
if (size > MAX_RECORDING_BYTES) throw new Error('Recording too large before download') Try / catch
try { rec = await fetchRecording(url) } catch (e) { if (/too large/.test(String(e))) notify('Recording exceeds the size cap'); else throw e } Prevention
- Check content-length via HEAD before fetching large files
- Keep recordings small: trim snapshots at capture time
- Serve recordings from hosts that report accurate content-length
When it happens
Trigger: fetchRecording(url) against a recording whose Content-Length header exceeds MAX_RECORDING_BYTES.
Common situations: Sharing an oversized app-recording export; a server that reports a wrong/large content-length; pointing the loader at a non-recording large JSON file.
Related errors
- Recording exceeded the size limit
- body.error || res.statusText
- HTTP ${res.status} ${res.statusText}
- Offline replay: this page renders a recording and cannot cal
- Could not fetch the run this recording is based on
AI-assisted analysis of windmill-labs/windmill@e474e8803c (2026-09-03).
Data as JSON: /api/errors/0144e655467a8bb3.
Report an issue: GitHub.