Exception:unexpected EOF
cnryb opened this issue · 5 comments
cnryb commented
system: windows
dotnet core version:3.0.100-preview6-012264
V2Ray version: 4.18.0
v2ray-dotnet-sdk version:4.18.0
Google.Protobuf version:3.6.1
Grpc version:1.19.0
.net core code
var channel = new Channel("127.0.0.1:10086", ChannelCredentials.Insecure);
HandlerServiceClient client = new HandlerServiceClient(channel);
RemoveUserOperation removeUserOperation = new RemoveUserOperation
{
Email = "a@b.c"
};
var r = client.AlterInbound(new AlterInboundRequest
{
Tag = "vss",
Operation = new TypedMessage
{
Type = "v2ray.core.app.proxyman.command.RemoveUserOperation",
Value = Google.Protobuf.ByteString.CopyFromUtf8(removeUserOperation.ToString())
}
});
Exception:
Grpc.Core.RpcException:“Status(StatusCode=Unknown, Detail="v2ray.com/core/app/proxyman/command: unknown operation > unexpected EOF")”
Can you help me
techotaku commented
How about .NET Core 2.2?
cnryb commented
On .NET Core 2.2.300, has the same exception.
cnryb commented
ubuntu 18.04
.net core 2.2.300
has the same exception.
techotaku commented
@cnryb Sorry, I didn't look at your code carefully. 😉
Just use removeUserOperation.ToByteString()
instead of ByteString.CopyFromUtf8()
.
cnryb commented
You are right.