microsoft / microsoft/vs-streamjsonrpc

HeaderDelimitedMessageHandler fails when formatter does not implement IJsonRpcMessageTextFormatter

Open
#1,282 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
C#
Stars
937
Forks
178
Avg merge
3d 1h
Merged PRs (30d)
28

Description

Using version 2.22.11. Trying to communicate between two processes using a named pipe. This is how both of them are initialized:

var handler = new HeaderDelimitedMessageHandler(Pipe, new MessagePackFormatter());

However, when calling a simple echo method via the proxy, I get this error:

System.NotSupportedException: 'Text encoding is not supported because the formatter "StreamJsonRpc.MessagePackFormatter" does not implement "StreamJsonRpc.IJsonRpcMessageTextFormatter".'

Image

I dont understand this error. Can't I use the MessagePackFormatter?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the named-pipe setup with HeaderDelimitedMessageHandler and MessagePackFormatter, then inspect how IJsonRpcMessageTextFormatter is required by the handler. Determine whether this formatter combination is supported; done means the compatibility behavior is resolved or clearly documented with coverage for the reported case.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
api, networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.