{
  "id": 12058083,
  "title": "My browser video compressor choked on a 2.2 GB AVI. Here's why",
  "url": "https://urgent.news/2026/10/05/my-browser-video-compressor-choked-on-a-2-2-gb-avi-heres-why",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-10-05T02:52:52.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/maxslashwang/my-browser-video-compressor-choked-on-a-22-gb-avi-heres-why-on8"
  },
  "original_language": "en",
  "account": "SquishyFile, a browser-based video compressor, ran into issues when attempting to process a 2.24 GB AVI file. The problem lay in a single line of code that attempted to read the entire file into memory using arrayBuffer(). This approach caused issues in Chromium, as it would fail to read files larger than 2 GiB, resulting in a \"NotReadableError.\" The writeFile() function then attempted to copy the failed file into ffmpeg's in-memory filesystem (MEMFS), which had a 32-bit address limit of 4 GB. This meant that even if the initial read succeeded, the subsequent copy operation would eventually encounter a limit. The same issue was present in other tools on the SquishyFile website. To resolve the problem, the author implemented a WORKERFS mount using Emscripten's filesystem library, which reads file slices on demand instead of loading the entire file into memory. This allowed the encoder to access the file without hitting memory limits. The new implementation involved creating a new File object with the same data and mounting it in a separate directory using WORKERFS. The encoder then processed the mounted file, and the original file could be released afterwards. Although the output was still stored in MEMFS due to the nature of ffmpeg.wasm, this change prevented the crashes and allowed the compressor to process larger files successfully.",
  "summary": "I run SquishyFile, a video compressor that works entirely in the browser. Most files go through WebCodecs with Mediabunny. Files the browser can't decode natively, like AVI, MPG, MTS and FLV, fall back to ffmpeg.wasm. The same fallback kicks in when a browser has no working H.264 encoder. Last week a user sent me a bug report. A 2.24 GB .avi failed in Chromium with my generic \"Something went…",
  "key_points": [
    "SquishyFile choked on 2.2 GB AVI due to memory limit in Chromium",
    "readFile() failed to read large files >2 GiB, causing NotReadableError",
    "WORKERFS solution reads file slices on demand, bypassing memory limits"
  ],
  "editors_take": "The fix for SquishyFile's video compression issue reveals a broader limitation in browser-based tools that rely on in-memory file processing, highlighting the need for on-demand file loading approaches.",
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}