Skip to content

Conversation

asomethings
Copy link
Contributor

Description

tauri-apps/plugin-http handles response as stream which causes error Response with null body status cannot have body in Javascript.

Fix

When status is 204 then it uses null instead of readableStreamBody.

fixes: #2580

@asomethings asomethings requested a review from a team as a code owner April 16, 2025 09:27
Copy link
Contributor

github-actions bot commented Apr 16, 2025

Package Changes Through 625fd3d

There are 2 changes which include http with patch, http-js with patch

Planned Package Versions

The following package releases are the planned based on the context of changes in this pull request.

package current next
api-example 2.0.25 2.0.26
api-example-js 2.0.21 2.0.22
http 2.4.3 2.4.4
http-js 2.4.3 2.4.4

Add another change file through the GitHub UI by following this link.


Read about change files or the docs at github.com/jbolda/covector

Copy link
Member

@lucasfernog lucasfernog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you!

@lucasfernog lucasfernog merged commit ff384cb into tauri-apps:v2 Apr 18, 2025
11 checks passed
@FabianLars
Copy link
Member

we probably should do the same for 205 and 304. They will throw the same error (at least in firefox)

amrbashir added a commit that referenced this pull request Apr 19, 2025
amrbashir added a commit that referenced this pull request Apr 19, 2025
tauri-bot pushed a commit to tauri-apps/tauri-plugin-http that referenced this pull request Apr 19, 2025
gezihuzi pushed a commit to Hypobenthos/plugins-workspace that referenced this pull request Jun 22, 2025
…auri-apps#2636)

* fix(http): handle status code 204 to use javascript null

* add change file

---------

Co-authored-by: Lucas Nogueira <[email protected]>
gezihuzi pushed a commit to Hypobenthos/plugins-workspace that referenced this pull request Jun 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[bug] tauri-apps/plugin-http incorrectly handles responses for status code 204
3 participants