def wire.fail.other
emerging-ezhttp@0.21.0.0 · src/wirespec.bend:361
import emerging-ezhttp@0.21.0.0/src/wirespec.bend as Wirespec
import Base
361
362def wire.fail.other(p: Phase, host: String, +port: U32, +n: U32, why: String)
363 -> String:
364 match p:
365 case Resolve{}:
366 wire.fail.resolve(host, n, U32.is_eq(n, 2))
367 case Connect{}:
368 "7\ncould not reach " ++ host ++ " port " ++ U32.show(port) ++ ": "
369 ++ wire.cause(n)
370 case Handshake{}:
371 "35\nthe TLS handshake with " ++ host ++ " failed: " ++ wire.cause(n)
372 ++ ": " ++ why
373 case Send{}:
374 "55\nthe request to " ++ host ++ " could not be sent: " ++ wire.cause(n)
375 case Receive{}:
376 "56\nthe answer from " ++ host ++ " was cut short: " ++ wire.cause(n)