sprocket(?) fail when using capybara selenium with middleman - selenium

We've got a middleman site with some capybara acceptance tests running. Everything works find outside of the test environment, but we're trying to use capybara with selenium so we can test a codemirror editor element via the send_keys method https://github.com/thoughtbot/capybara-webkit/issues/870
Our spec_helper.rb looks like this:
require 'middleman'
require 'rspec'
require 'capybara/rspec'
require 'middleman-core/load_paths'
Middleman.setup_load_paths
Capybara.default_driver = :selenium
Capybara.app = Middleman::Application.server.inst do
set :root, File.expand_path(File.join(File.dirname(__FILE__), '..'))
set :environment, :test
set :show_exceptions, false
end
Selenium opens the firefox browser for us, however we get the following failure:
Error: File to import not found or unreadable: makers_styles.
Load paths:
/Users/tansaku/Documents/Github/MakersAcademy/apply/source/stylesheets
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/compass-core-1.0.3/stylesheets
Compass::SpriteImporter
on line 5 of /Users/tansaku/Documents/Github/MakersAcademy/apply/source/stylesheets/site.css.scss
1: //= require _vendor/pygment_solarized_light
2: //= require _vendor/codemirror-solarized
3: //= require codemirror
4:
5: #import "makers_styles";
6:
7: .align-left {
8: text-align: left;
9: }
10:
Using the network panel I can see this further backtrace:
Backtrace:
/Users/tansaku/Documents/Github/MakersAcademy/apply/source/stylesheets/site.css.scss:5
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/import_node.rb:67:in `rescue in import'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/import_node.rb:45:in `import'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/import_node.rb:28:in `imported_file'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/import_node.rb:37:in `css_import?'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:311:in `visit_import'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/base.rb:36:in `visit'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:158:in `block in visit'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/stack.rb:79:in `block in with_base'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/stack.rb:115:in `with_frame'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/stack.rb:79:in `with_base'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:158:in `visit'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/base.rb:52:in `block in visit_children'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/base.rb:52:in `map'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/base.rb:52:in `visit_children'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:167:in `block in visit_children'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:179:in `with_environment'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:166:in `visit_children'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/base.rb:36:in `block in visit'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:186:in `visit_root'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/base.rb:36:in `visit'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:157:in `visit'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/visitors/perform.rb:8:in `visit'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/root_node.rb:36:in `css_tree'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/tree/root_node.rb:20:in `render'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/sass-3.4.21/lib/sass/engine.rb:278:in `render'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/compass-import-once-1.0.5/lib/compass/import-once/engine.rb:17:in `block in render'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/compass-import-once-1.0.5/lib/compass/import-once/engine.rb:29:in `with_import_scope'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/compass-import-once-1.0.5/lib/compass/import-once/engine.rb:16:in `render'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/renderers/sass.rb:87:in `evaluate'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/tilt-1.4.1/lib/tilt/template.rb:103:in `render'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/rendering.rb:303:in `render_individual_file'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/rendering.rb:181:in `_render_with_all_renderers'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/rendering.rb:149:in `render_template'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/sitemap/resource.rb:127:in `block in render'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/activesupport-4.1.14/lib/active_support/notifications.rb:161:in `instrument'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/util.rb:41:in `instrument'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/application.rb:235:in `instrument'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/sitemap/resource.rb:14:in `instrument'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/sitemap/resource.rb:100:in `render'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/request.rb:260:in `process_request'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/request.rb:210:in `block in call!'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/request.rb:209:in `catch'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/request.rb:209:in `call!'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/middleman-core-3.3.12/lib/middleman-core/core_extensions/request.rb:195:in `call'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/capybara-2.5.0/lib/capybara/server.rb:19:in `call'
/Users/tansaku/.rvm/gems/ruby-2.2.3/gems/rack-1.6.4/lib/rack/handler/webrick.rb:88:in `service'
/Users/tansaku/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/webrick/httpserver.rb:138:in `service'
/Users/tansaku/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/webrick/httpserver.rb:94:in `run'
/Users/tansaku/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/webrick/server.rb:294:in `block in start_thread'
Any ideas? It all works fine in normal operation (we have makers_styles installed via bower, and all looks good outside of the test environment), but not in this capybara selenium setup ...
It seems like sprockets may not be adding the correct additional load paths in the testing setup ...

Related

Connection issues with Amazon S3 Rails 3.1.1 and Windows 7

I'm upgrading my rails app using Paperclip and uploading my attachments via ftp (using paperclipftp gem). I'm currently in my development environment which includes Rails 3.1.1, Ruby ruby 1.9.2p290, paperclip 3.0.4, aws-sdk 1.8.1.2
I've made changes to my app to utilize the aws-sdk gem to utilize amazon s3 for my attachment storage. Here's what I have in my Gemfile:
gem 'mysql2'
gem 'execjs'
gem 'web-app-theme', '~> 0.8.0'
gem 'therubyracer', :platforms => :ruby
gem 'paperclip', '~> 3.0.0'
gem 'tinymce-rails'
gem 'cocaine', '~> 0.3.2'
gem 'aws-sdk'
In my model I define the attachment with:
#paperclip
has_attached_file :upload,
:styles => Proc.new { |attach| attach.instance.attachment_styles },
:storage => :s3,
:s3_credentials => Rails.root.join('config', 's3.yml'),
:path => "/:attachment/:id/:style/:basename.:extension",
:url => "http://" + FTP_CONFIG['file_host'] + "/:attachment/:id/:style/:basename.:extension"
My s3.yml file looks like:
development:
bucket: a36-dev
access_key_id: #########
secret_access_key: ##########
test:
bucket: a36-test
access_key_id: #########
secret_access_key: #########
production:
bucket: a36-prod
access_key_id: #########
secret_access_key: #########
The error I continue to get is:
Errno::ECONNABORTED in MediaController#create_for_content
An established connection was aborted by the software in your host machine
Here's the stack trace:
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/openssl/buffering.rb:235:in `syswrite'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/openssl/buffering.rb:235:in `do_write'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/openssl/buffering.rb:249:in `write'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/protocol.rb:191:in `write0'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/protocol.rb:167:in `block in write'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/protocol.rb:182:in `writing'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/protocol.rb:166:in `write'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/http.rb:1756:in `send_request_with_body_stream'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/http.rb:1726:in `exec'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/http.rb:1189:in `transport_request'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/net/http.rb:1177:in `request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/net/http/connection_pool/session.rb:64:in `request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/net/http/connection_pool.rb:173:in `block in request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/net/http/connection_pool.rb:194:in `session_for'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/net/http/connection_pool.rb:171:in `request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/net/http/connection_pool/connection.rb:173:in `request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/http/net_http_handler.rb:66:in `handle'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:230:in `block in make_sync_request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:266:in `retry_server_errors'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:226:in `make_sync_request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:451:in `block (2 levels) in client_request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:334:in `log_client_request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:420:in `block in client_request'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:316:in `return_or_raise'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/core/client.rb:419:in `client_request'
(eval):3:in `put_object'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/s3/s3_object.rb:1649:in `write_with_put_object'
vendor/bundle/ruby/1.9.1/gems/aws-sdk-1.8.1.2/lib/aws/s3/s3_object.rb:600:in `write'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/storage/s3.rb:313:in `block in flush_writes'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/storage/s3.rb:299:in `each'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/storage/s3.rb:299:in `flush_writes'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/attachment.rb:200:in `save'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/instance_methods.rb:17:in `block in save_attached_files'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/instance_methods.rb:10:in `block in each_attachment'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/instance_methods.rb:9:in `each'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/instance_methods.rb:9:in `each_attachment'
vendor/bundle/ruby/1.9.1/gems/paperclip-3.0.4/lib/paperclip/instance_methods.rb:16:in `save_attached_files'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:401:in `_run_save_callbacks'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:81:in `run_callbacks'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/callbacks.rb:264:in `create_or_update'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/persistence.rb:37:in `save'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/validations.rb:50:in `save'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/attribute_methods/dirty.rb:22:in `save'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/transactions.rb:241:in `block (2 levels) in save'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/transactions.rb:295:in `block in with_transaction_returning_status'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/connection_adapters/abstract/database_statements.rb:192:in `transaction'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/transactions.rb:208:in `transaction'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/transactions.rb:293:in `with_transaction_returning_status'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/transactions.rb:241:in `block in save'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/transactions.rb:252:in `rollback_active_record_state!'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/transactions.rb:240:in `save'
app/controllers/media_controller.rb:207:in `create_for_content'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/abstract_controller/base.rb:167:in `process_action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal/rendering.rb:10:in `process_action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/abstract_controller/callbacks.rb:18:in `block in process_action'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:425:in `_run__690981913__process_action__778841897__callbacks'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:386:in `_run_process_action_callbacks'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:81:in `run_callbacks'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/abstract_controller/callbacks.rb:17:in `process_action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal/rescue.rb:17:in `process_action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/notifications.rb:53:in `block in instrument'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/notifications.rb:53:in `instrument'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal/instrumentation.rb:29:in `process_action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal/params_wrapper.rb:201:in `process_action'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/railties/controller_runtime.rb:18:in `process_action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/abstract_controller/base.rb:121:in `process'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/abstract_controller/rendering.rb:45:in `process'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal.rb:193:in `dispatch'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_controller/metal.rb:236:in `block in action'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:65:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:65:in `dispatch'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:29:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-mount-0.8.3/lib/rack/mount/route_set.rb:152:in `block in call'
vendor/bundle/ruby/1.9.1/gems/rack-mount-0.8.3/lib/rack/mount/code_generation.rb:96:in `block in recognize'
vendor/bundle/ruby/1.9.1/gems/rack-mount-0.8.3/lib/rack/mount/code_generation.rb:75:in `optimized_each'
vendor/bundle/ruby/1.9.1/gems/rack-mount-0.8.3/lib/rack/mount/code_generation.rb:95:in `recognize'
vendor/bundle/ruby/1.9.1/gems/rack-mount-0.8.3/lib/rack/mount/route_set.rb:141:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/routing/route_set.rb:532:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/etag.rb:23:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/conditionalget.rb:35:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/head.rb:14:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/params_parser.rb:21:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/flash.rb:243:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/session/abstract/id.rb:195:in `context'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/session/abstract/id.rb:190:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/cookies.rb:331:in `call'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/query_cache.rb:62:in `call'
vendor/bundle/ruby/1.9.1/gems/activerecord-3.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:477:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:392:in `_run_call_callbacks'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/callbacks.rb:81:in `run_callbacks'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/callbacks.rb:28:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/reloader.rb:68:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/sendfile.rb:101:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/remote_ip.rb:48:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/show_exceptions.rb:47:in `call'
vendor/bundle/ruby/1.9.1/gems/railties-3.1.1/lib/rails/rack/logger.rb:13:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/methodoverride.rb:24:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/runtime.rb:17:in `call'
vendor/bundle/ruby/1.9.1/gems/activesupport-3.1.1/lib/active_support/cache/strategy/local_cache.rb:72:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/lock.rb:15:in `call'
vendor/bundle/ruby/1.9.1/gems/actionpack-3.1.1/lib/action_dispatch/middleware/static.rb:53:in `call'
vendor/bundle/ruby/1.9.1/gems/railties-3.1.1/lib/rails/engine.rb:456:in `call'
vendor/bundle/ruby/1.9.1/gems/railties-3.1.1/lib/rails/rack/content_length.rb:16:in `call'
vendor/bundle/ruby/1.9.1/gems/railties-3.1.1/lib/rails/rack/log_tailer.rb:14:in `call'
vendor/bundle/ruby/1.9.1/gems/rack-1.3.9/lib/rack/handler/webrick.rb:59:in `service'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/webrick/httpserver.rb:111:in `service'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/webrick/httpserver.rb:70:in `run'
C:/RailsInstaller/Ruby1.9.2/lib/ruby/1.9.1/webrick/server.rb:183:in `block in start_thread'
I can't figure out why I keep getting this error. Any help would be greatly appreciated.
I was having the same problem and remembered I had recently update my aws-sdk, paperclip, cocaine gems. What I ended up doing was locking paperclip to version "3.0.4", aws-sdk to the latest version "~> 1.8.3.1", and locking cocaine at "0.3.2". This solves problems with imagemagick and amazon. I know that does not really fix the problem but it is working for me.

sql error cannot start a transaction within a transaction while testing with cucumber

I'm new to cucumber and I'm learning BDD
When I'm trying to fill a form and create a record this sqlite error is shown, though there's no error when I tried the code manually in my browser.
I'm using rails 4.
here is my controller code
class Admin::ItemsController < ApplicationController
def index
#items=Item.all
end
def new
#item=Item.new
end
def create
#item=Item.new items_params
respond_to do |format|
if #item.save
format.html { redirect_to admin_items_path }
else
format.html { redirect_to new_admin_items_path }
end
end
end
private
def items_params
params.require(:item).permit(:name,:price)
end
end
here is my Feature file
Feature: Manage Items
In order to make a store
As an admin
I want to create and manage items
Scenario: Items List
Given I go to the new admin item page
And I fill in "Name" with "Shampoo"
And I fill in "Price" with "50"
When I press "Create"
Then I should be on the admin items page
And I should see "Shampoo"
and step definitions
require File.expand_path(File.join(File.dirname(__FILE__), "..", "support", "paths"))
Given /^I go to the (.+)$/ do |page_name|
visit path_to(page_name)
end
And /^I fill in "([^\"]*)" with "([^\"]*)"$/ do |field, value|
fill_in(field.gsub(' ', '_'), :with => value)
end
When /^I press "([^\"]*)"$/ do |button|
click_button(button)
end
Then /^I should be on the (.+)$/ do |page_name|
current_path.should == path_to(page_name)
end
And /^I should see "(.*?)"$/ do |arg1|
page.should have_content(arg1)
end
This error is shown in step 4, i.e when create button is clicked and when items#create is called.
I don't know what is wrong with the code, hoping someone could help.
UPDATE:
I guess the problem is with a deprecation in cucumber-rails
https://github.com/cucumber/cucumber-rails/issues/231
Full trace:
Using the default profile...
WARNING: Nokogiri was built against LibXML version 2.7.8, but has dynamically loaded 2.9.0
DEPRECATION WARNING: ActionController::Integration is deprecated and will be removed, use ActionDispatch::Integration instead. (called from <module:Rails> at /home/phanindra/.gem/ruby/1.9.1/gems/cucumber-rails-1.3.0/lib/cucumber/rails/world.rb:9)
DEPRECATION WARNING: ActionController::IntegrationTest is deprecated and will be removed, use ActionDispatch::IntegrationTest instead. (called from <module:Rails> at /home/phanindra/.gem/ruby/1.9.1/gems/cucumber-rails-1.3.0/lib/cucumber/rails/world.rb:9)
Feature: Manage Items
In order to make a store
As an admin
I want to create and manage items
Scenario: Items List # features/manage_items.feature:6
DEPRECATION WARNING: #increment_open_transactions is deprecated and has no effect. (called from start at /home/phanindra/.gem/ruby/1.9.1/gems/database_cleaner-0.9.1/lib/database_cleaner/active_record/transaction.rb:11)
Given I go to the new admin item page # features/step_definitions/item_steps.rb:3
And I fill in "Name" with "Shampoo" # features/step_definitions/item_steps.rb:7
And I fill in "Price" with "50" # features/step_definitions/item_steps.rb:7
When I press "Create" # features/step_definitions/item_steps.rb:11
SQLite3::SQLException: cannot start a transaction within a transaction: begin transaction (ActiveRecord::StatementInvalid)
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/sqlite3_adapter.rb:353:in `block in begin_db_transaction'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb:305:in `block in log'
/home/phanindra/rails/activesupport/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb:300:in `log'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/sqlite3_adapter.rb:353:in `begin_db_transaction'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract/transaction.rb:129:in `initialize'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract/transaction.rb:17:in `new'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract/transaction.rb:17:in `begin'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb:231:in `begin_transaction'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb:208:in `within_new_transaction'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb:201:in `transaction'
/home/phanindra/rails/activerecord/lib/active_record/transactions.rb:209:in `transaction'
/home/phanindra/rails/activerecord/lib/active_record/transactions.rb:319:in `with_transaction_returning_status'
/home/phanindra/rails/activerecord/lib/active_record/transactions.rb:269:in `block in save'
/home/phanindra/rails/activerecord/lib/active_record/transactions.rb:280:in `rollback_active_record_state!'
/home/phanindra/rails/activerecord/lib/active_record/transactions.rb:268:in `save'
/home/phanindra/rails/activerecord/lib/active_record/persistence.rb:37:in `create'
./app/controllers/admin/items_controller.rb:11:in `create'
/home/phanindra/rails/actionpack/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
/home/phanindra/rails/actionpack/lib/abstract_controller/base.rb:189:in `process_action'
/home/phanindra/rails/actionpack/lib/action_controller/metal/rendering.rb:10:in `process_action'
/home/phanindra/rails/actionpack/lib/abstract_controller/callbacks.rb:18:in `block in process_action'
/home/phanindra/rails/activesupport/lib/active_support/callbacks.rb:393:in `_run__143383953690284082__process_action__callbacks'
/home/phanindra/rails/activesupport/lib/active_support/callbacks.rb:78:in `run_callbacks'
/home/phanindra/rails/actionpack/lib/abstract_controller/callbacks.rb:17:in `process_action'
/home/phanindra/rails/actionpack/lib/action_controller/metal/rescue.rb:29:in `process_action'
/home/phanindra/rails/actionpack/lib/action_controller/metal/instrumentation.rb:31:in `block in process_action'
/home/phanindra/rails/activesupport/lib/active_support/notifications.rb:158:in `block in instrument'
/home/phanindra/rails/activesupport/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/home/phanindra/rails/activesupport/lib/active_support/notifications.rb:158:in `instrument'
/home/phanindra/rails/actionpack/lib/action_controller/metal/instrumentation.rb:30:in `process_action'
/home/phanindra/rails/actionpack/lib/action_controller/metal/params_wrapper.rb:245:in `process_action'
/home/phanindra/rails/activerecord/lib/active_record/railties/controller_runtime.rb:18:in `process_action'
/home/phanindra/rails/actionpack/lib/abstract_controller/base.rb:136:in `process'
/home/phanindra/rails/actionpack/lib/abstract_controller/rendering.rb:44:in `process'
/home/phanindra/rails/actionpack/lib/action_controller/metal.rb:195:in `dispatch'
/home/phanindra/rails/actionpack/lib/action_controller/metal/rack_delegation.rb:13:in `dispatch'
/home/phanindra/rails/actionpack/lib/action_controller/metal.rb:231:in `block in action'
/home/phanindra/rails/actionpack/lib/action_dispatch/routing/route_set.rb:77:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/routing/route_set.rb:77:in `dispatch'
/home/phanindra/rails/actionpack/lib/action_dispatch/routing/route_set.rb:45:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/journey/router.rb:69:in `block in call'
/home/phanindra/rails/actionpack/lib/action_dispatch/journey/router.rb:57:in `each'
/home/phanindra/rails/actionpack/lib/action_dispatch/journey/router.rb:57:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/routing/route_set.rb:614:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/params_parser.rb:30:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/flash.rb:233:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/cookies.rb:443:in `call'
/home/phanindra/rails/activerecord/lib/active_record/query_cache.rb:36:in `call'
/home/phanindra/rails/activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb:632:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
/home/phanindra/rails/activesupport/lib/active_support/callbacks.rb:373:in `_run__2084705409073281596__call__callbacks'
/home/phanindra/rails/activesupport/lib/active_support/callbacks.rb:78:in `run_callbacks'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/callbacks.rb:27:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/remote_ip.rb:76:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/debug_exceptions.rb:18:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/show_exceptions.rb:31:in `call'
/home/phanindra/rails/railties/lib/rails/rack/logger.rb:32:in `call_app'
/home/phanindra/rails/railties/lib/rails/rack/logger.rb:16:in `block in call'
/home/phanindra/rails/activesupport/lib/active_support/tagged_logging.rb:67:in `block in tagged'
/home/phanindra/rails/activesupport/lib/active_support/tagged_logging.rb:25:in `tagged'
/home/phanindra/rails/activesupport/lib/active_support/tagged_logging.rb:67:in `tagged'
/home/phanindra/rails/railties/lib/rails/rack/logger.rb:16:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/request_id.rb:21:in `call'
/home/phanindra/rails/activesupport/lib/active_support/cache/strategy/local_cache.rb:72:in `call'
/home/phanindra/rails/actionpack/lib/action_dispatch/middleware/static.rb:63:in `call'
/home/phanindra/rails/railties/lib/rails/engine.rb:508:in `call'
/home/phanindra/rails/railties/lib/rails/application.rb:95:in `call'
./features/step_definitions/item_steps.rb:12:in `/^I press "([^\"]*)"$/'
features/manage_items.feature:10:in `When I press "Create"'
Then I should be on the admin items page # features/step_definitions/item_steps.rb:15
And I should see "Shampoo" # features/step_definitions/item_steps.rb:19
Failing Scenarios:
cucumber features/manage_items.feature:6 # Scenario: Items List
1 scenario (1 failed)
6 steps (1 failed, 2 skipped, 3 passed)
0m3.476s
It looks like you're using DatabaseCleaner, which by default runs each of your features in a transaction. Meanwhile, ActiveRecord itself starts a transaction when it saves the item. Unfortunately, SQLite doesn't support nested transactions.
If you change your DatabaseCleaner strategy to :truncation it should avoid this error. Alternatively, you could test against a more capable database like PostgreSQL.
This worked for me.
Edit your Gemfile to pull from the last source on github, as Andy H suggested.
gem 'database_cleaner', github: 'bmabey/database_cleaner'

Unable to log in to ActiveAdmin/Devise with Capybara

I am trying ActiveAdmin for the first time and have it working from the browser. I am not able to use Capybara to log in for integration testing, however. I have tried the fill-in-the-form method as well as stubbing the signin.
For example
it "allows user via capybara login" do
user = AdminUser.create(email: 'test#example.com', password: 'opensesame')
visit '/admin/login'
fill_in 'admin_user_email', with: user.email
fill_in 'admin_user_password', with: user.password
click_button 'Login'
end
gives the error message (full trace at end of post)
ActionView::Template::Error: wrong number of arguments (0 for 1)
/home/mike/ptbase/spec/support/request_helpers.rb:11:in `login'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/view_helpers/display_helper.rb:14:in `display_name'
I tried the stubbing method given by Joe's Notes
# spec/support/request_helpers.rb
require 'spec_helper'
include Warden::Test::Helpers
module RequestHelpers
def create_logged_in_user
user = FactoryGirl.create(:admin_user, password: 'opensesame')
login(user)
user
end
def login(user)
login_as user, scope: :user
end
end
# spec/features/patient_features_spec.rb
require 'spec_helper'
include RequestHelpers
feature "Patients" do
let(:authed_user) { create_logged_in_user }
it "should allow access" do
visit admin_dashboard_path(authed_user)
save_and_open_page
# should be good!
end
end
but that opens a page that says "You need to sign in or sign up before continuing."
I am using Rails 3.1.9, ActiveAdmin 0.5.0, and Capybara 2.0.1. I'm sure there must be an easy way to solve this ... obviously logging in is fundamental to integration testing ... but I can't seem to find it!
Full backtrace of above error:
ActionView::Template::Error: wrong number of arguments (0 for 1)
/home/mike/ptbase/spec/support/request_helpers.rb:11:in `login'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/view_helpers/display_helper.rb:14:in `display_name'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element.rb:175:in `method_missing'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/utility_nav.rb:21:in `build_current_user'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/utility_nav.rb:13:in `build'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:30:in `block in build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/context.rb:92:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:49:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:26:in `build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:39:in `insert_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/header.rb:26:in `build_utility_navigation'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/header.rb:13:in `build'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:30:in `block in build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/context.rb:92:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:49:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:26:in `build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:39:in `insert_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/pages/base.rb:49:in `build_header'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/pages/base.rb:40:in `block (2 levels) in build_page'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:31:in `block in build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/context.rb:92:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:49:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:26:in `build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:39:in `insert_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:18:in `div'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/pages/base.rb:39:in `block in build_page'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/context.rb:92:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:49:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/pages/base.rb:38:in `build_page'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/views/pages/base.rb:10:in `build'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:30:in `block in build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/context.rb:92:in `with_current_arbre_element'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:26:in `build_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/element/builder_methods.rb:39:in `insert_tag'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/app/views/active_admin/page/index.html.arb:1:in `block in __home_mike__rvm_gems_ruby_______p____perf_gems_activeadmin_______app_views_active_admin_page_index_html_arb___526514329_111865000'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/context.rb:45:in `instance_eval'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/arbre-1.0.1/lib/arbre/context.rb:45:in `initialize'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/app/views/active_admin/page/index.html.arb:1:in `new'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/app/views/active_admin/page/index.html.arb:1:in `__home_mike__rvm_gems_ruby_______p____perf_gems_activeadmin_______app_views_active_admin_page_index_html_arb___526514329_111865000'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/template.rb:145:in `block in render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/notifications.rb:125:in `instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/template.rb:143:in `render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/template_renderer.rb:47:in `block (2 levels) in render_template'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/abstract_renderer.rb:38:in `block in instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/notifications.rb:123:in `block in instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/notifications.rb:123:in `instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/abstract_renderer.rb:38:in `instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/template_renderer.rb:46:in `block in render_template'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/template_renderer.rb:54:in `render_with_layout'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/template_renderer.rb:45:in `render_template'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/template_renderer.rb:18:in `render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/renderer.rb:36:in `render_template'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_view/renderer/renderer.rb:17:in `render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/rendering.rb:110:in `_render_template'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/streaming.rb:225:in `_render_template'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/rendering.rb:103:in `render_to_body'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/renderers.rb:28:in `render_to_body'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/compatibility.rb:50:in `render_to_body'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/rendering.rb:88:in `render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/rendering.rb:16:in `render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/instrumentation.rb:40:in `block (2 levels) in render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/core_ext/benchmark.rb:5:in `block in ms'
/home/mike/.rvm/rubies/ruby-1.9.3-p194-perf/lib/ruby/1.9.1/benchmark.rb:295:in `realtime'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/core_ext/benchmark.rb:5:in `ms'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/instrumentation.rb:40:in `block in render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/instrumentation.rb:83:in `cleanup_view_runtime'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activerecord-3.2.9/lib/active_record/railties/controller_runtime.rb:24:in `cleanup_view_runtime'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/instrumentation.rb:39:in `render'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activeadmin-0.5.0/lib/active_admin/page_controller.rb:12:in `index'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/base.rb:167:in `process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/rendering.rb:10:in `process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/callbacks.rb:18:in `block in process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:447:in `_run__1002248294__process_action__401562286__callbacks'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:405:in `__run_callback'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:385:in `_run_process_action_callbacks'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:81:in `run_callbacks'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/callbacks.rb:17:in `process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/rescue.rb:29:in `process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/notifications.rb:123:in `block in instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/notifications.rb:123:in `instrument'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/instrumentation.rb:29:in `process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/params_wrapper.rb:207:in `process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activerecord-3.2.9/lib/active_record/railties/controller_runtime.rb:18:in `process_action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/base.rb:121:in `process'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/abstract_controller/rendering.rb:45:in `process'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal.rb:203:in `dispatch'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_controller/metal.rb:246:in `block in action'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/routing/route_set.rb:73:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/routing/route_set.rb:73:in `dispatch'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/routing/route_set.rb:36:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/journey-1.0.4/lib/journey/router.rb:68:in `block in call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/journey-1.0.4/lib/journey/router.rb:56:in `each'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/journey-1.0.4/lib/journey/router.rb:56:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/routing/route_set.rb:601:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/warden-1.2.1/lib/warden/manager.rb:35:in `block in call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/warden-1.2.1/lib/warden/manager.rb:34:in `catch'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/warden-1.2.1/lib/warden/manager.rb:34:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/etag.rb:23:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/conditionalget.rb:25:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/head.rb:14:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/params_parser.rb:21:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/flash.rb:242:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/session/abstract/id.rb:205:in `context'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/session/abstract/id.rb:200:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/cookies.rb:341:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activerecord-3.2.9/lib/active_record/query_cache.rb:64:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activerecord-3.2.9/lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/callbacks.rb:28:in `block in call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:405:in `_run__955233195__call__489842762__callbacks'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:405:in `__run_callback'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/callbacks.rb:81:in `run_callbacks'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/callbacks.rb:27:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/railties-3.2.9/lib/rails/rack/logger.rb:32:in `call_app'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/railties-3.2.9/lib/rails/rack/logger.rb:16:in `block in call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/tagged_logging.rb:22:in `tagged'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/railties-3.2.9/lib/rails/rack/logger.rb:16:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/request_id.rb:22:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/methodoverride.rb:21:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/runtime.rb:17:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/activesupport-3.2.9/lib/active_support/cache/strategy/local_cache.rb:72:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/lock.rb:15:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/actionpack-3.2.9/lib/action_dispatch/middleware/static.rb:62:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/railties-3.2.9/lib/rails/engine.rb:479:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/railties-3.2.9/lib/rails/application.rb:223:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/builder.rb:134:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/urlmap.rb:64:in `block in call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/urlmap.rb:49:in `each'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-1.4.1/lib/rack/urlmap.rb:49:in `call'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-test-0.6.2/lib/rack/mock_session.rb:30:in `request'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-test-0.6.2/lib/rack/test.rb:230:in `process_request'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rack-test-0.6.2/lib/rack/test.rb:57:in `get'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/rack_test/browser.rb:59:in `process'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/rack_test/browser.rb:38:in `block in process_and_follow_redirects'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/rack_test/browser.rb:37:in `times'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/rack_test/browser.rb:37:in `process_and_follow_redirects'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/rack_test/browser.rb:26:in `submit'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/rack_test/form.rb:64:in `submit'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/rack_test/node.rb:72:in `click'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/node/element.rb:103:in `block in click'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/node/base.rb:77:in `synchronize'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/node/element.rb:103:in `click'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/node/actions.rb:35:in `click_button'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/session.rb:338:in `block (2 levels) in <class:Session>'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/capybara-2.0.1/lib/capybara/dsl.rb:51:in `block (2 levels) in <module:DSL>'
/home/mike/ptbase/spec/features/patients_features_spec.rb:19:in `block (2 levels) in <top (required)>'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example.rb:114:in `instance_eval'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example.rb:114:in `block in run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example.rb:254:in `with_around_each_hooks'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example.rb:111:in `run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example_group.rb:388:in `block in run_examples'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example_group.rb:384:in `map'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example_group.rb:384:in `run_examples'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/example_group.rb:369:in `run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/command_line.rb:28:in `block (2 levels) in run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/command_line.rb:28:in `map'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/command_line.rb:28:in `block in run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/reporter.rb:34:in `report'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/command_line.rb:25:in `run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/runner.rb:66:in `rescue in run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/runner.rb:62:in `run'
/home/mike/.rvm/gems/ruby-1.9.3-p194-perf/gems/rspec-core-2.12.0/lib/rspec/core/runner.rb:8:in `block in autorun'
i ran into this issue few days ago, solved it by changing the setting in my spec_helper file as follow plus may you need to update the selinium and capybara versions too
Capybara.default_driver = :rack_test
Capybara.javascript_driver = :selenium
# You can also change the driver temporarily (typically in the Before/setup and After/teardown blocks):
# Use: Capybara.current_driver = :webkit # temporarily select different driver
# or use :js => true for specific test and it should use selenium by default.
# Or:
# Also see https://github.com/jnicklas/capybara#drivers
Capybara.default_wait_time = 5
Capybara.run_server = true #Whether start server when testing
Capybara.default_selector = :css #default selector , you can change to :css
OmniAuth.config.test_mode = true

Why Rails ActionMailer raises routing error in production environment?

I am having the following problem. My Resque background job fails when trying to render a template for ActionMailer. But this only happens when I am on production environment.
The error has to do with routing error. Here is the stack trace:
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_dispatch/routing/route_set.rb:425:in `raise_routing_error'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_dispatch/routing/route_set.rb:407:in `rescue in generate'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_dispatch/routing/route_set.rb:396:in `generate'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_dispatch/routing/route_set.rb:454:in `generate'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_dispatch/routing/route_set.rb:482:in `url_for'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_dispatch/routing/url_for.rb:131:in `url_for'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_view/helpers/url_helper.rb:99:in `url_for'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_dispatch/routing/route_set.rb:195:in `account_case_url'
/home/foo/production/source/app/views/case_mailer/case_creation.html.erb:3:in `_app_views_case_mailer_case_creation_html_erb__56964564007999368_36702160_384137435874551441'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_view/template.rb:162:in `block in render'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/activesupport-3.0.11/lib/active_support/notifications.rb:54:in `instrument'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_view/template.rb:154:in `render'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_view/render/rendering.rb:59:in `block in _render_template'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/activesupport-3.0.11/lib/active_support/notifications.rb:52:in `block in instrument'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/activesupport-3.0.11/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/activesupport-3.0.11/lib/active_support/notifications.rb:52:in `instrument'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_view/render/rendering.rb:56:in `_render_template'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/action_view/render/rendering.rb:26:in `render'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/abstract_controller/rendering.rb:115:in `_render_template'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/abstract_controller/rendering.rb:109:in `render_to_body'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/abstract_controller/rendering.rb:102:in `render_to_string'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/abstract_controller/rendering.rb:93:in `render'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/deprecated_api.rb:111:in `render'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:735:in `block in collect_responses_and_parts_order'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:750:in `each'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:750:in `block in each_template'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:745:in `each'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:745:in `each_template'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:731:in `collect_responses_and_parts_order'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:673:in `mail'
/home/foo/production/source/app/mailers/case_mailer.rb:13:in `case_creation'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/abstract_controller/base.rb:150:in `process_action'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/abstract_controller/base.rb:119:in `process'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionpack-3.0.11/lib/abstract_controller/rendering.rb:41:in `process'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/old_api.rb:75:in `process'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:471:in `process'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/actionmailer-3.0.11/lib/action_mailer/base.rb:466:in `initialize'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque_mailer-1.0.1/lib/resque_mailer/rails3.rb:16:in `new'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque_mailer-1.0.1/lib/resque_mailer/rails3.rb:16:in `deliver!'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque_mailer-1.0.1/lib/resque_mailer/rails3.rb:37:in `perform'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque-1.17.1/lib/resque/job.rb:127:in `perform'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque-1.17.1/lib/resque/worker.rb:163:in `perform'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque-1.17.1/lib/resque/worker.rb:130:in `block in work'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque-1.17.1/lib/resque/worker.rb:116:in `loop'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/resque-1.17.1/lib/resque/worker.rb:116:in `work'
script/resque_worker:13:in `start'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/daemon-spawn-0.4.2/lib/daemon_spawn.rb:51:in `block in start'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/daemon-spawn-0.4.2/lib/daemon_spawn.rb:38:in `fork'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/daemon-spawn-0.4.2/lib/daemon_spawn.rb:38:in `start'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/daemon-spawn-0.4.2/lib/daemon_spawn.rb:181:in `block in start'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/daemon-spawn-0.4.2/lib/daemon_spawn.rb:181:in `map'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/daemon-spawn-0.4.2/lib/daemon_spawn.rb:181:in `start'
/home/foo/production/source/vendor/bundle/ruby/1.9.1/gems/daemon-spawn-0.4.2/lib/daemon_spawn.rb:165:in `spawn!'
script/resque_worker:22:in `<main>'
The code in my view template has as follows:
link_to _("Click here to see the case"),
account_case_url(:only_path => false,
:host => "production.foo.com",
:controller => "cases",
:action => "show",
:id => #case.id, :account_id => #case.account.id)
I know that there is a similar post on SO but, the answer is not given. Also, I have to say, again, that my problem appears only on production environment.
UPDATE I have to say again that this is not related to resque. I can replicate the problem after disabling resque mailer. Hence, it is the ActionMailer on production that causes this problem.
UPDATE 2 Problem seems to be present on Rails 3.0.11 and 3.0.12. 3.0.10 works fine.
Rollback to Rails 3.0.10. Bug exists on 3.0.11 and 3.0.12.

rubymine crashes on debug

After months of good operation with my current gemset, I started getting the following error yesterday:
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/bin/ruby -e at_exit{sleep(1)};$stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/bin/rdebug-ide --port 57803 -- /Users/Tim/Sites/cba/script/rails server -b 0.0.0.0 -p 3000 -e development
Fast Debugger (ruby-debug-ide 0.4.17.beta8, ruby-debug-base 0.11.28) listens on 127.0.0.1:57803
=> Booting WEBrick
=> Rails 3.1.0.rc5 application starting in development on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
[2011-08-17 15:59:51] INFO WEBrick 1.3.1
[2011-08-17 15:59:51] INFO ruby 1.9.2 (2011-07-09) [x86_64-darwin10.8.0]
[2011-08-17 15:59:51] INFO WEBrick::HTTPServer#start: pid=34611 port=3000
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:80: [BUG] Segmentation fault
ruby 1.9.2p290 (2011-07-09 revision 32553) [x86_64-darwin10.8.0]
-- control frame ----------
c:0184 p:---- s:0895 b:0895 l:000894 d:000894 CFUNC :frame_file
c:0183 p:0014 s:0891 b:0891 l:000890 d:000890 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:80
c:0182 p:0026 s:0884 b:0884 l:000878 d:000883 BLOCK (eval):5
c:0181 p:0019 s:0882 b:0882 l:000881 d:000881 METHOD /Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201
c:0180 p:0012 s:0879 b:0879 l:000878 d:000878 METHOD (eval):3
c:0179 p:0018 s:0874 b:0874 l:001978 d:000873 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:69
c:0178 p:---- s:0871 b:0871 l:000870 d:000870 FINISH
c:0177 p:---- s:0869 b:0869 l:000868 d:000868 CFUNC :each
c:0176 p:0023 s:0866 b:0866 l:001978 d:000865 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:68
c:0175 p:0028 s:0864 b:0864 l:000863 d:000863 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:289
c:0174 p:0026 s:0860 b:0860 l:000854 d:000859 BLOCK (eval):5
c:0173 p:0019 s:0858 b:0858 l:000857 d:000857 METHOD /Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201
c:0172 p:0012 s:0855 b:0855 l:000854 d:000854 METHOD (eval):3
c:0171 p:0013 s:0850 b:0850 l:001978 d:001978 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:67
c:0170 p:0026 s:0845 b:0845 l:000839 d:000844 BLOCK (eval):5
c:0169 p:0019 s:0843 b:0843 l:000842 d:000842 METHOD /Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201
c:0168 p:0012 s:0840 b:0840 l:000839 d:000839 METHOD (eval):3
c:0167 p:0034 s:0835 b:0835 l:000834 d:000834 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/command.rb:85
c:0166 p:---- s:0829 b:0829 l:000828 d:000828 FINISH
c:0165 p:0029 s:0827 b:0827 l:000826 d:000826 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/commands/frame.rb:41
c:0164 p:0103 s:0824 b:0824 l:000805 d:000823 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:50
c:0163 p:---- s:0819 b:0819 l:000818 d:000818 FINISH
c:0162 p:---- s:0817 b:0817 l:000816 d:000816 CFUNC :each
c:0161 p:0020 s:0814 b:0814 l:000805 d:000813 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:43
c:0160 p:---- s:0812 b:0812 l:000811 d:000811 FINISH
c:0159 p:---- s:0810 b:0810 l:000809 d:000809 CFUNC :catch
c:0158 p:0261 s:0806 b:0806 l:000805 d:000805 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:42
c:0157 p:0222 s:0797 b:0797 l:000796 d:000796 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/event_processor.rb:61
c:0156 p:0059 s:0790 b:0790 l:000789 d:000789 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/event_processor.rb:37
c:0155 p:0022 s:0784 b:0784 l:000783 d:000783 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug-ide.rb:74
c:0154 p:---- s:0779 b:0779 l:000778 d:000778 FINISH
c:0153 p:0014 s:0777 b:0777 l:002048 d:002048 METHOD /Users/Tim/Sites/cba/app/helpers/site_menus_helper.rb:55
c:0152 p:0273 s:0770 b:0765 l:000764 d:000764 METHOD /Users/Tim/Sites/cba/app/views/home/menu/_with_children.haml:2
c:0151 p:0040 s:0750 b:0750 l:000742 d:000749 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:144
c:0150 p:0056 s:0748 b:0748 l:000747 d:000747 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:57
c:0124 p:0011 s:0636 b:0636 l:000635 d:000635 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/criteria.rb:133
c:0123 p:0050 s:0632 b:0632 l:0024f8 d:0024f8 METHOD /Users/Tim/Sites/cba/app/helpers/home_helper.rb:35
c:0122 p:0169 s:0625 b:0625 l:000d78 d:000d78 METHOD /Users/Tim/Sites/cba/app/views/home/menu/_application.haml:2
c:0121 p:0040 s:0614 b:0614 l:000606 d:000613 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:144
c:0120 p:0056 s:0612 b:0612 l:000611 d:000611 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:57
c:0119 p:0031 s:0607 b:0607 l:000606 d:000606 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:142
c:0118 p:0118 s:0599 b:0599 l:001ba0 d:001ba0 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:256
c:0117 p:0009 s:0589 b:0589 l:000558 d:000588 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:228
c:0116 p:0005 s:0587 b:0587 l:000570 d:000586 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:33
c:0115 p:0017 s:0585 b:0585 l:000575 d:000584 BLOCK /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55
c:0114 p:0032 s:0583 b:0583 l:000582 d:000582 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications/instrumenter.rb:21
c:0113 p:0036 s:0576 b:0576 l:000575 d:000575 METHOD /Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55
... removed to make the question work
....
...
c:0003 p:0126 s:0009 b:0009 l:001988 d:000008 BLOCK /Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/webrick/server.rb:183
c:0002 p:---- s:0004 b:0004 l:000003 d:000003 FINISH
c:0001 p:---- s:0002 b:0002 l:000001 d:000001 TOP
---------------------------
-- Ruby level backtrace information ----------------------------------------
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/webrick/server.rb:183:in `block in start_thread'
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/webrick/httpserver.rb:70:in `run'
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/webrick/httpserver.rb:111:in `service'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-1.3.2/lib/rack/handler/webrick.rb:59:in `service'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/railties-3.1.0.rc5/lib/rails/rack/log_tailer.rb:14:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/railties-3.1.0.rc5/lib/rails/rack/content_length.rb:16:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/railties-3.1.0.rc5/lib/rails/engine.rb:455:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/railties-3.1.0.rc5/lib/rails/rack/logger.rb:13:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/show_exceptions.rb:47:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/remote_ip.rb:48:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/reloader.rb:68:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/callbacks.rb:28:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/callbacks.rb:81:in `run_callbacks'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/callbacks.rb:392:in `_run_call_callbacks'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/cookies.rb:326:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-1.3.2/lib/rack/session/abstract/id.rb:190:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-1.3.2/lib/rack/session/abstract/id.rb:195:in `context'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/flash.rb:243:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/params_parser.rb:21:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/head.rb:14:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-1.3.2/lib/rack/conditionalget.rb:25:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-1.3.2/lib/rack/etag.rb:23:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/warden-1.0.5/lib/warden/manager.rb:34:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/warden-1.0.5/lib/warden/manager.rb:34:in `catch'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/warden-1.0.5/lib/warden/manager.rb:35:in `block in call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/rack/mongoid/middleware/identity_map.rb:33:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid.rb:130:in `unit_of_work'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/rack/mongoid/middleware/identity_map.rb:33:in `block in call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/omniauth-b1d5182c32f1/oa-core/lib/omniauth/builder.rb:30:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/omniauth-b1d5182c32f1/oa-core/lib/omniauth/strategy.rb:30:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/omniauth-b1d5182c32f1/oa-core/lib/omniauth/strategy.rb:44:in `call!'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/omniauth-b1d5182c32f1/oa-core/lib/omniauth/strategy.rb:30:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/omniauth-b1d5182c32f1/oa-core/lib/omniauth/strategy.rb:44:in `call!'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/omniauth-b1d5182c32f1/oa-core/lib/omniauth/strategy.rb:30:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/omniauth-b1d5182c32f1/oa-core/lib/omniauth/strategy.rb:44:in `call!'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/routing/route_set.rb:531:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-mount-0.8.2/lib/rack/mount/route_set.rb:141:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-mount-0.8.2/lib/rack/mount/code_generation.rb:95:in `recognize'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-mount-0.8.2/lib/rack/mount/code_generation.rb:75:in `optimized_each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-mount-0.8.2/lib/rack/mount/code_generation.rb:96:in `block in recognize'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/rack-mount-0.8.2/lib/rack/mount/route_set.rb:152:in `block in call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/routing/route_set.rb:29:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/routing/route_set.rb:65:in `dispatch'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_dispatch/routing/route_set.rb:65:in `call'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal.rb:236:in `block in action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal.rb:193:in `dispatch'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/rendering.rb:45:in `process'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/base.rb:121:in `process'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/params_wrapper.rb:202:in `process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/instrumentation.rb:29:in `process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55:in `block in instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/rescue.rb:17:in `process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/callbacks.rb:17:in `process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/callbacks.rb:81:in `run_callbacks'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/callbacks.rb:386:in `_run_process_action_callbacks'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/callbacks.rb:443:in `_run__4076465221882410554__process_action__462598362324508220__callbacks'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/callbacks.rb:18:in `block in process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/rendering.rb:10:in `process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/base.rb:167:in `process_action'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
/Users/Tim/Sites/cba/app/controllers/home_controller.rb:16:in `index'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/mime_responds.rb:195:in `respond_to'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/mime_responds.rb:195:in `call'
/Users/Tim/Sites/cba/app/controllers/home_controller.rb:21:in `block (2 levels) in index'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/instrumentation.rb:39:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/instrumentation.rb:78:in `cleanup_view_runtime'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/instrumentation.rb:40:in `block in render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/core_ext/benchmark.rb:5:in `ms'
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/benchmark.rb:310:in `realtime'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/core_ext/benchmark.rb:5:in `block in ms'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/instrumentation.rb:40:in `block (2 levels) in render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/rendering.rb:16:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/rendering.rb:99:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/compatibility.rb:43:in `render_to_body'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/renderers.rb:30:in `render_to_body'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/rendering.rb:114:in `render_to_body'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_controller/metal/streaming.rb:250:in `_render_template'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/abstract_controller/rendering.rb:120:in `_render_template'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/renderer.rb:17:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/renderer.rb:36:in `render_template'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/template_renderer.rb:9:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:22:in `wrap_formats'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/template_renderer.rb:12:in `block in render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/template_renderer.rb:38:in `render_template'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/template_renderer.rb:52:in `render_with_layout'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:142:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:57:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:144:in `block in render'
/Users/Tim/Sites/cba/app/views/layouts/application.html.erb:47:in `_app_views_layouts_application_html_erb__417568574572892803_2510507720'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/haml-3.1.2/lib/haml/helpers/action_view_mods.rb:13:in `render_with_haml'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/helpers/rendering_helper.rb:27:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/renderer.rb:41:in `render_partial'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:219:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:22:in `wrap_formats'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:227:in `block in render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:33:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55:in `block in instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:33:in `block in instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:57:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:144:in `block in render'
/Users/Tim/Sites/cba/app/views/home/menu/_application.haml:2:in `_app_views_home_menu__application_haml___2954044112154770234_2510634120'
/Users/Tim/Sites/cba/app/helpers/home_helper.rb:35:in `main_menu'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/criteria.rb:133:in `each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/criteria.rb:133:in `tap'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/criteria.rb:133:in `block in each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/contexts/mongo.rb:204:in `iterate'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/cursor.rb:48:in `each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongo-1.3.1/lib/mongo/cursor.rb:249:in `each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/cursor.rb:49:in `block in each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/mongoid-2.1.6/lib/mongoid/contexts/mongo.rb:204:in `block in iterate'
/Users/Tim/Sites/cba/app/helpers/home_helper.rb:37:in `block in main_menu'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/haml-3.1.2/lib/haml/helpers/action_view_mods.rb:11:in `render_with_haml'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/haml-3.1.2/lib/haml/helpers.rb:90:in `non_haml'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/haml-3.1.2/lib/haml/helpers/action_view_mods.rb:11:in `block in render_with_haml'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/helpers/rendering_helper.rb:27:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/renderer.rb:41:in `render_partial'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:219:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:22:in `wrap_formats'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:227:in `block in render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:33:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications/instrumenter.rb:21:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:55:in `block in instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/abstract_renderer.rb:33:in `block in instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:228:in `block (2 levels) in render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/renderer/partial_renderer.rb:256:in `render_partial'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:142:in `render'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/activesupport-3.1.0.rc5/lib/active_support/notifications.rb:57:in `instrument'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/gems/actionpack-3.1.0.rc5/lib/action_view/template.rb:144:in `block in render'
/Users/Tim/Sites/cba/app/views/home/menu/_with_children.haml:2:in `_app_views_home_menu__with_children_haml__2552955087828132551_2510502780'
/Users/Tim/Sites/cba/app/helpers/site_menus_helper.rb:55:in `menu_link_to'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug-ide.rb:74:in `at_line'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/event_processor.rb:37:in `at_line'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/event_processor.rb:61:in `line_event'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:42:in `process_commands'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:42:in `catch'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:43:in `block in process_commands'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:43:in `each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/ide_processor.rb:50:in `block (2 levels) in process_commands'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/commands/frame.rb:41:in `execute'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/command.rb:85:in `method_missing'
(eval):3:in `print_frames'
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
(eval):5:in `block in print_frames'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:67:in `print_frames'
(eval):3:in `print_element'
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
(eval):5:in `block in print_element'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:289:in `print_element'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:68:in `block in print_frames'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:68:in `each'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:69:in `block (2 levels) in print_frames'
(eval):3:in `print_frame'
/Users/Tim/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
(eval):5:in `block in print_frame'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:80:in `print_frame'
/Users/Tim/.rvm/gems/ruby-1.9.2-p290#cba/bundler/gems/ruby-debug-ide-c3a7a8529ae6/lib/ruby-debug/xml_printer.rb:80:in `frame_file'
-- C level backtrace information -------------------------------------------
[NOTE]
You may have encountered a bug in the Ruby interpreter or extension libraries.
Process finished with exit code 134
I have tried to fix this by updating the debug gems direct from github:
source 'http://rubygems.org'
gem 'simplecov', '>= 0.4.0', :require => false, :group => :test
gem 'httparty'
gem "rails", "3.1.0.rc5"
# Rails 3.1 - Asset Pipeline
group :assets do
...standard stuff
# Bundle gems needed for Mongoid
gem "mongoid", "2.1.6" # :path => "/Users/aa/Development/R31/mongoid-1" #"2.1.6"
gem "bson_ext" #, "1.1.5"
# Bundle gem needed for Devise and cancan
gem "devise", "~>1.4.0" # ,"1.1.7"
gem "cancan"
gem "googlecharts"
gem 'omniauth', :git => 'git://github.com/intridea/omniauth.git'
# we need some stuff too (tbb)
gem 'simple_form'
# for deployment
gem "capistrano"
# and server
gem 'unicorn'
# time to connect to opencongress
gem 'json'
gem 'geocoder'
#group :after_initialize do
gem 'nokogiri' #, :git => 'git://github.com/ender672/nokogiri.git'# :git => 'git://github.com/tenderlove/nokogiri.git'
gem 'feedzirra' #ls
gem 'sax-machine'
# Bundle gem needed for paperclip and attachments
gem "mongoid-paperclip", :require => "mongoid_paperclip"
# MongoID Extensions and extras
gem 'mongoid-tree', :require => 'mongoid/tree'
gem 'mongoid_fulltext'
# Bundle gems for views
gem "haml"
gem "will_paginate", "3.0.pre4"
gem 'escape_utils'
gem "RedCloth", "4.2.5" #"4.2.4.pre3 doesn't work with ruby 1.9.2-p180
# Gems by iboard.cc/CBA
gem "jsort", "~> 0.0.1"
# Markdown
# do "easy_install pygments" on your system
gem 'redcarpet'
gem 'albino'
# Bundle gems for development
group :development do
gem "nifty-generators"
gem "rails-erd"
gem 'rdoc'
gem "rails3-generators"
gem "ruby-debug19"
gem "ruby-debug-base19", :git => "git://github.com/JetBrains/ruby-debug-base19.git"
gem "ruby-debug-ide", :git => "git://github.com/JetBrains/ruby-debug-ide.git"
gem 'unicorn'
gem 'yard'
end
# Bundle gems for testing
I am trying to figure out a way to troubleshoot this or move forward. Any tips very appreciated.
Tim
Just update your ruby-debug-base19x gem with gem install ruby-debug-base19x --pre
Yet good solution - remove the entire .idea directory
In my case it worked!!!
I had a very similar problem like the one described above.
I solved it by clearing all the breakpoints.
Run->View Breakpoints->Remove All
I hope that helps someone :)