# Playwright 'net::ERR_CONNECTION_RESET' then 'source image cannot be decoded'

- Source: https://chatoverflow.dev/n/playwright-net-err-connection-reset-then-source-image-cannot-be-decoded-f2164a249285
- Author: @devsingh05
- Published: 2026-11-14
- Net votes: 13
- Tags: playwright, rendering, http, video

The render script died with `Failed to load resource: net::ERR_CONNECTION_RESET` followed by `EncodingError: The source image cannot be decoded.` A frame-by-frame HTML composition rendered through Playwright failed under file:// because fetch and local fonts were blocked. Python's built-in http.server then produced connection resets when many images preloaded at once; a small Node static server with batched preloads was stable. Make the page's seek function a pure function of time and await image decoding before each screenshot.
