-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Do not convert Rack::Response to Rack::Response #1045
Do not convert Rack::Response to Rack::Response #1045
Conversation
Ouch. Can you please add a line to the CHANGELOG? I will probably cut a dot release with this since it's a regression. |
While using https://github.com/aserafin/grape_logging grape middleware after an upgrading grape from 0.11 to 0.12 I've been stuck with an issue: ``` NoMethodError (undefined method `downcase' for 2:Fixnum) ``` That's because `Middleware#response` tries to convert `Rack::Response` to `Rack::Response` and fails.
4e0fc3a
to
7ad647a
Compare
@dblock Rebased with |
Do not convert Rack::Response to Rack::Response
Merged. |
Just ran into this problem. Will really appreciate a new release! Thanks! |
I was just having the same problem, and I wonder if this PR fully fixes it. After building the gem from the latest source, I still had the problem, but it goes away when using 0.11.0. |
+1. Still seeing this exact error message after building a 0.12.1 version from master. |
What about using |
@dmitry That ought to be the same code in master, right? In any case, the problem is still there. |
@AndyDangerous can you show the full stacktrace? |
Here it is, @dmitry
|
Got the same error today on one of my project using Grape 0.12.0 !
|
@patfrat you have to use grape from master, because this patch isn't released in a new gem yet. |
Grape 0.10.0 is working for me ... not 0.11.0 nor 0.12.0 |
@dmitry i use grape from master in my project |
It's another issue, and the issue is in rails 4.2.3: https://github.com/rails/rails/blob/4-2-stable/activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb#L654 |
Is it happens while tests or in a development/production mode? |
For us, it was in development. |
@AndyDangerous @patfrat I believe you have to move grape middleware upper than Basically you are experiencing an issue inside |
In development mode too
|
How do you mounting grape API? |
I am using Rack::Cascade.new [Api, ApiDoc, statics] |
@patfrat but where do you put this Rack::Cascade instance? |
I believe we have to stop chatting here about your issues, and you have to create a new issue... because it's unrelated to this this fix at all. |
ok @dmitry |
While using https://github.com/aserafin/grape_logging grape middleware after an upgrading grape from 0.11 to 0.12 I've been stuck with an issue (aserafin/grape_logging#6):
That's because
Middleware#response
tries to convertRack::Response
toRack::Response
and fails.