cloudflare / cloudflare/workerd

Bug report — Rewriting a WebSocket response throws exception due to unsupported status code 101.

Open
#3,047 17 comments 0 reactions 0 assignees View on GitHub
feature request
Dominant language
C++
Stars
8.7k
Forks
739
Avg merge
2d 20h
Merged PRs (30d)
174

Description

If I try to instantiate a response based on another response, with status code 101, returned by a `DurableObject`, I get this error:
Responses may only be constructed with status codes in the range 200 to 599, inclusive.

This is causing an issue in next-on-pages as reported [here](https://github.com/cloudflare/next-on-pages/issues/894#issuecomment-2453047716)

I don't know if it should be addressed here, or next-on-pages should put an exception for this case to directly return the response coming from the `DurableObject` and return it without re-instantiation.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.