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

fix: extract request-id from response headers #479

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

AngeloGiacco
Copy link
Collaborator

@AngeloGiacco AngeloGiacco commented Feb 10, 2025

fixes #478

please don't merge, want to leave for fern folks to see

Copy link
Collaborator

@PaulAsjes PaulAsjes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, just one little nit.

return
request_id = _response.headers.get('request-id')
if not request_id:
raise ApiError(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How likely is this to happen?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

impossible because we set it if not provided by the user

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i can just leave it as optional alternatively ?

@AngeloGiacco
Copy link
Collaborator Author

please don't merge, want to leave for fern folks to see

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.

Add response attribute to TextToSpeechClient class
2 participants