-
Notifications
You must be signed in to change notification settings - Fork 151
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
The output char buffer is too small to contain the decoded characters... #455
Comments
I expect the first exception you mentioned happens first. Since decoding a message is a protocol critical error, we disconnect, leading to the second one. The relevant code in the first exception is here: Do you have a solid repro? I'd like to investigate and fix this. |
What runtime and version are you on (e.g. .NET Framework or .NET Core x.y)? The |
The exception that happens first is the from rpc call Both sides use .NET Core 3.1. |
Thanks. I'm still pretty sure the decoding failure causes the connection loss, even if you observe the exceptions in the opposite order. But you can see in the Disconnected event that there's a reason property that should tell you why the disconnection happened for sure. I have a repro and filed a bug as linked above. I'll keep this issue open to track updating to the nerdbank.streams library that has the fix. |
Yes. I have added the Disconnected handler:
Now the order is following:
I can confirm that my case is using surrogate pairs. |
@n9 For now you can workaround the problem by installing the Nerdbank.Streams package directly in your project, with version 2.4.67 or above. |
@AArnott Thank you. It is no longer failing. |
I am getting the following the exception from
JsonRpc.Completion
.Stack trace is:
In addition to this exception, I am getting another exception from the method call:
with stack trace:
How to find out which exception is cause and which is effect?
Does RPC call fail because of the first exception: buffer issue?
Or does RPC call fail because of the second exception: remote party was lost?
The text was updated successfully, but these errors were encountered: