Closed azixMcAze closed 2 years ago
Hello @azixMcAze, so nice to have you back here, despite the unhappy circumstances.
Thanks for the detailed report. Unfortunately I won't be able to investigate this issue in the next couple weeks. Maybe @geoperez might want to chime in; otherwise I'm starting to work on it on the second week of August. I have pinned the issue so it doesn't get marked as stale in the meantime.
Context
Hello, I am doing some tests with websockets. I close an existing websocket and I open a new one just after:
I have an minimal WebsocketModule:
Observed Behaviour
The second time I re-open socket,
OnClientDisconnectedAsync
is called twice for the existing websocket that I juste closed.I get these log messages:
After tracing the code, It seems that
OnClientDisconnectedAsync
is called the first time fromPurgeDisconnectedContexts()
inOnRequestAsync()
and the second time from thefinally
block inOnRequestAsync()
.Enabling the watchdog or not does not change the behaviour
Expected Behavior
I expect that
OnClientDisconnectedAsync
is only called once per contextVersions
I observed the problem with EmbedIO v3.4.3 from nuget and build from source. I tested with Firefox 89 and Chrome 91 on mac. EmbedIO is called from the Unity Editor.