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

Fixed broken getting of body as a string #141

Closed

Conversation

awm1
Copy link

@awm1 awm1 commented Jun 13, 2023

as in this pull request

@gehrisandro
Copy link
Collaborator

@awm1 Could you give an example when does this problem occurs or provide a regression test?

@awm1
Copy link
Author

awm1 commented Jun 13, 2023

@awm1 Could you give an example when does this problem occurs or provide a regression test?

It occurs when I use \OpenAI::factory()->withHttpClient() + Client from php-http/guzzle7-adapter. It should be the same implementation of ClientInterface like Psr18Client, however, it returns empty getContents() due to its internal behaviour mentioned in that PR. I haven't found any standard this client violates so I suppose this fix may be good solution.

@gehrisandro
Copy link
Collaborator

@awm1 Do you have a working example of a failing setup? Maybe a repository?

The reason I ask: I could merge this PR as I don't see an issue, but I want to ensure it does not get reverted with the next refactoring as it already happened once. Therefore we need some way to write a regression test, which is only possible when I can reproduce the issue.

@gehrisandro
Copy link
Collaborator

@awm1 Still waiting for your example. But feel free to reopen this PR if needed.

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.

None yet

2 participants