Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat: support with_call for wrapped rpcs#550

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
daniel-sanche merged 4 commits intomainfromsupport_with_call
Nov 9, 2023

Conversation

@daniel-sanche
Copy link
Contributor

Most grpc calls return agrpc.Call object, that contains trailing metadata and other useful information. You can thenawait (for async unary rpcs) or iterate over (for streaming rpcs) the Call object to get the proto results of the rpc.

This is not the case for unary synchronous calls, because there is no intermediate object. Calling the rpc results in the value directly. The grpc library provideswith_call methods for this reason, which return a tuple of the rpc result and the Call object.

Currently, the gapic wrapper does not provide a way to access this data

This PR solves the issue by addingwith_call to thewrap_method function, which will is passed down to the grpc callable

@daniel-sanchedaniel-sanche requested review froma team ascode ownersNovember 9, 2023 20:32
@product-auto-labelproduct-auto-labelbot added the size: sPull request size is small. labelNov 9, 2023
@vchudnov-g
Copy link
Contributor

@daniel-sanche Could you fix the lint error?

@daniel-sanche
Copy link
ContributorAuthor

@daniel-sanche Could you fix the lint error?

fixed, thanks

@daniel-sanchedaniel-sanche merged commit01a57a7 intomainNov 9, 2023
@daniel-sanchedaniel-sanche deleted the support_with_call branchNovember 9, 2023 21:31
@release-pleaserelease-pleasebot mentioned this pull requestNov 9, 2023
This was referencedMay 30, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@vchudnov-gvchudnov-gvchudnov-g approved these changes

Assignees

No one assigned

Labels

size: sPull request size is small.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@daniel-sanche@vchudnov-g

[8]ページ先頭

©2009-2025 Movatter.jp