Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up async docs and unify for future GAPIC async. #2638

Merged

Conversation

daspecster
Copy link
Contributor

@dhermes mentioned this in a previous review.
This is correct and I also cleaned up the docs.

In my testing with async, I haven't gotten more than one alternative to show up, even whith max_alternatives=2. So that's why there isn't two in the doc example.

@daspecster daspecster added the api: speech Issues related to the Speech-to-Text API. label Oct 28, 2016
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Oct 28, 2016
@daspecster daspecster added the do not merge Indicates a pull request not ready for merge, due to either quality or timing. label Oct 28, 2016
@@ -123,8 +123,9 @@ def _update(self, response):
raw_results = response.get('response', {}).get('results', None)

This comment was marked as spam.

@daspecster daspecster removed the do not merge Indicates a pull request not ready for merge, due to either quality or timing. label Oct 28, 2016
from google.cloud.speech.transcript import Transcript


class SpeechResult(object):

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

@daspecster daspecster mentioned this pull request Oct 28, 2016
14 tasks
results.append(Transcript.from_api_repr(result))
for result in raw_results:
for alternative in result['alternatives']:
results.append(Transcript.from_api_repr(alternative))

This comment was marked as spam.

@@ -46,10 +46,12 @@ def test_from_api_repr(self):
self.assertEqual('123456789', operation.name)
self.assertTrue(operation.complete)

self.assertIsInstance(operation.results, list)

This comment was marked as spam.

This comment was marked as spam.

@daspecster daspecster force-pushed the unify-speech-async-operation-results branch from 7afb765 to 1c5ed57 Compare October 29, 2016 02:22
@daspecster daspecster merged commit 1cbc793 into googleapis:master Oct 29, 2016
@daspecster daspecster deleted the unify-speech-async-operation-results branch October 29, 2016 02:28
richkadel pushed a commit to richkadel/google-cloud-python that referenced this pull request May 6, 2017
…-operation-results

Clean up async docs and unify for future GAPIC async.
atulep pushed a commit that referenced this pull request Apr 3, 2023
…-results

Clean up async docs and unify for future GAPIC async.
atulep pushed a commit that referenced this pull request Apr 18, 2023
…-results

Clean up async docs and unify for future GAPIC async.
parthea pushed a commit that referenced this pull request Oct 22, 2023
…-results

Clean up async docs and unify for future GAPIC async.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: speech Issues related to the Speech-to-Text API. cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants