MCPcopy Create free account
hub / github.com/Effect-TS/effect / serializeDefectReply

Function serializeDefectReply

packages/cluster/src/RunnerServer.ts:26–34  ·  view source on GitHub ↗
(
  reply: Reply.ReplyWithContext<R>,
  defect: unknown
)

Source from the content-addressed store, hash-verified

24const constVoid = constant(Effect.void)
25
26const serializeDefectReply = <R extends Rpc.Any>(
27 reply: Reply.ReplyWithContext<R>,
28 defect: unknown
29): Effect.Effect<Reply.ReplyEncoded<any>> =>
30 Effect.orDie(Reply.serialize(Reply.ReplyWithContext.fromDefect({
31 id: reply.reply.id,
32 requestId: reply.reply.requestId,
33 defect
34 })))
35
36const serializeReply = <R extends Rpc.Any>(
37 reply: Reply.ReplyWithContext<R>

Callers 2

serializeReplyFunction · 0.85
respondFunction · 0.85

Calls 1

fromDefectMethod · 0.80

Tested by

no test coverage detected