Second PR to introduce UnreadableResponse exception
Third PR with only Phpdoc update
The purpose of this PR is to provide an easy way to try/catch method of this lib:
It avoids catching \Exception which catch everything
It avoids catching OpenAI\Exceptions\ErrorException|OpenAI\Exceptions\InvalidArgumentException|... which is complicated and can miss an exception if a new one is introduced later.
What:
Description:
Hi @gehrisandro
I'm trying to move https://github.com/openai-php/client/pull/287 forward by splitting it in 3 smaller PRs:
The purpose of this PR is to provide an easy way to try/catch method of this lib:
\Exception
which catch everythingOpenAI\Exceptions\ErrorException|OpenAI\Exceptions\InvalidArgumentException|...
which is complicated and can miss an exception if a new one is introduced later.Related:
https://github.com/openai-php/client/pull/287