mirror of
https://github.com/ProxymanApp/Proxyman.git
synced 2026-04-26 00:25:56 +03:00
[GH-ISSUE #301] [BUG] Too many digits on Request / Response Body Size #297
Labels
No labels
Discussion
Feature request
In Progress...
Plugins
Waiting response
Windows
Windows
bug
duplicate
enhancement
feature
good first issue
iOS
macOS 10.11
question
wontfix
✅ Done
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/Proxyman#297
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @NghiaTranUIT on GitHub (Oct 14, 2019).
Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/301
Originally assigned to: @NghiaTranUIT on GitHub.
🐶 Brief
In the latest version, they request and response body size have many redundant digits.
👑 Criteria
@shirshak55 commented on GitHub (Oct 14, 2019):
haha this floating point digit is always pain in ass :) Specially in JS as it only has f64 it even gets more irritating.
@NghiaTranUIT commented on GitHub (Oct 15, 2019):
In the past, I encountered this floating pain when parsing the number in JSON too (https://github.com/ProxymanApp/Proxyman/issues/169). It's weird that the JSONSerialization class in Foundation framework doesn't handle it properly and our developer have to fix it manually. 😅
@NghiaTranUIT commented on GitHub (Oct 18, 2019):
All done 🎉
Changelogs
formatter.maximumFractionDigitsinNSNumberFormatter@shirshak55 commented on GitHub (Oct 18, 2019):
@NghiaTranUIT what will happen if the data was actually 70.000000001?
@NghiaTranUIT commented on GitHub (Oct 18, 2019):
We round it up to 70 (Bytes) 😄
@shirshak55 commented on GitHub (Oct 18, 2019):
hmm i am that is problem right? Lets say I am working on money endpoint and supplied 70.00001 and proxyman made it 70 and i mock that response to test api server now it will fail because my api server consumer expects it to be 70.00001 not 70 . SO I think proxy man should serve same response given by server and should not roundup etc.
@NghiaTranUIT commented on GitHub (Oct 18, 2019):
The size of the response remains as it is (70.00001) and your Test API server won't be failed. It only rounds up for the presenter on the flow panel.
If we need the precise value, I suppose that I would implement the Summary tab, which presents all essential data without round up.
@shirshak55 commented on GitHub (Oct 18, 2019):
i mean if i save response to disk will it modify according to presenter or it will save response as it should?