[GH-ISSUE #4387] [bug]: accept-encoding gzip does not decode #1604

Closed
opened 2026-03-16 21:02:58 +03:00 by kerem · 13 comments
Owner

Originally created by @Marcuse7 on GitHub (Sep 30, 2024).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/4387

Originally assigned to: @AugleBoBaugles on GitHub.

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

When I send a GET request with header accept-encoding: gzip, deflate I expect the response to be decoded. What I get is undecoded (gzipped) text.

Steps to reproduce

  1. Open URL https://hoppscotch.io/
  2. Use default GET query with https://echo.hoppscotch.io
  3. Add header Accept-encoding value gzip or gzip, deflate
  4. Execute query

Environment

Production

Version

Cloud

Originally created by @Marcuse7 on GitHub (Sep 30, 2024). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/4387 Originally assigned to: @AugleBoBaugles on GitHub. ### Is there an existing issue for this? - [X] I have searched the existing issues ### Current behavior When I send a GET request with header `accept-encoding: gzip, deflate` I expect the response to be decoded. What I get is undecoded (gzipped) text. ### Steps to reproduce 1. Open URL https://hoppscotch.io/ 2. Use default `GET` query with https://echo.hoppscotch.io 3. Add header `Accept-encoding` value `gzip` or `gzip, deflate` 4. Execute query ### Environment Production ### Version Cloud
kerem 2026-03-16 21:02:58 +03:00
Author
Owner

@VANSH3104 commented on GitHub (Oct 8, 2024):

@Marcuse7 can you explain more about this

<!-- gh-comment-id:2399226479 --> @VANSH3104 commented on GitHub (Oct 8, 2024): @Marcuse7 can you explain more about this
Author
Owner

@Marcuse7 commented on GitHub (Oct 13, 2024):

Hello Vansh, thank you for reply!
I use Hoppscotch Version 24.9.1-0 (20241006.121003) on macOS 14.7.
This is the request and its reply:
Screenshot 2024-10-13 at 14 00 55
These are my settings (the error persists w/ interceptor set to Native):
Screenshot 2024-10-13 at 14 02 59

<!-- gh-comment-id:2408952026 --> @Marcuse7 commented on GitHub (Oct 13, 2024): Hello Vansh, thank you for reply! I use Hoppscotch Version 24.9.1-0 (20241006.121003) on macOS 14.7. This is the request and its reply: ![Screenshot 2024-10-13 at 14 00 55](https://github.com/user-attachments/assets/fdfd3471-9818-4742-8b8d-36d0127f767c) These are my settings (the error persists w/ interceptor set to Native): ![Screenshot 2024-10-13 at 14 02 59](https://github.com/user-attachments/assets/8e509dcc-21ba-42e5-9ce5-3dfd94eece47)
Author
Owner

@unacro commented on GitHub (Oct 14, 2024):

Same situation.

While response body is zipped, show RAW content as garble
(header content-encoding marked as gzip)

<!-- gh-comment-id:2410842512 --> @unacro commented on GitHub (Oct 14, 2024): Same situation. While response body is zipped, show RAW content as garble (header `content-encoding` marked as `gzip`)
Author
Owner

@AugleBoBaugles commented on GitHub (Nov 14, 2024):

I'm working on this

<!-- gh-comment-id:2475467923 --> @AugleBoBaugles commented on GitHub (Nov 14, 2024): I'm working on this
Author
Owner

@SanskritiHarmukh commented on GitHub (Nov 19, 2024):

Hey @AugleBoBaugles , just wanted to check if you're participating in the CodeDay micro-internship program, as issues labeled with CodeDay are reserved for that partnership. Let me know!

<!-- gh-comment-id:2486155698 --> @SanskritiHarmukh commented on GitHub (Nov 19, 2024): Hey @AugleBoBaugles , just wanted to check if you're participating in the CodeDay micro-internship program, as issues labeled with `CodeDay` are reserved for that partnership. Let me know!
Author
Owner

@AugleBoBaugles commented on GitHub (Nov 19, 2024):

@SanskritiHarmukh Yes, this is the issue assigned to my group for the CodeDay micro-internship.

<!-- gh-comment-id:2486682952 --> @AugleBoBaugles commented on GitHub (Nov 19, 2024): @SanskritiHarmukh Yes, this is the issue assigned to my group for the CodeDay micro-internship.
Author
Owner

@AugleBoBaugles commented on GitHub (Dec 3, 2024):

@SanskritiHarmukh My team has hit a wall with this issue. We’ve successfully set up our build environments, however we haven’t been able to recreate the issue locally. We have been able to recreate it using the current version of Hoppscotch at https://hoppscotch.io/ though.

We’ve seen that there was an update to the Hoppscotch version recently and the issue still exists there. Our theory is that there is a commit to the repository that has not been used in the public version of Hoppscotch yet.

Where should we go from here to resolve this issue?

<!-- gh-comment-id:2515721841 --> @AugleBoBaugles commented on GitHub (Dec 3, 2024): @SanskritiHarmukh My team has hit a wall with this issue. We’ve successfully set up our build environments, however we haven’t been able to recreate the issue locally. We have been able to recreate it using the current version of Hoppscotch at https://hoppscotch.io/ though. We’ve seen that there was an update to the Hoppscotch version recently and the issue still exists there. Our theory is that there is a commit to the repository that has not been used in the public version of Hoppscotch yet. Where should we go from here to resolve this issue?
Author
Owner

@SanskritiHarmukh commented on GitHub (Dec 4, 2024):

@SanskritiHarmukh My team has hit a wall with this issue. We’ve successfully set up our build environments, however we haven’t been able to recreate the issue locally. We have been able to recreate it using the current version of Hoppscotch at https://hoppscotch.io/ though.

We’ve seen that there was an update to the Hoppscotch version recently and the issue still exists there. Our theory is that there is a commit to the repository that has not been used in the public version of Hoppscotch yet.

Where should we go from here to resolve this issue?

We'll get back to you on this.

<!-- gh-comment-id:2517499785 --> @SanskritiHarmukh commented on GitHub (Dec 4, 2024): > @SanskritiHarmukh My team has hit a wall with this issue. We’ve successfully set up our build environments, however we haven’t been able to recreate the issue locally. We have been able to recreate it using the current version of Hoppscotch at https://hoppscotch.io/ though. > > We’ve seen that there was an update to the Hoppscotch version recently and the issue still exists there. Our theory is that there is a commit to the repository that has not been used in the public version of Hoppscotch yet. > > Where should we go from here to resolve this issue? We'll get back to you on this.
Author
Owner

@SanskritiHarmukh commented on GitHub (Dec 4, 2024):

Could you try setting up the Hoppscotch Agent as an interceptor and see if you can reproduce the issue on your end?

<!-- gh-comment-id:2517654880 --> @SanskritiHarmukh commented on GitHub (Dec 4, 2024): Could you try setting up the Hoppscotch Agent as an interceptor and see if you can reproduce the issue on your end?
Author
Owner

@SanskritiHarmukh commented on GitHub (Dec 4, 2024):

Hi there,
I interacted with the team and we were able to figure out a few things. The issue seems to be related to the combination of the web app and the Agent. Specifically, when both are used together, the response is not being deflated properly. However, if you use just the web app, the response deflates automatically because the browser (via Axios) handles it. Similarly, if you're using the desktop app, the native interceptors are not deflating the response, which is where the issue also occurs.

The hoppscotch-relay library, which manages networking for both the desktop app and the Agent, is central to understanding this issue. Exploring how it interacts with the Agent could help address the problem.

If you're comfortable with Rust, there could be a potential solution involving libcurl to handle the deflation for us. If you’re interested in exploring this, you can dive into the rust-curl implementation and see how it can work with the current setup.

If Rust isn't your area, there's still an open issue for CodeDay that hasn't been addressed yet: Hoppscotch Extension Issue #303. You can either look into that or explore other potential open issues. Let me know if you'd like to take one up.

<!-- gh-comment-id:2518050706 --> @SanskritiHarmukh commented on GitHub (Dec 4, 2024): Hi there, I interacted with the team and we were able to figure out a few things. The issue seems to be related to the combination of the web app and the Agent. Specifically, when both are used together, the response is not being deflated properly. However, if you use just the web app, the response deflates automatically because the browser (via Axios) handles it. Similarly, if you're using the desktop app, the native interceptors are not deflating the response, which is where the issue also occurs. The `hoppscotch-relay` library, which manages networking for both the desktop app and the Agent, is central to understanding this issue. Exploring how it interacts with the Agent could help address the problem. If you're comfortable with Rust, there could be a potential solution involving libcurl to handle the deflation for us. If you’re interested in exploring this, you can dive into the rust-curl implementation and see how it can work with the current setup. If Rust isn't your area, there's still an open issue for CodeDay that hasn't been addressed yet: [Hoppscotch Extension Issue #303](https://github.com/hoppscotch/hoppscotch-extension/issues/303). You can either look into that or explore other potential open issues. Let me know if you'd like to take one up.
Author
Owner

@hissssst commented on GitHub (Feb 13, 2025):

I experience this issue on hoppscotch electron desktop app

<!-- gh-comment-id:2657297186 --> @hissssst commented on GitHub (Feb 13, 2025): I experience this issue on hoppscotch electron desktop app
Author
Owner

@xTudoS commented on GitHub (Feb 27, 2025):

Hi there, I interacted with the team and we were able to figure out a few things. The issue seems to be related to the combination of the web app and the Agent. Specifically, when both are used together, the response is not being deflated properly. However, if you use just the web app, the response deflates automatically because the browser (via Axios) handles it. Similarly, if you're using the desktop app, the native interceptors are not deflating the response, which is where the issue also occurs.

The hoppscotch-relay library, which manages networking for both the desktop app and the Agent, is central to understanding this issue. Exploring how it interacts with the Agent could help address the problem.

If you're comfortable with Rust, there could be a potential solution involving libcurl to handle the deflation for us. If you’re interested in exploring this, you can dive into the rust-curl implementation and see how it can work with the current setup.

If Rust isn't your area, there's still an open issue for CodeDay that hasn't been addressed yet: Hoppscotch Extension Issue #303. You can either look into that or explore other potential open issues. Let me know if you'd like to take one up.

I find out where

adding curl_handle.accept_encoding("gzip"); to run_request_task solved

I will open a PR for it

Image
<!-- gh-comment-id:2687194782 --> @xTudoS commented on GitHub (Feb 27, 2025): > Hi there, I interacted with the team and we were able to figure out a few things. The issue seems to be related to the combination of the web app and the Agent. Specifically, when both are used together, the response is not being deflated properly. However, if you use just the web app, the response deflates automatically because the browser (via Axios) handles it. Similarly, if you're using the desktop app, the native interceptors are not deflating the response, which is where the issue also occurs. > > The `hoppscotch-relay` library, which manages networking for both the desktop app and the Agent, is central to understanding this issue. Exploring how it interacts with the Agent could help address the problem. > > If you're comfortable with Rust, there could be a potential solution involving libcurl to handle the deflation for us. If you’re interested in exploring this, you can dive into the rust-curl implementation and see how it can work with the current setup. > > If Rust isn't your area, there's still an open issue for CodeDay that hasn't been addressed yet: [Hoppscotch Extension Issue #303](https://github.com/hoppscotch/hoppscotch-extension/issues/303). You can either look into that or explore other potential open issues. Let me know if you'd like to take one up. I find out where adding curl_handle.accept_encoding("gzip"); to run_request_task solved I will open a PR for it <img width="800" alt="Image" src="https://github.com/user-attachments/assets/a18b8c9d-0c88-47bb-8278-3039efab8ac5" />
Author
Owner

@liyasthomas commented on GitHub (Mar 4, 2025):

Thanks for your patience and valuable feedback. We’ve fixed this bug in the latest release.
Download the latest builds and provide your valuable feedback.

Closing this ticket as this bug is now fixed in the recent version. Please feel free to reach out if you have any other concerns.

<!-- gh-comment-id:2696973382 --> @liyasthomas commented on GitHub (Mar 4, 2025): Thanks for your patience and valuable feedback. We’ve fixed this bug in the latest release. [Download the latest builds](https://hoppscotch.com/download) and provide your valuable feedback. Closing this ticket as this bug is now fixed in the recent version. Please feel free to reach out if you have any other concerns.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#1604
No description provided.