connectrpc/connect-swift

cardinality violations should use error code "unimplemented"

jhump opened this issue · 0 comments

The gRPC docs for error codes state that both client and server should use the unimplemented code for cardinality violations. See table at the bottom of this doc (you can search for “cardinality violation” in the doc): https://grpc.github.io/grpc/core/md_doc_statuscodes.html.

A cardinality violation is when a stream contains an incorrect number of messages. Specifically, when a response stream for a unary or client-stream RPC contains zero messages with an OK status or more than one message.

The client in this repo does not report an unimplemented error code to the application in these cases.