Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KCP Threaded Client Error On Disconnect #3787

Open
joshuameurey opened this issue Mar 19, 2024 · 0 comments
Open

KCP Threaded Client Error On Disconnect #3787

joshuameurey opened this issue Mar 19, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@joshuameurey
Copy link

Describe the bug
Application produces this error "Skipped Data message handling because connection is null." each time one client is disconnecting normally from the host.

[IMPORTANT] How can we reproduce the issue, step by step:
Please tell us how to reproduce your issue, STEP BY STEP, with one of our built in examples.
-> Configure project to use Threaded KCP transport
-> Build and run a standalone application (this will be the host: client+server)
-> Run application in Unity Editor (this is a pure client), connect to the host
-> Disconnect properly the client (not in any bad/error conditions)
-> Log error appears in Unity Log
It appears that it remains data (bytes) in stack to process when the transport is disconnected

Any bug that can be reproduced, can be fixed.
If we can't reproduce it, we can't fix.

Expected behavior
Since the client is disconnected, no mater what is remaining in bytes data stack, it should not produce error.

Screenshots
N/A

StackTrace
Skipped Data message handling because connection is null. UnityEngine.Debug:LogError (object) Mirror.NetworkClient:OnTransportData (System.ArraySegment1<byte>,int) (at Assets/Mirror/Core/NetworkClient.cs:395) Mirror.ThreadedTransport:ClientEarlyUpdate () (at Assets/Mirror/Transports/Threaded/ThreadedTransport.cs:410) Mirror.NetworkClient:NetworkEarlyUpdate () (at Assets/Mirror/Core/NetworkClient.cs:1489) Mirror.NetworkLoop:NetworkEarlyUpdate () (at Assets/Mirror/Core/NetworkLoop.cs:193)

Desktop (please complete the following information):

  • OS: Windows 11
  • Build target: Windows
  • Unity version: 2022.3.14f1
  • Mirror branch: 86.13.4
  • KCP version: V1.39 [2023-10-31]

Additional context
Important: this is produced using Threaded KCP transport

@MrGadget1024 MrGadget1024 changed the title Mirror logs an error on client disconnection KCP Threaded Client Error On Disconnect Mar 19, 2024
@MrGadget1024 MrGadget1024 added the bug Something isn't working label Mar 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants