Skip to content

blob/gcsblob: Handle grpc errors on gcsblob#3697

Merged
vangent merged 1 commit intogoogle:masterfrom
dpulpeiro:fix-blob-grpc-canceled-detection
Apr 9, 2026
Merged

blob/gcsblob: Handle grpc errors on gcsblob#3697
vangent merged 1 commit intogoogle:masterfrom
dpulpeiro:fix-blob-grpc-canceled-detection

Conversation

@dpulpeiro
Copy link
Copy Markdown
Contributor

@dpulpeiro dpulpeiro commented Apr 9, 2026

This PR fixes an issue where errors returned from an underlying gRPC client are incorrectly classified as Unknown.

Previously, when the gRPC client returned a structured error (e.g., Canceled, DeadlineExceeded, etc.), it was being surfaced as a generic Unknown error. This caused a loss of important context and made error handling more difficult.

For example, an error like (code=Unknown): rpc error: code = Canceled desc = context canceled was masking the actual Canceled status returned by gRPC.

Same approach is used in gcppubsubv2

func (*topic) ErrorCode(err error) gcerrors.ErrorCode {
return gcerr.GRPCCode(err)
}

@google-cla
Copy link
Copy Markdown

google-cla bot commented Apr 9, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@vangent
Copy link
Copy Markdown
Contributor

vangent commented Apr 9, 2026

Thanks!

@vangent vangent merged commit 30ab1a0 into google:master Apr 9, 2026
5 checks passed
@dpulpeiro
Copy link
Copy Markdown
Contributor Author

Do you know when the next release will be?

@vangent
Copy link
Copy Markdown
Contributor

vangent commented Apr 10, 2026

No specific timeline, I usually do one every few months. But you should be able to pick up the change independently of it being labeled as a release using pseudo-versions (https://go.dev/ref/mod#pseudo-versions).

@dpulpeiro dpulpeiro deleted the fix-blob-grpc-canceled-detection branch April 10, 2026 20:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants