gapic-generator-python icon indicating copy to clipboard operation
gapic-generator-python copied to clipboard

Determine if we want to log streaming responses in gapic-generator-python

Open parthea opened this issue 8 months ago • 0 comments

Capturing discussion from https://github.com/googleapis/gapic-generator-python/pull/2340.

Streaming responses are logged in google-api-core as of https://github.com/googleapis/python-api-core/pull/794. We should determine if we want to move the streaming iterator to gapic-generator-python so we can inspect the next item and log it.

See the discussion in https://github.com/googleapis/gapic-generator-python/pull/2340#discussion_r2027502501.

This discussion will be captured in code so that if/when we decide to refactor the streaming logic, we can determine if we want to consolidate the logging logic.

Depending how we want to log (a) receiving a streaming response vs (b) exposing the next streamed item to the user, we could possibly want to log something here
(a) should always happen in api-core
(b) could happen in api-core, or it could happen here when we iterate to the next streamed item that was previously received.

parthea avatar May 09 '25 14:05 parthea