Skip to content

Random content decoding failure #347

@Verequies

Description

@Verequies

Prerequisites

  • I have written a descriptive issue title
  • I have searched existing issues to ensure the bug has not already been reported

Fastify version

5.2.1

Plugin version

8.0.2

Node.js version

20

Operating system

Windows

Operating system version (i.e. 20.04, 11.3, 10)

Server running on Linux, clients connecting from Chrome on Windows 11

Description

Over the past year I have been seeing a random bug with Fastify compress, where after some amount of requests (entirely random) I eventually get a (failed)net::ERR_CONTENT_DECODING_FAILED. I am not able to repeat this consistently, but many of my users receive this issue quite alot, even within 5 minutes of using the software.

Is there any part of Fastify compress that could be causing this bug? It does not happen when I disable compression.
Fastify and fastify-compress are updated to the latest versions. Requests that fail usually appear to be around 50 Bytes according to Chromes network monitor.

Link to code that reproduces the bug

Not able to consistently reproduce as it is random after some amount of requests.

Expected Behavior

All requests go through successfully and (failed)net::ERR_CONTENT_DECODING_FAILED does not occur.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions