-
Notifications
You must be signed in to change notification settings - Fork 9
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
Empty Response with Faraday 2.5.1 #14
Comments
I'm pinning gem "faraday-net_http", "< 3.0.0" # v3 currently breaks faraday-net_http_persistent |
Thank you for reporting this @MrSerth, indeed we should have pinned |
v2.0.2 is on its way 🎉 @MrSerth @mattbrictson I'd appreciate if you could give it a try and let me know if that solves the problem (after removing any pinning you might have added for |
@iMacTia Short answer, yes this works and I am all set. Long answer is that it is a little sensitive. If you have In that situation, if I try to force bundler to resolve 2.0.2 like this: gem "faraday-net_http_persistent", ">= 2.0.2" Then I get an error:
In that case deleting the Gemfile.lock does work, but it is a pretty drastic solution. However if uninstall all versions of all faraday gems and create a fresh Gemfile like this: source "https://rubygems.org"
# gem "rails"
gem "faraday"
gem "faraday-net_http_persistent" Then it does work as expected:
So I think people who upgraded to |
Thanks for releasing a new version and pinning |
Thank you both for confirming, at least this should stop the bleeding. The biggest issue here is that this adapter heavily relies on the net-http one even though it is a different library, and this is getting things hard to maintain now that they're in separate gems. The best course of action would probably be to remove the dependency from faraday-net_http and that would allow me to fix both issues at once 👍 |
Great! Let me know if there is anything I can do to help, whether it is testing, PR reviews, etc. |
confirmed ;) wrestling this out and it's pretty hard in our case where our Ruby apps are pulling this gem via a private gem. i can get those gems installing the correct things but when i get to the full apps... the bundler resolution process pulls me back into the badlands of |
for anyone else stumbling here, #14 (comment) seems to be working. |
@mattbrictson @rsl I've just opened a PR to address this together with #13, I'd really appreciate if you could either:
|
@iMacTia on it! |
@iMacTia not sure i can review some of that internals in i noticed the version number is the same as main right now tho.
i just ran this to verify it's running the correct version [out of curiosity]. the gemfile.lock does back it up tho.
|
I also tested the changes you pushed in our application, @iMacTia. With that development version, all tests pass as expected, the (implicitly required) gem |
Thank you both! I'll merge the PR and release as 2.1 shortly 🎉 |
I'm using 2.1.0 in production now and it is working great so far. Thanks! |
i'm jealous. discovered that |
Are they responsive at all? I could try opening a PR to upgrade to Faraday 2.0 |
i haven't seen them comment on any of the threads/issues about faraday versioning. i tried making a fork and updating but i think someone would have to know more about middleware [and the changes in the architecture] than i currently do. |
Oh yeah, I can see this one has been waiting 3 months already 😨! |
Basic Info
Issue description
In our project, we use Faraday with the Net::HTTP::Persistent adapter. Using Faraday 2.4.0 works fine, however, using Faraday 2.5.1 breaks our application.
Probably, this adapter is not yet compatible with the new streaming API introduced in Faraday 2.5.0?
Steps to reproduce
Executing the file with
ruby <filename>.rb
will render an error with the latest Faraday version:When using a previous version (change
gem "faraday"
togem "faraday", '~> 2.4.0'
in the example above), the test will succeed. Additionally, switching the adapter to:net_http
(instead of:net_http_persistent
) will also result in a successful test execution.The text was updated successfully, but these errors were encountered: