[GH-ISSUE #5155] [feature]: add high-precision number support for desktop app #1962

Closed
opened 2026-03-16 22:38:26 +03:00 by kerem · 11 comments
Owner

Originally created by @auzundere on GitHub (Jun 16, 2025).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/5155

Originally assigned to: @CuriousCorrelation on GitHub.

Is there an existing issue for this?

  • I have searched existing issues and this bug hasn't been reported yet

Current behavior

When I pass a data like in the request body "dsid": 990000000262240065
Then it converts to the dsid value to "dsid": 990000000262240100

I cannot wrap with double quote because my server/API cannot allow different data type, it should stay the same data type as numerical.

Steps to reproduce

  1. Paste the payload
  2. Send the request
  3. Wrong response became because of the request payload has different dsid

Logs and Screenshots


Environment

Production

Hoppscotch Version

Cloud (Desktop App for Mac OS)

Interceptor

Not Applicable - Issue not related to network requests

Browsers Affected

No response

Operating System

None

Additional Information

No response

Originally created by @auzundere on GitHub (Jun 16, 2025). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/5155 Originally assigned to: @CuriousCorrelation on GitHub. ### Is there an existing issue for this? - [x] I have searched existing issues and this bug hasn't been reported yet ### Current behavior When I pass a data like in the request body `"dsid": 990000000262240065` Then it converts to the dsid value to `"dsid": 990000000262240100` I cannot wrap with double quote because my server/API cannot allow different data type, it should stay the same data type as numerical. ### Steps to reproduce 1. Paste the payload 2. Send the request 3. Wrong response became because of the request payload has different dsid ### Logs and Screenshots ```shell ``` ### Environment Production ### Hoppscotch Version Cloud (Desktop App for Mac OS) ### Interceptor Not Applicable - Issue not related to network requests ### Browsers Affected _No response_ ### Operating System None ### Additional Information _No response_
kerem 2026-03-16 22:38:26 +03:00
  • closed this issue
  • added the
    feature
    label
Author
Owner

@CuriousCorrelation commented on GitHub (Jun 19, 2025):

Hi @auzundere, this isn't actually a bug in the traditional sense, it's a JavaScript limitation where numbers larger than MAX_SAFE_INTEGER (2^53 - 1) lose precision.

The number 990000000262240065 you mentioned exceeds this limit, so standard parsing tends to lose precision there.

And although this isn't quite possible on the web app without usage of string at some point, this certainly is an interesting feature request for the desktop app which can bypass such restrictions, and something I'll definitely consider, a PoC draft is already up for this but there are some edge cases to be considered.

For now I'm changing the ticket to be a feature request with title "[features]: add high-precision number support for desktop app" instead so it'll encompass the constraints and help us track this better.

Thanks for suggesting this! 🎯

<!-- gh-comment-id:2987118784 --> @CuriousCorrelation commented on GitHub (Jun 19, 2025): Hi @auzundere, this isn't actually a bug in the traditional sense, it's a JavaScript limitation where numbers larger than [MAX_SAFE_INTEGER](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/MAX_SAFE_INTEGER) (2^53 - 1) lose precision. The number `990000000262240065` you mentioned exceeds this limit, so standard parsing tends to lose precision there. And although this isn't quite possible on the web app without usage of string at some point, this certainly is an interesting feature request for the desktop app which can bypass such restrictions, and something I'll definitely consider, a PoC draft is already up for this but there are some edge cases to be considered. For now I'm changing the ticket to be a feature request with title "[features]: add high-precision number support for desktop app" instead so it'll encompass the constraints and help us track this better. Thanks for suggesting this! 🎯
Author
Owner

@auzundere commented on GitHub (Jun 25, 2025):

@CuriousCorrelation any ETA to complete this feature request?

<!-- gh-comment-id:3004583270 --> @auzundere commented on GitHub (Jun 25, 2025): @CuriousCorrelation any ETA to complete this feature request?
Author
Owner

@CuriousCorrelation commented on GitHub (Jun 25, 2025):

Unsure at the moment, but planning to tackle this very soon.

Progress right now is that this feature requires some changes to the relay component, which is a major part of the core networking machinery that powers the entire request-response flow.

Any modifications to the underlying networking stack need to go through a lot of consideration and review channels, which is why this might need extra care with the impl.

I'll keep you updated as we make progress. Appreciate your patience.

<!-- gh-comment-id:3004696864 --> @CuriousCorrelation commented on GitHub (Jun 25, 2025): Unsure at the moment, but planning to tackle this very soon. Progress right now is that this feature requires some changes to the `relay` component, which is a major part of the core networking machinery that powers the entire request-response flow. Any modifications to the underlying networking stack need to go through a lot of consideration and review channels, which is why this might need extra care with the impl. I'll keep you updated as we make progress. Appreciate your patience.
Author
Owner

@auzundere commented on GitHub (Jun 30, 2025):

@CuriousCorrelation thank you.

<!-- gh-comment-id:3019408847 --> @auzundere commented on GitHub (Jun 30, 2025): @CuriousCorrelation thank you.
Author
Owner

@auzundere commented on GitHub (Jul 9, 2025):

@CuriousCorrelation Any updates so far? My application consistently uses DSIDs greater than 2^53 - 1, and as a result, I’m currently blocked from sending requests through the Desktop Application.

<!-- gh-comment-id:3053689807 --> @auzundere commented on GitHub (Jul 9, 2025): @CuriousCorrelation Any updates so far? My application consistently uses DSIDs greater than 2^53 - 1, and as a result, I’m currently blocked from sending requests through the Desktop Application.
Author
Owner

@CuriousCorrelation commented on GitHub (Jul 10, 2025):

Hi @auzundere, just wanted to check if you are you still experiencing this precision loss issue on the latest desktop app build?

We actually implemented a fix for a separate sub-system that was partially also a workaround for this issue. It essentially changes how json content is processed to treat it as text rather than parsing them through js' number system.

Could you please confirm you're running the latest version of the desktop app and test with one of your problematic DSID values to see if the precision is now preserved?

This will help me determine if there are any edge cases the current workaround doesn't cover, or if we need to investigate further. A more complete high-precision number support at the relay level is still in development, but that workaround should unblock you for now.

<!-- gh-comment-id:3055805156 --> @CuriousCorrelation commented on GitHub (Jul 10, 2025): Hi @auzundere, just wanted to check if you are you still experiencing this precision loss issue on the latest desktop app build? We actually implemented a fix for a separate sub-system that was partially also a workaround for this issue. It essentially changes how json content is processed to treat it as text rather than parsing them through js' number system. Could you please confirm you're running the latest version of the desktop app and test with one of your problematic DSID values to see if the precision is now preserved? This will help me determine if there are any edge cases the current workaround doesn't cover, or if we need to investigate further. A more complete high-precision number support at the relay level is still in development, but that workaround should unblock you for now.
Author
Owner

@auzundere commented on GitHub (Jul 14, 2025):

@CuriousCorrelation I just tested this on version 25.6.0 and I’m still seeing the same issue. It’s not limited to POST requests—I’m also seeing GET requests return altered dsid values.

For example, the expected dsid stored in the DB looks like this:

"modifiedBy": {
  "dsid": 990000000262257282,
  "email": "uatsuperuser_automation_p@xyz.com",
  "firstName": "UATSuperUser",
  "lastName": "Automation",
  "type": "INTERNAL",
  "phoneNumber": "0",
  "chat": null,
  "systemAccountFlag": true
}

However, when making a GET request using the Hoppscotch Desktop app on Mac, I receive:

"modifiedBy": {
  "dsid": 990000000262257300,
  "email": "uatsuperuser_automation_p@xyz.com",
  "firstName": "UATSuperUser",
  "lastName": "Automation",
  "type": "INTERNAL",
  "phoneNumber": "0",
  "chat": null,
  "systemAccountFlag": true
}

But when I test the same request using Postman, I receive the correct dsid:

"modifiedBy": {
  "dsid": 990000000262257282,
  "email": "uatsuperuser_automation_p@xyz.com",
  "firstName": "UATSuperUser",
  "lastName": "Automation",
  "type": "INTERNAL",
  "phoneNumber": "0",
  "chat": null,
  "systemAccountFlag": true
}

So it seems the issue persists, and it’s not the correct behavior.

<!-- gh-comment-id:3070250411 --> @auzundere commented on GitHub (Jul 14, 2025): @CuriousCorrelation I just tested this on version 25.6.0 and I’m still seeing the same issue. It’s not limited to POST requests—I’m also seeing GET requests return altered dsid values. For example, the expected dsid stored in the DB looks like this: ``` "modifiedBy": { "dsid": 990000000262257282, "email": "uatsuperuser_automation_p@xyz.com", "firstName": "UATSuperUser", "lastName": "Automation", "type": "INTERNAL", "phoneNumber": "0", "chat": null, "systemAccountFlag": true } ``` However, when making a GET request using the Hoppscotch Desktop app on Mac, I receive: ``` "modifiedBy": { "dsid": 990000000262257300, "email": "uatsuperuser_automation_p@xyz.com", "firstName": "UATSuperUser", "lastName": "Automation", "type": "INTERNAL", "phoneNumber": "0", "chat": null, "systemAccountFlag": true } ``` But when I test the same request using Postman, I receive the correct dsid: ``` "modifiedBy": { "dsid": 990000000262257282, "email": "uatsuperuser_automation_p@xyz.com", "firstName": "UATSuperUser", "lastName": "Automation", "type": "INTERNAL", "phoneNumber": "0", "chat": null, "systemAccountFlag": true } ``` So it seems the issue persists, and it’s not the correct behavior.
Author
Owner

@CuriousCorrelation commented on GitHub (Jul 15, 2025):

Hi @auzundere, thanks for testing on the latest version, also I appreciate the details.

I've been trying to reproduce this with the exact DSID values you mentioned (990000000262257282) using version 25.6.0 on the same Cloud Desktop App for Mac OS setup. The strange thing is that in my tests, the DSID values are coming through correctly without any precision loss:

Local GET Local POST Remote POST
Image Image Image

Notice I'm seeing 990000000262257282 in both requests and responses when testing against remote (httpbin's echo response) APIs and local servers (nc -l 8080 which simply displays what it got).

Perhaps I am missing some context regarding the exact config or the request you are making. Also wondering if this happens every single time or just sometimes. A screenshot showing the precision loss like above would be really helpful to understand all the surrounding context!

Thanks again for your patience

<!-- gh-comment-id:3072482228 --> @CuriousCorrelation commented on GitHub (Jul 15, 2025): Hi @auzundere, thanks for testing on the latest version, also I appreciate the details. I've been trying to reproduce this with the exact DSID values you mentioned (`990000000262257282`) using version 25.6.0 on the same Cloud Desktop App for Mac OS setup. The strange thing is that in my tests, the DSID values are coming through correctly without any precision loss: | Local GET | Local POST | Remote POST | | --- | --- | --- | | <img width="1774" height="693" alt="Image" src="https://github.com/user-attachments/assets/1692a07c-da60-4715-b1d1-9a506f7c7f91" /> | <img width="1774" height="693" alt="Image" src="https://github.com/user-attachments/assets/e2f1bd30-8d53-440a-8975-67fe9205a58f" /> | <img width="1372" height="1061" alt="Image" src="https://github.com/user-attachments/assets/37b343e0-ed50-4a71-8a09-0fa35c9d6efc" /> | Notice I'm seeing `990000000262257282` in both requests and responses when testing against remote (`httpbin`'s echo response) APIs and local servers (`nc -l 8080` which simply displays what it got). Perhaps I am missing some context regarding the exact config or the request you are making. Also wondering if this happens every single time or just sometimes. A screenshot showing the precision loss like above would be really helpful to understand all the surrounding context! Thanks again for your patience
Author
Owner

@auzundere commented on GitHub (Jul 15, 2025):

@CuriousCorrelation After today’s patch update, I’m now receiving the correct response and the payload is also sent correctly. Thank you so much for the help!

I have a quick question — I’m trying to self-host the Desktop Application on my Mac. Could you please provide detailed steps to achieve this? I tried following the documentation, but ran into several issues while running pnpm commands.

I believe I could run it locally using Docker, but I’m facing problems building the Docker image. Any guidance on how to set this up would be greatly appreciated.

<!-- gh-comment-id:3075107062 --> @auzundere commented on GitHub (Jul 15, 2025): @CuriousCorrelation After today’s patch update, I’m now receiving the correct response and the payload is also sent correctly. Thank you so much for the help! I have a quick question — I’m trying to self-host the Desktop Application on my Mac. Could you please provide detailed steps to achieve this? I tried following the documentation, but ran into several issues while running pnpm commands. I believe I could run it locally using Docker, but I’m facing problems building the Docker image. Any guidance on how to set this up would be greatly appreciated.
Author
Owner

@CuriousCorrelation commented on GitHub (Jul 16, 2025):

That's fantastic to hear @auzundere 🎉 glad I could help!

Just to clarify, when you mention wanting to "self-host the Desktop Application," I'm assuming you mean building the desktop app locally from source?

The term "self-host" in the Hoppscotch context typically refers to using our Docker image to host the Hoppscotch platform locally, and any desktop app distribution (whether our official release or locally built) can connect to that self-hosted instance via the instance switcher in the top-left corner.

You can find detailed instructions for setting up and connecting to self-hosted instances in the Desktop App README and also the Hoppscotch SH Edition section of the official docs.

For troubleshooting those pnpm errors, Docker image building issues, and general setup help with connecting to self-hosted instances, I'd recommend checking the Discussions tab; there are some existing threads that might help, but if they don't cover your specific issue, feel free to start a new discussion with the exact error messages you're seeing.

I'll be happy to help there.

Since the original precision issue has been resolved, I'll go ahead and close this issue. Thanks for your patience throughout! 🚀

<!-- gh-comment-id:3076743270 --> @CuriousCorrelation commented on GitHub (Jul 16, 2025): That's fantastic to hear @auzundere 🎉 glad I could help! Just to clarify, when you mention wanting to "self-host the Desktop Application," I'm assuming you mean building the desktop app locally from source? The term "self-host" in the Hoppscotch context typically refers to using our Docker image to host the Hoppscotch platform locally, and any desktop app distribution (whether our official release or locally built) can connect to that self-hosted instance via the instance switcher in the top-left corner. You can find detailed instructions for setting up and connecting to self-hosted instances in the [Desktop App README](https://github.com/hoppscotch/hoppscotch/tree/main/packages/hoppscotch-desktop#readme) and also the [Hoppscotch SH Edition section](https://docs.hoppscotch.io/documentation/clients/desktop#hoppscotch-self-hosted-edition-for-community) of the official docs. For troubleshooting those `pnpm` errors, Docker image building issues, and general setup help with connecting to self-hosted instances, I'd recommend checking the [Discussions tab](https://github.com/hoppscotch/hoppscotch/discussions); there are some existing threads that might help, but if they don't cover your specific issue, feel free to start a new discussion with the exact error messages you're seeing. I'll be happy to help there. Since the original precision issue has been resolved, I'll go ahead and close this issue. Thanks for your patience throughout! 🚀
Author
Owner

@auzundere commented on GitHub (Jul 17, 2025):

Thanks @CuriousCorrelation! Yes, I meant building the desktop app locally from source — and I’ve now successfully set up the on-premise instance. Everything is working great. Really appreciate your guidance throughout! 🙌

<!-- gh-comment-id:3084326248 --> @auzundere commented on GitHub (Jul 17, 2025): Thanks @CuriousCorrelation! Yes, I meant building the desktop app locally from source — and I’ve now successfully set up the on-premise instance. Everything is working great. Really appreciate your guidance throughout! 🙌
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#1962
No description provided.