forked from karthink/gptel
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
gptel: API agnostic response error handling
* gptel.el (gptel--url-get-response, gptel--url-parse-response): - When the query fails, the error message format (in the JSON) differs between APIs. Ultimately it may be required to dispatch error handling via a generic function, but for now: try to make the error handling API agnostic. - Mention the backend name in the error message. Pass the backend to the (non-streaming response) parsers to be able to do this. * gptel-curl.el (gptel-curl--stream-cleanup, gptel-curl--parse-response): Same changes.
- Loading branch information
Showing
2 changed files
with
39 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters