Sharagoz/rails_exception_handler — pull request #12 by davidjrice (2014-11-21 16:30:44+00:00)
Title: Handle ActionDispatch::Response::RackBody in Rails 4.2 beta

In Rails 4.2 beta a new class has been introduced. ```ActionDispatch::Response::RackBody```
https://github.com/rails/rails/blob/master/actionpack/lib/action_dispatch/http/response.rb#L356

This essentially wraps ActionDispatch::Response but does not allow access to the object directly.

Causing an error during exception handling in a Rails 4.2 app. ```Undefined method body= for ActionDispatch::Response::RackBody```

Here is a simple but hacky way of getting round the error. However it's probably not the best solution going forward.

Also, there are a bunch of test failures if you up the rails requirement to ```gem 'rails', '4.2.0.beta4'``` and this does not address the majority of them.