ProxymanApp / Proxyman

Modern. Native. Delightful Web Debugging Proxy for macOS, iOS, and Android ⚡️
https://proxyman.io
5.57k stars 186 forks source link

Abort doesn't seem to work properly, keeps restarting requests from iOS Simulator #564

Open bobspryn opened 4 years ago

bobspryn commented 4 years ago

Proxyman version? (Ex. Proxyman 1.4.3)

Version 2.3.0 (20300), proxy helper tool not installed

macOS Version? (Ex. mac 10.14)

10.15.6

Steps to reproduce

Add a breakpoint to a request, tap abort when it's attempted

Expected behavior

The request should be in error state and I the app in the simulator should be notified that the request failed.

Observed behavior

The request keeps being reattempted and I have to hit abort again. Our app has logic to retry once, but it's not even getting to that point. Confirmed with a different proxy app that it works as expected there.

Screenshots (optional)

NghiaTranUIT commented 4 years ago

Thanks for the detailed report. Let me investigate it 👍

NghiaTranUIT commented 4 years ago

Hi @sprynmr, please check out this BETA build: https://proxyman.s3.us-east-2.amazonaws.com/beta/Proxyman_2.3.0_Fix_Breakpoint_Abort.dmg

The investigation shows that the client tries to re-connect to Proxyman after we hit Abort -> Show the breakpoint twice.

I fixed it by return 503 errors and close the connection immediately, like another app. Thus, no more breakpoint appears twice anymore 👍

Please check out and inform me that if it works for you. Thank you in advance 🎉

bobspryn commented 4 years ago

Thanks for the quick turnaround. It fixed it for request breakpoints, but I still see the same symptom for response ones. Obviously if you are intending to abort it for testing purposes it makes more sense to do it on a request breakpoint, but you probably want the same behavior on the response breakpoint.

NghiaTranUIT commented 4 years ago

Totally sorry about the bug on the response 🙀 I'm fixing it now

NghiaTranUIT commented 4 years ago

@sprynmr, let check out this build https://proxyman.s3.us-east-2.amazonaws.com/beta/Proxyman_2.3.0_Fix_Abort_Response.dmg

Same Abort Behavior on both Request and response 🎉

Thank you so much for reporting the bug 🌮

bobspryn commented 4 years ago

Can confirm Response works as well now!