nakama-js icon indicating copy to clipboard operation
nakama-js copied to clipboard

Javascript - Socket RPC never resolved or rejected when disconnected

Open Rojoss opened this issue 3 years ago • 1 comments

Hi, when making an RPC call while the network is turned off it never resolves or rejects. I assume this is not the intended behavior right?

As you an see in this gif the first request works properly when connected. Then I turn off the wifi and send another request, it's called but never resolved or rejected. Even when I turn my wifi back on.

ws_rpc_hangs

Rojoss avatar Feb 18 '22 16:02 Rojoss

Hey @Rojoss, thanks for finding this. It's definitely a problem and we'll look to fix it in the next release.

lugehorsam avatar May 16 '22 19:05 lugehorsam

@lugehorsam @novabyte I can take a look at this when I have time. What's the intended behaviour? Simply timing requests out or restoring them?

jackunion avatar Apr 26 '23 17:04 jackunion

Hey @jackunion and @Rojoss we've added socket heartbeating to the recent version of the client. This should resolve this issue. Let me know if it's still an issue.

lugehorsam avatar Apr 28 '23 13:04 lugehorsam