A redirection to an error page without explanation
<p>I have a rails app, where users can upload files (using <code>paperclip</code>). When uploading large files, the user is redirected to a 500 error page, and this only happens remotely; locally the user is redirected to the view of the new model, as expected. Moreover, despite the error page redirection, the model and its associated file were successfully uploaded and created. </p>

<p>Since it happens only with large files, I suspect it's due to a request timeout, but I'm using <code>puma</code> which <a href="https://github.com/puma/puma/issues/160" rel="nofollow">doesn't enforce such timeouts</a>.</p>

<p>That's the application log, the puma logs don't show anything abnormal.</p>

<pre><code>D, DEBUG -- :   SQL (0.4ms)  INSERT INTO "posts" [...]
D, DEBUG -- :    (0.9ms)  COMMIT
D, DEBUG -- :    (0.1ms)  BEGIN
D, DEBUG -- :    (0.1ms)  COMMIT
I, INFO -- : Started GET "/500.html" for [...]
F, FATAL -- :
ActionController::RoutingError (No route matches [GET] "/500.html"):
  actionpack (4.2.6) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
  actionpack (4.2.6) lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
  railties (4.2.6) lib/rails/rack/logger.rb:38:in `call_app'
  railties (4.2.6) lib/rails/rack/logger.rb:20:in `block in call'
  activesupport (4.2.6) lib/active_support/tagged_logging.rb:68:in `block in tagged'
  activesupport (4.2.6) lib/active_support/tagged_logging.rb:26:in `tagged'
  activesupport (4.2.6) lib/active_support/tagged_logging.rb:68:in `tagged'
  railties (4.2.6) lib/rails/rack/logger.rb:20:in `call'
  actionpack (4.2.6) lib/action_dispatch/middleware/request_id.rb:21:in `call'
  rack (1.6.4) lib/rack/methodoverride.rb:22:in `call'
  rack (1.6.4) lib/rack/runtime.rb:18:in `call'
  activesupport (4.2.6) lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
  rack (1.6.4) lib/rack/sendfile.rb:113:in `call'
  railties (4.2.6) lib/rails/engine.rb:518:in `call'
  railties (4.2.6) lib/rails/application.rb:165:in `call'
  puma (3.6.0) lib/puma/configuration.rb:225:in `call'
  puma (3.6.0) lib/puma/server.rb:578:in `handle_request'
  puma (3.6.0) lib/puma/server.rb:415:in `process_client'
  puma (3.6.0) lib/puma/server.rb:275:in `block in run'
  puma (3.6.0) lib/puma/thread_pool.rb:116:in `block in spawn_thread'
</code></pre>