It is a type of its own, so a test can tell "the code made a call I did not script" apart from every error a real provider returns, and from the errors a test scripts with Reply.failure:
client.complete(conversation, options) match {
case Left(e: UnscriptedCallError) => e.callNumber // 3
case other => ...
}
It is not retryable, so a ReliableClient around the scripted client does not retry it.
Value parameters
callNumber
which call had no reply, counting from 1
lastMessage
the last message of the conversation, as role: "text" cut to 80 characters; None when the conversation had no messages
reason
why there was none, for example the script has 2 replies
The delay the server asked for before the request is sent again (an HTTP Retry-After header), and only that: None when the server gave none. A delay the library chooses when the server is silent is the retry policy's, never reported here, so "the server said" and "we guessed" stay distinguishable.
The delay the server asked for before the request is sent again (an HTTP Retry-After header), and only that: None when the server gave none. A delay the library chooses when the server is silent is the retry policy's, never reported here, so "the server said" and "we guessed" stay distinguishable.