Repository navigation
feat(python): unify GAOS HTTP errors onto native APIError and export GAOS error classes - #3236
Open
copybara-service[bot] wants to merge 1 commit into
Open
copybara-service[bot] wants to merge 1 commit into
copybara-service[bot] wants to merge 1 commit into
Conversation
copybara-service
Bot
force-pushed
the
copybara/1008500737
branch
4 times, most recently
from
October 29, 2026 20:36
39d7bb3 to
4182c35
Compare
…GAOS error classes Have 4xx/5xx GAOS compatibility error classes (`APIStatusError`, `BadRequestError`, `AuthenticationError`, `PermissionDeniedError`, `NotFoundError`, `ConflictError`, `UnprocessableEntityError`, `RateLimitError`, `InternalServerError`, and unmapped 4xx status errors) also inherit from native `google.genai.errors.APIError` (`ClientError` for 4xx, `ServerError` for 5xx) via multiple inheritance, and populate the native `code`, `status`, and `details` attributes alongside existing `status_code` and `body` attributes. Non-HTTP and schema validation errors (`APIConnectionError`, `APITimeoutError`, `APIResponseValidationError`) remain compat-only. Also export the GAOS error classes on `google.genai.interactions`, `google.genai.private.interactions`, `google.genai.errors` (with `InteractionsAPIError` aliasing compat `APIError`), and `google.genai.private.errors`, and deduplicate `_gaos_private.lib.compat_errors` against `_gaos.lib.compat_errors`. FUTURE_COPYBARA_INTEGRATE_REVIEW=#3209 from googleapis:release-please--branches--main 39c95f2 PiperOrigin-RevId: 1008500737
copybara-service
Bot
force-pushed
the
copybara/1008500737
branch
from
October 29, 2026 20:46
4182c35 to
3d9ad92
Compare
This branch has not been deployed
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
feat(python): unify GAOS HTTP errors onto native APIError and export GAOS error classes
Have 4xx/5xx GAOS compatibility error classes (
APIStatusError,BadRequestError,AuthenticationError,PermissionDeniedError,NotFoundError,ConflictError,UnprocessableEntityError,RateLimitError,InternalServerError, and unmapped 4xx status errors) also inherit from nativegoogle.genai.errors.APIError(ClientErrorfor 4xx,ServerErrorfor 5xx) via multiple inheritance, and populate the nativecode,status, anddetailsattributes alongside existingstatus_codeandbodyattributes. Non-HTTP and schema validation errors (APIConnectionError,APITimeoutError,APIResponseValidationError) remain compat-only.Also export the GAOS error classes on
google.genai.interactions,google.genai.private.interactions,google.genai.errors(withInteractionsAPIErroraliasing compatAPIError), andgoogle.genai.private.errors, and deduplicate_gaos_private.lib.compat_errorsagainst_gaos.lib.compat_errors.FUTURE_COPYBARA_INTEGRATE_REVIEW=#3209 from googleapis:release-please--branches--main 39c95f2