-
Notifications
You must be signed in to change notification settings - Fork 26
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
Streaming error mishandled in http.rb #20
Comments
Thanks, @strukturedkaos. Have you seen this occur @swombat ? |
Any chance of this being fixed in the next few days? We can't use the streaming api right now. |
Also getting this error |
@redders123 will see if I can fix this |
@alexrudall Anything I can help with? Are you able to reproduce the issue? In case it helps: ruby 3.2.2 |
Hey @strukturedkaos -- struggling to find the time to look at this - but I'm very open to a PR if you're able to figure out a fix! If not I will get to it when I can. |
I ran into this as well, it's because the streaming proc method signature changed in Faraday 2.5.0, and any older version only provides the first two arguments to the proc (see 6799f58). So you could update the gemspec to require ~> 2.5.0 of Faraday, although that wouldn't work for me as I have other gems that require < 2.0 of Faraday that I'm not able to easily upgrade. The other option is to update @alexrudall if you have any suggestions about how you'd like to handle older versions of Faraday and I can put together a PR. |
I created a PR that makes it functional for anyone using Faraday < 2.5.0: #21 Let me know if you have suggested changes on that one since it skips out on handling errors while receiving streaming results if Faraday < 2.5.0. |
@geeosh your fix worked for me. Thank you. Hopefully we can get the PR merged soon. |
Line 154 in http.rb on
env
isnil
on valid requests. This causesmerge
to error on line 157Example:
The text was updated successfully, but these errors were encountered: