No Method Error on an unmodified Devise boolean - ruby-on-rails

I am working on a legacy RoR app and am in the midst of configuring devise (as a replacement for Restful_authentication plugin). I have ran into a very peculiar error. When I try to go to /users/sign_in page I get this
NoMethodError in Devise::SessionsController#new
undefined method `is_navigational_format?' for #<Devise::SessionsController:0x000000034b2078>
The only time I have seen this error referenced is when someone is trying to override the devise session-controller with their own. (https://groups.google.com/d/msg/plataformatec-devise/jyYNhaRztDU/MLsjwxRvf_YJ) I have not tried to do that.
I have installed devise correctly (followed their wiki). I have added devise_for :users to my routes. I have restarted the server, many many times. If there is any more info, or files needed, I will be happy to provide them.
Edit when I ran $LOAD_PATH.dup in the rails console the output included
"/usr/local/rvm/gems/ruby-1.9.3-p429/gems/devise-2.2.4/lib", "/usr/local/rvm/gems/ruby-1.9.3-p429/gems/devise-2.2.4/app/controllers", "/usr/local/rvm/gems/ruby-1.9.3-p429/gems/devise-2.2.4/app/helpers", "/usr/local/rvm/gems/ruby-1.9.3-p429/gems/devise-2.2.4/app/mailers"
I am using Rails 3.2.13, ruby 1.9.3 and devise 2.2.4
This is the full-stack trace
devise (2.2.4) app/controllers/devise_controller.rb:119:in require_no_authentication'
activesupport (3.2.13) lib/active_support/callbacks.rb:418:inrun_1218703357271506681__process_action_3906451143611010656_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in __run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in_run_process_action_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in run_callbacks'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:17:inprocess_action'
actionpack (3.2.13) lib/action_controller/metal/rescue.rb:29:in process_action'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:30:inblock in process_action'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in block in instrument'
activesupport (3.2.13) lib/active_support/notifications/instrumenter.rb:20:ininstrument'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in instrument'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:29:inprocess_action'
actionpack (3.2.13) lib/action_controller/metal/params_wrapper.rb:207:in process_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:121:inprocess'
actionpack (3.2.13) lib/abstract_controller/rendering.rb:45:in process'
actionpack (3.2.13) lib/action_controller/metal.rb:203:indispatch'
actionpack (3.2.13) lib/action_controller/metal/rack_delegation.rb:14:in dispatch'
actionpack (3.2.13) lib/action_controller/metal.rb:246:inblock in action'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:indispatch'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:36:in call'
actionpack (3.2.13) lib/action_dispatch/routing/mapper.rb:42:incall'
journey (1.0.4) lib/journey/router.rb:68:in block in call'
journey (1.0.4) lib/journey/router.rb:56:ineach'
journey (1.0.4) lib/journey/router.rb:56:in call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:612:incall'
warden (1.2.1) lib/warden/manager.rb:35:in block in call'
warden (1.2.1) lib/warden/manager.rb:34:incatch'
arden (1.2.1) lib/warden/manager.rb:34:in call'
actionpack (3.2.13) lib/action_dispatch/middleware/best_standards_support.rb:17:incall'
rack (1.4.5) lib/rack/etag.rb:23:in call'
rack (1.4.5) lib/rack/conditionalget.rb:25:incall'
actionpack (3.2.13) lib/action_dispatch/middleware/head.rb:14:in call'
actionpack (3.2.13) lib/action_dispatch/middleware/params_parser.rb:21:incall'
actionpack (3.2.13) lib/action_dispatch/middleware/flash.rb:242:in call'
rack (1.4.5) lib/rack/session/abstract/id.rb:210:incontext'
rack (1.4.5) lib/rack/session/abstract/id.rb:205:in call'
actionpack (3.2.13) lib/action_dispatch/middleware/cookies.rb:341:incall'
activerecord (3.2.13) lib/active_record/query_cache.rb:64:in call'
activerecord (3.2.13) lib/active_record/connection_adapters/abstract/connection_pool.rb:479:incall'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:28:in block in call'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:inrun_3871622813520347987_call_3063468228496691759__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in __run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in_run_call_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in run_callbacks'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:27:incall'
actionpack (3.2.13) lib/action_dispatch/middleware/reloader.rb:65:in call'
actionpack (3.2.13) lib/action_dispatch/middleware/remote_ip.rb:31:incall'
actionpack (3.2.13) lib/action_dispatch/middleware/debug_exceptions.rb:16:in call'
actionpack (3.2.13) lib/action_dispatch/middleware/show_exceptions.rb:56:incall'
railties (3.2.13) lib/rails/rack/logger.rb:32:in call_app'
railties (3.2.13) lib/rails/rack/logger.rb:16:inblock in call'
activesupport (3.2.13) lib/active_support/tagged_logging.rb:22:in tagged'
railties (3.2.13) lib/rails/rack/logger.rb:16:incall'
actionpack (3.2.13) lib/action_dispatch/middleware/request_id.rb:22:in call'
rack (1.4.5) lib/rack/methodoverride.rb:21:incall'
rack (1.4.5) lib/rack/runtime.rb:17:in call'
activesupport (3.2.13) lib/active_support/cache/strategy/local_cache.rb:72:incall'
rack (1.4.5) lib/rack/lock.rb:15:in call'
actionpack (3.2.13) lib/action_dispatch/middleware/static.rb:63:incall'
railties (3.2.13) lib/rails/engine.rb:479:in call'
railties (3.2.13) lib/rails/application.rb:223:incall'
railties (3.2.13) lib/rails/railtie/configurable.rb:30:in method_missing'
passenger (4.0.2) lib/phusion_passenger/rack/thread_handler_extension.rb:77:inprocess_request'
passenger (4.0.2) lib/phusion_passenger/request_handler/thread_handler.rb:135:in accept_and_process_next_request'
passenger (4.0.2) lib/phusion_passenger/request_handler/thread_handler.rb:106:inmain_loop'
passenger (4.0.2) lib/phusion_passenger/request_handler.rb:449:in block (4 levels) in start_threads'
passenger (4.0.2) lib/phusion_passenger/utils/robust_interruption.rb:108:indisable_interruptions'
passenger (4.0.2) lib/phusion_passenger/request_handler.rb:444:in `block (3 levels) in start_threads'

Related

NoMethodError: Undefined method 'type' for nil:NilClass in Rails

Getting a NoMethodError when trying to load up one of the pages on my website built with Rails. See the full stack trace below.
If I change false to true in production.rb at line
config.cache_classes = false
then the problem goes away, but I have to restart the Rails server every time I make a change to any file. It seems like the problem is related to checking the type of a column in my DB, but I can't figure out how to resolve it.
Controller action:
def manage
#view_data = {}
if (#view_data[:product] = Product.find(params[:id])).nil?
raise ActionController::RoutingError.new('Not Found')
end
#view_data[:backlog] = Task.where("product_id = ? AND status < ?", params[:id], Task::STATUS_COMPLETED)
.page(params[:page]).per(10)
#view_data[:completed] = Task.where(product_id: params[:id], status: Task::STATUS_COMPLETED)
.page(params[:page]).per(10)
end
There are four columns on the 'tasks' table that are type datetime--I think those are causing the problem, but I'm not fully sure.
Full stack trace:
NoMethodError - undefined method `type' for nil:NilClass:
activerecord (3.2.13) lib/active_record/attribute_methods/time_zone_conversion.rb:60:in `create_time_zone_conversion_attribute?'
activerecord (3.2.13) lib/active_record/attribute_methods/time_zone_conversion.rb:24:in `attribute_cast_code'
activerecord (3.2.13) lib/active_record/attribute_methods/serialization.rb:80:in `attribute_cast_code'
activerecord (3.2.13) lib/active_record/attribute_methods/read.rb:72:in `define_method_attribute'
activerecord (3.2.13) lib/active_record/attribute_methods/primary_key.rb:29:in `define_method_attribute'
activemodel (3.2.13) lib/active_model/attribute_methods.rb:267:in `block in define_attribute_method'
activemodel (3.2.13) lib/active_model/attribute_methods.rb:260:in `define_attribute_method'
activemodel (3.2.13) lib/active_model/attribute_methods.rb:256:in `block in define_attribute_methods'
activemodel (3.2.13) lib/active_model/attribute_methods.rb:256:in `define_attribute_methods'
activerecord (3.2.13) lib/active_record/attribute_methods.rb:66:in `block in define_attribute_methods'
activerecord (3.2.13) lib/active_record/attribute_methods.rb:63:in `define_attribute_methods'
activerecord (3.2.13) lib/active_record/attribute_methods.rb:168:in `respond_to?'
activesupport (3.2.13) lib/active_support/callbacks.rb:398:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_initialize_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
activerecord (3.2.13) lib/active_record/base.rb:501:in `initialize'
app/controllers/products_controller.rb:14:in `manage'
actionpack (3.2.13) lib/action_controller/metal/implicit_render.rb:4:in `send_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:167:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/rendering.rb:10:in `process_action'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:18:in `block in process_action'
activesupport (3.2.13) lib/active_support/callbacks.rb:425:in `_run__115665803178931257__process_action__4080704983955383443__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_process_action_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:17:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/rescue.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `block in instrument'
activesupport (3.2.13) lib/active_support/notifications/instrumenter.rb:20:in `instrument'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `instrument'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/params_wrapper.rb:207:in `process_action'
activerecord (3.2.13) lib/active_record/railties/controller_runtime.rb:18:in `process_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:121:in `process'
actionpack (3.2.13) lib/abstract_controller/rendering.rb:45:in `process'
actionpack (3.2.13) lib/action_controller/metal.rb:203:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal.rb:246:in `block in action'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in `dispatch'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:36:in `call'
journey (1.0.4) lib/journey/router.rb:68:in `block in call'
journey (1.0.4) lib/journey/router.rb:56:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:612:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
rack (1.4.5) lib/rack/etag.rb:23:in `call'
rack (1.4.5) lib/rack/conditionalget.rb:25:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/head.rb:14:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/params_parser.rb:21:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/flash.rb:242:in `call'
rack (1.4.5) lib/rack/session/abstract/id.rb:210:in `context'
rack (1.4.5) lib/rack/session/abstract/id.rb:205:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/cookies.rb:341:in `call'
activerecord (3.2.13) lib/active_record/query_cache.rb:64:in `call'
activerecord (3.2.13) lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:28:in `block in call'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `_run__4157597128006817714__call__2909158845673021585__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
better_errors (0.9.0) lib/better_errors/middleware.rb:84:in `protected_app_call'
better_errors (0.9.0) lib/better_errors/middleware.rb:79:in `better_errors_call'
better_errors (0.9.0) lib/better_errors/middleware.rb:56:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
railties (3.2.13) lib/rails/rack/logger.rb:32:in `call_app'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `block in call'
activesupport (3.2.13) lib/active_support/tagged_logging.rb:22:in `tagged'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/request_id.rb:22:in `call'
rack (1.4.5) lib/rack/methodoverride.rb:21:in `call'
rack (1.4.5) lib/rack/runtime.rb:17:in `call'
activesupport (3.2.13) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
rack (1.4.5) lib/rack/lock.rb:15:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/static.rb:63:in `call'
railties (3.2.13) lib/rails/engine.rb:479:in `call'
railties (3.2.13) lib/rails/application.rb:223:in `call'
rack (1.4.5) lib/rack/content_length.rb:14:in `call'
railties (3.2.13) lib/rails/rack/log_tailer.rb:17:in `call'
rack (1.4.5) lib/rack/handler/webrick.rb:59:in `service'
In my case I had a model with 76 attributes, and one of them was named 'class', this was causing the error and exception.
So, I did:
rake/bin db:rollback
rails d scaffold MyModel
rename 'class' column in scaffold generator command
rename 'class' in csv header
rails g scaffold MyModel blablaba..
rake/bin db:migrate
import data
rails s
And works :-)
It seems like your error is related to this bug. There are some proposed solutions that may be relevant for your situation, or you could try this fix by alsemyonov.
Try setting config.autoload_once_paths

undefined method `child_ancestry' using ancestry gem

I'm trying to implement nested micropost replies in the Rails Tutorial with Michael Hartl. I've installed the ancestry gem, included has_ancestry in the Micropost model, and restarted the server, but I continue to get this error. Link to github repo and full trace below.
https://github.com/johnklawlor/sample_app
NoMethodError in MicropostsController#new
undefined method `child_ancestry' for "302":String
Rails.root: /Users/johnlawlor/rails_projects/sample_app
Application Trace | Framework Trace | Full Trace
ancestry (2.0.0) lib/ancestry/instance_methods.rb:114:in `parent='
app/controllers/microposts_controller.rb:7:in `new'
actionpack (3.2.13) lib/action_controller/metal/implicit_render.rb:4:in `send_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:167:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/rendering.rb:10:in `process_action'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:18:in `block in process_action'
activesupport (3.2.13) lib/active_support/callbacks.rb:425:in `_run__2568186625216276787__process_action__4261485550099489968__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_process_action_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:17:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/rescue.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `block in instrument'
activesupport (3.2.13) lib/active_support/notifications/instrumenter.rb:20:in `instrument'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `instrument'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/params_wrapper.rb:207:in `process_action'
activerecord (3.2.13) lib/active_record/railties/controller_runtime.rb:18:in `process_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:121:in `process'
actionpack (3.2.13) lib/abstract_controller/rendering.rb:45:in `process'
actionpack (3.2.13) lib/action_controller/metal.rb:203:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal.rb:246:in `block in action'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in `dispatch'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:36:in `call'
journey (1.0.4) lib/journey/router.rb:68:in `block in call'
journey (1.0.4) lib/journey/router.rb:56:in `each'
journey (1.0.4) lib/journey/router.rb:56:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:612:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
rack (1.4.5) lib/rack/etag.rb:23:in `call'
rack (1.4.5) lib/rack/conditionalget.rb:25:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/head.rb:14:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/params_parser.rb:21:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/flash.rb:242:in `call'
rack (1.4.5) lib/rack/session/abstract/id.rb:210:in `context'
rack (1.4.5) lib/rack/session/abstract/id.rb:205:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/cookies.rb:341:in `call'
activerecord (3.2.13) lib/active_record/query_cache.rb:64:in `call'
activerecord (3.2.13) lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:28:in `block in call'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `_run__3072718973742101490__call__2739205707066950640__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/reloader.rb:65:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
railties (3.2.13) lib/rails/rack/logger.rb:32:in `call_app'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `block in call'
activesupport (3.2.13) lib/active_support/tagged_logging.rb:22:in `tagged'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/request_id.rb:22:in `call'
rack (1.4.5) lib/rack/methodoverride.rb:21:in `call'
rack (1.4.5) lib/rack/runtime.rb:17:in `call'
activesupport (3.2.13) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
rack (1.4.5) lib/rack/lock.rb:15:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/static.rb:63:in `call'
railties (3.2.13) lib/rails/engine.rb:479:in `call'
railties (3.2.13) lib/rails/application.rb:223:in `call'
rack (1.4.5) lib/rack/content_length.rb:14:in `call'
railties (3.2.13) lib/rails/rack/log_tailer.rb:17:in `call'
rack (1.4.5) lib/rack/handler/webrick.rb:59:in `service'
/Users/johnlawlor/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/webrick/httpserver.rb:138:in `service'
/Users/johnlawlor/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/webrick/httpserver.rb:94:in `run'
/Users/johnlawlor/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/webrick/server.rb:191:in `block in start_thread'
Parameters:
{"parent_id"=>"302"}
You're assigning the id to the parent setter, while you should use parent_id here.
Try changing:
#micropost.parent = params[ :parent_id]
to:
#micropost.parent_id = params[:parent_id]

Spree admin panel configuration menu not working

After installing Spree_Subscription gem, I got following error, when goto "Configuration Menu" under Admin Panel
NameError in Spree::Admin::GeneralSettingsController#edit
uninitialized constant Spree::GeneralSetting
I installed spree_subscription gem from following link
https://github.com/DynamoMTL/spree_subscriptions
Full Trace
activesupport (3.2.13) lib/active_support/inflector/methods.rb:230:in `block in constantize'
activesupport (3.2.13) lib/active_support/inflector/methods.rb:229:in `each'
activesupport (3.2.13) lib/active_support/inflector/methods.rb:229:in `constantize'
activesupport (3.2.13) lib/active_support/core_ext/string/inflections.rb:54:in `constantize'
spree_auth_devise (1.3.1) app/controllers/spree/admin/admin_controller_decorator.rb:5:in `model_class'
spree_core (1.3.3) app/controllers/spree/admin/base_controller.rb:19:in `authorize_admin'
activesupport (3.2.13) lib/active_support/callbacks.rb:473:in `_run__464357097018810999__process_action__2499127901059018972__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_process_action_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:17:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/rescue.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `block in instrument'
activesupport (3.2.13) lib/active_support/notifications/instrumenter.rb:20:in `instrument'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `instrument'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/params_wrapper.rb:207:in `process_action'
activerecord (3.2.13) lib/active_record/railties/controller_runtime.rb:18:in `process_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:121:in `process'
actionpack (3.2.13) lib/abstract_controller/rendering.rb:45:in `process'
actionpack (3.2.13) lib/action_controller/metal.rb:203:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal.rb:246:in `block in action'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in `dispatch'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:36:in `call'
journey (1.0.4) lib/journey/router.rb:68:in `block in call'
journey (1.0.4) lib/journey/router.rb:56:in `each'
journey (1.0.4) lib/journey/router.rb:56:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:612:in `call'
spree_core (1.3.3) lib/spree/core/middleware/redirect_legacy_product_url.rb:13:in `call'
spree_core (1.3.3) lib/spree/core/middleware/seo_assist.rb:27:in `call'
railties (3.2.13) lib/rails/engine.rb:479:in `call'
railties (3.2.13) lib/rails/railtie/configurable.rb:30:in `method_missing'
journey (1.0.4) lib/journey/router.rb:68:in `block in call'
journey (1.0.4) lib/journey/router.rb:56:in `each'
journey (1.0.4) lib/journey/router.rb:56:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:612:in `call'
warden (1.1.1) lib/warden/manager.rb:35:in `block in call'
warden (1.1.1) lib/warden/manager.rb:34:in `catch'
warden (1.1.1) lib/warden/manager.rb:34:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
rack (1.4.5) lib/rack/etag.rb:23:in `call'
rack (1.4.5) lib/rack/conditionalget.rb:25:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/head.rb:14:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/params_parser.rb:21:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/flash.rb:242:in `call'
rack (1.4.5) lib/rack/session/abstract/id.rb:210:in `context'
rack (1.4.5) lib/rack/session/abstract/id.rb:205:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/cookies.rb:341:in `call'
activerecord (3.2.13) lib/active_record/query_cache.rb:64:in `call'
activerecord (3.2.13) lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:28:in `block in call'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `_run__897956655828939022__call__2053947994652827205__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/reloader.rb:65:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
railties (3.2.13) lib/rails/rack/logger.rb:32:in `call_app'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `block in call'
activesupport (3.2.13) lib/active_support/tagged_logging.rb:22:in `tagged'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/request_id.rb:22:in `call'
rack (1.4.5) lib/rack/methodoverride.rb:21:in `call'
rack (1.4.5) lib/rack/runtime.rb:17:in `call'
activesupport (3.2.13) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
rack (1.4.5) lib/rack/lock.rb:15:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/static.rb:63:in `call'
railties (3.2.13) lib/rails/engine.rb:479:in `call'
railties (3.2.13) lib/rails/application.rb:223:in `call'
rack (1.4.5) lib/rack/content_length.rb:14:in `call'
railties (3.2.13) lib/rails/rack/log_tailer.rb:17:in `call'
rack (1.4.5) lib/rack/handler/webrick.rb:59:in `service'
/usr/local/rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:138:in `service'
/usr/local/rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:94:in `run'
/usr/local/rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/webrick/server.rb:191:in `block in start_thread'
You may need to bump spree_auth_devise. I believe this commit fixes your issue:
https://github.com/spree/spree_auth_devise/commit/328f00dc1b79e1273063a79e5b04a3ee5fa9ebd6

TypeError in UsersController#create

I'm using the code for this SaaS example, but when I run the code on Ruby 1.9.3 and signup, I get this error:
http://i.stack.imgur.com/BCB0H.png
I'm on Ruby 1.9.3, Rails 3.2.13
It seems to be failing on the creation step:
users_controller.rb:
def create_memcached_instance
docker_path = '/usr/bin'
container_id = `#{docker_path}docker run -d -p 11211 jbarbier/memcached memcached -u daemon`
cmd = "#{docker_path}docker inspect #{container_id}"
json_infos = `#{cmd}`
i = JSON.parse(json_infos)
#user.memcached = i["NetworkSettings"]["PortMapping"]["11211"]
#user.container_id = container_id
#user.docker_ip = i["NetworkSettings"]["IpAddress"]
end
Full Trace:
json (1.7.7) lib/json/common.rb:155:in `initialize'
json (1.7.7) lib/json/common.rb:155:in `new'
json (1.7.7) lib/json/common.rb:155:in `parse'
app/controllers/users_controller.rb:73:in `create_memcached_instance'
app/controllers/users_controller.rb:49:in `create'
actionpack (3.2.13) lib/action_controller/metal/implicit_render.rb:4:in `send_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:167:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/rendering.rb:10:in `process_action'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:18:in `block in process_action'
activesupport (3.2.13) lib/active_support/callbacks.rb:414:in `_run__1753984858439435449__process_action__4397313512021220537__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_process_action_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/abstract_controller/callbacks.rb:17:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/rescue.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `block in instrument'
activesupport (3.2.13) lib/active_support/notifications/instrumenter.rb:20:in `instrument'
activesupport (3.2.13) lib/active_support/notifications.rb:123:in `instrument'
actionpack (3.2.13) lib/action_controller/metal/instrumentation.rb:29:in `process_action'
actionpack (3.2.13) lib/action_controller/metal/params_wrapper.rb:207:in `process_action'
activerecord (3.2.13) lib/active_record/railties/controller_runtime.rb:18:in `process_action'
actionpack (3.2.13) lib/abstract_controller/base.rb:121:in `process'
actionpack (3.2.13) lib/abstract_controller/rendering.rb:45:in `process'
actionpack (3.2.13) lib/action_controller/metal.rb:203:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
actionpack (3.2.13) lib/action_controller/metal.rb:246:in `block in action'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:73:in `dispatch'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:36:in `call'
journey (1.0.4) lib/journey/router.rb:68:in `block in call'
journey (1.0.4) lib/journey/router.rb:56:in `each'
journey (1.0.4) lib/journey/router.rb:56:in `call'
actionpack (3.2.13) lib/action_dispatch/routing/route_set.rb:612:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
rack (1.4.5) lib/rack/etag.rb:23:in `call'
rack (1.4.5) lib/rack/conditionalget.rb:35:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/head.rb:14:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/params_parser.rb:21:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/flash.rb:242:in `call'
rack (1.4.5) lib/rack/session/abstract/id.rb:210:in `context'
rack (1.4.5) lib/rack/session/abstract/id.rb:205:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/cookies.rb:341:in `call'
activerecord (3.2.13) lib/active_record/query_cache.rb:64:in `call'
activerecord (3.2.13) lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:28:in `block in call'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `_run__1573725910118489674__call__8700384058904149__callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.13) lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
activesupport (3.2.13) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.13) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/reloader.rb:65:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
railties (3.2.13) lib/rails/rack/logger.rb:32:in `call_app'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `block in call'
activesupport (3.2.13) lib/active_support/tagged_logging.rb:22:in `tagged'
railties (3.2.13) lib/rails/rack/logger.rb:16:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/request_id.rb:22:in `call'
rack (1.4.5) lib/rack/methodoverride.rb:21:in `call'
rack (1.4.5) lib/rack/runtime.rb:17:in `call'
activesupport (3.2.13) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
rack (1.4.5) lib/rack/lock.rb:15:in `call'
actionpack (3.2.13) lib/action_dispatch/middleware/static.rb:63:in `call'
railties (3.2.13) lib/rails/engine.rb:479:in `call'
railties (3.2.13) lib/rails/application.rb:223:in `call'
rack (1.4.5) lib/rack/content_length.rb:14:in `call'
railties (3.2.13) lib/rails/rack/log_tailer.rb:17:in `call'
rack (1.4.5) lib/rack/handler/webrick.rb:59:in `service'
/usr/local/rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/webrick/httpserver.rb:138:in `service'
/usr/local/rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/webrick/httpserver.rb:94:in `run'
/usr/local/rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/webrick/server.rb:191:in `block in start_thread'
1.9.3p194 :002 > j = JSON.parse(nil)
TypeError: can't convert nil into String
from /Users/mike.campbell/.rvm/gems/ruby-1.9.3-p194/gems/json-1.7.7/lib/json/common.rb:155:in `initialize'
from /Users/mike.campbell/.rvm/gems/ruby-1.9.3-p194/gems/json-1.7.7/lib/json/common.rb:155:in `new'
from /Users/mike.campbell/.rvm/gems/ruby-1.9.3-p194/gems/json-1.7.7/lib/json/common.rb:155:in `parse'
That quick IRB experiement leads me to the conclusion that your variable json_infos is nil.
Are you sure you don't want docker_path = '/usr/bin/' (with the trailing slash)? Unless you have the directory /usr/bindocker ...

Rails Paperclip gem wrong number of arguments error

I'm working on my first RoR project and attempting to use the Paperclip gem, but I'm running into an error I can't seem to figure out:
wrong number of arguments (1 for 0)
app/controllers/events_controller.rb:43:in `create'
Parameters:
{"utf8"=>"✓",
"authenticity_token"=>"OBYHA0M+TA93sNF3uqrJ/zvnnEyWJUREn4NcOl0ExfA=",
"event"=>{"title"=>"",
"image"=>#<ActionDispatch::Http::UploadedFile:0x007f803802b1f0 #original_filename="icon.png",
#content_type="image/png",
#headers="Content-Disposition: form-data; name=\"event[image]\"; filename=\"icon.png\"\r\nContent-Type: image/png\r\n",
#tempfile=#<File:/tmp/RackMultipart20130217-21480-1molvwa>>,
"description"=>"",
"date"=>"",
"time"=>""},
"commit"=>"Create Event"}
I understand that in events_controller.rb in the create method, too many arguments are being passed in. However, I followed the QuickStart instructions on Paperclip's Github so I'm not sure why I'm getting this error.
Here is my code for events_controller.rb
def create
#event = Event.create( params[:event] )
end
Just for debugging, I tried changing the line to Event.create( params[] ), at which point the error changed from wrong number of arguments (1 for 0) to wrong number of arguments (0 for 1).
Here is my code for event.rb
class Event < ActiveRecord::Base
attr_accessible :date, :description, :time, :title, :image
has_attached_file :image, :styles => { :medium => "300x300>", :thumb => "100x100>" }
end
I've checked that I'm running the correct versions for everything. I have Paperclip 3.4.0, Rails 3.2.12, Ruby 1.9.3, and ImageMagick 6.8.3-1. I'm using Ubuntu 12.04 LTS.
I've looked at quite a few similar problems but most seemed to occur a few years ago and were resolved in subsequent updates to Paperclip. None of the solutions I've found in similar posts have worked for me, and unfortunately I just have enough Rails experience yet to know what's going on. I realize I'm probably making a total newbie mistake, in which case I apologize but would still really appreciate some help to get me on the right track.
Please let me know if any additional code or information would be useful for debugging.
Thanks for your time!
Application trace:
cocaine (0.3.2) lib/cocaine/command_line.rb:63:in run'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/helpers.rb:31:in
run'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/geometry_detector_factory.rb:18:in
block in geometry_string' activesupport (3.2.12)
lib/active_support/core_ext/kernel/reporting.rb:43:insilence_stream'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/geometry_detector_factory.rb:17:in
geometry_string'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/geometry_detector_factory.rb:9:in
make'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/geometry.rb:26:in
from_file'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/thumbnail.rb:35:in
initialize'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/processor.rb:33:in
new'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/processor.rb:33:in
make'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:431:in
block in post_process_style'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:430:in
each'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:430:in
inject'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:430:in
post_process_style'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:423:in
block in post_process_styles'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:422:in
each'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:422:in
post_process_styles'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:415:in
block (2 levels) in post_process' activesupport (3.2.12)
lib/active_support/callbacks.rb:403:in
_run__3384881169595487878__image_post_process__96086910066492375__callbacks'
activesupport (3.2.12) lib/active_support/callbacks.rb:405:in
__run_callback' activesupport (3.2.12)
lib/active_support/callbacks.rb:385:in
_run_image_post_process_callbacks' activesupport (3.2.12)
lib/active_support/callbacks.rb:81:inrun_callbacks'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/callbacks.rb:26:in
run_paperclip_callbacks'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:414:in
block in post_process' activesupport (3.2.12)
lib/active_support/callbacks.rb:403:in
_run__3384881169595487878__post_process__96086910066492375__callbacks' activesupport (3.2.12) lib/active_support/callbacks.rb:405:in
__run_callback' activesupport (3.2.12)
lib/active_support/callbacks.rb:385:in _run_post_process_callbacks'
activesupport (3.2.12) lib/active_support/callbacks.rb:81:in
run_callbacks'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/callbacks.rb:26:in
run_paperclip_callbacks'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:413:in
post_process'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip/attachment.rb:108:in
assign'
/home/user/.rvm/gems/ruby-1.9.3-p385/bundler/gems/paperclip-dcd2774e7913/lib/paperclip.rb:200:inblock in has_attached_file' activerecord (3.2.12)
lib/active_record/attribute_assignment.rb:85:in block in
assign_attributes' activerecord (3.2.12)
lib/active_record/attribute_assignment.rb:78:ineach' activerecord
(3.2.12) lib/active_record/attribute_assignment.rb:78:in
assign_attributes' activerecord (3.2.12)
lib/active_record/base.rb:497:ininitialize' activerecord (3.2.12)
lib/active_record/persistence.rb:44:in new' activerecord (3.2.12)
lib/active_record/persistence.rb:44:increate'
app/controllers/events_controller.rb:43:in create' actionpack
(3.2.12) lib/action_controller/metal/implicit_render.rb:4:in
send_action' actionpack (3.2.12)
lib/abstract_controller/base.rb:167:in process_action' actionpack
(3.2.12) lib/action_controller/metal/rendering.rb:10:in
process_action' actionpack (3.2.12)
lib/abstract_controller/callbacks.rb:18:in block in process_action'
activesupport (3.2.12) lib/active_support/callbacks.rb:414:in
run_3332570171411252513__process_action_3320642634939127128_callbacks' activesupport (3.2.12) lib/active_support/callbacks.rb:405:in
__run_callback' activesupport (3.2.12)
lib/active_support/callbacks.rb:385:in_run_process_action_callbacks'
activesupport (3.2.12) lib/active_support/callbacks.rb:81:in
run_callbacks' actionpack (3.2.12)
lib/abstract_controller/callbacks.rb:17:inprocess_action' actionpack
(3.2.12) lib/action_controller/metal/rescue.rb:29:in process_action'
actionpack (3.2.12)
lib/action_controller/metal/instrumentation.rb:30:inblock in
process_action' activesupport (3.2.12)
lib/active_support/notifications.rb:123:in block in instrument'
activesupport (3.2.12)
lib/active_support/notifications/instrumenter.rb:20:ininstrument'
activesupport (3.2.12) lib/active_support/notifications.rb:123:in
instrument' actionpack (3.2.12)
lib/action_controller/metal/instrumentation.rb:29:inprocess_action'
actionpack (3.2.12)
lib/action_controller/metal/params_wrapper.rb:207:in process_action'
activerecord (3.2.12)
lib/active_record/railties/controller_runtime.rb:18:in
process_action' actionpack (3.2.12)
lib/abstract_controller/base.rb:121:in process' actionpack (3.2.12)
lib/abstract_controller/rendering.rb:45:inprocess' actionpack
(3.2.12) lib/action_controller/metal.rb:203:in dispatch' actionpack
(3.2.12) lib/action_controller/metal/rack_delegation.rb:14:in
dispatch' actionpack (3.2.12) lib/action_controller/metal.rb:246:in
block in action' actionpack (3.2.12)
lib/action_dispatch/routing/route_set.rb:73:incall' actionpack
(3.2.12) lib/action_dispatch/routing/route_set.rb:73:in dispatch'
actionpack (3.2.12) lib/action_dispatch/routing/route_set.rb:36:in
call' journey (1.0.4) lib/journey/router.rb:68:in block in call'
journey (1.0.4) lib/journey/router.rb:56:ineach' journey (1.0.4)
lib/journey/router.rb:56:in call' actionpack (3.2.12)
lib/action_dispatch/routing/route_set.rb:601:incall' actionpack
(3.2.12)
lib/action_dispatch/middleware/best_standards_support.rb:17:in call'
rack (1.4.5) lib/rack/etag.rb:23:incall' rack (1.4.5)
lib/rack/conditionalget.rb:35:in call' actionpack (3.2.12)
lib/action_dispatch/middleware/head.rb:14:incall' actionpack
(3.2.12) lib/action_dispatch/middleware/params_parser.rb:21:in call'
actionpack (3.2.12) lib/action_dispatch/middleware/flash.rb:242:in
call' rack (1.4.5) lib/rack/session/abstract/id.rb:210:in context'
rack (1.4.5) lib/rack/session/abstract/id.rb:205:incall' actionpack
(3.2.12) lib/action_dispatch/middleware/cookies.rb:341:in call'
activerecord (3.2.12) lib/active_record/query_cache.rb:64:incall'
activerecord (3.2.12)
lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in
call' actionpack (3.2.12)
lib/action_dispatch/middleware/callbacks.rb:28:inblock in call'
activesupport (3.2.12) lib/active_support/callbacks.rb:405:in
_run__1281245379307539657__call__96086910066492375__callbacks'
activesupport (3.2.12) lib/active_support/callbacks.rb:405:in
__run_callback' activesupport (3.2.12)
lib/active_support/callbacks.rb:385:in _run_call_callbacks'
activesupport (3.2.12) lib/active_support/callbacks.rb:81:in
run_callbacks' actionpack (3.2.12)
lib/action_dispatch/middleware/callbacks.rb:27:in call' actionpack
(3.2.12) lib/action_dispatch/middleware/reloader.rb:65:incall'
actionpack (3.2.12) lib/action_dispatch/middleware/remote_ip.rb:31:in
call' actionpack (3.2.12)
lib/action_dispatch/middleware/debug_exceptions.rb:16:incall'
actionpack (3.2.12)
lib/action_dispatch/middleware/show_exceptions.rb:56:in call'
railties (3.2.12) lib/rails/rack/logger.rb:32:incall_app' railties
(3.2.12) lib/rails/rack/logger.rb:16:in block in call' activesupport
(3.2.12) lib/active_support/tagged_logging.rb:22:intagged' railties
(3.2.12) lib/rails/rack/logger.rb:16:in call' actionpack (3.2.12)
lib/action_dispatch/middleware/request_id.rb:22:incall' rack (1.4.5)
lib/rack/methodoverride.rb:21:in call' rack (1.4.5)
lib/rack/runtime.rb:17:incall' activesupport (3.2.12)
lib/active_support/cache/strategy/local_cache.rb:72:in call' rack
(1.4.5) lib/rack/lock.rb:15:incall' actionpack (3.2.12)
lib/action_dispatch/middleware/static.rb:62:in call' railties
(3.2.12) lib/rails/engine.rb:479:incall' railties (3.2.12)
lib/rails/application.rb:223:in call' rack (1.4.5)
lib/rack/content_length.rb:14:incall' railties (3.2.12)
lib/rails/rack/log_tailer.rb:17:in call' rack (1.4.5)
lib/rack/handler/webrick.rb:59:inservice'
/home/user/.rvm/rubies/ruby-1.9.3-p385/lib/ruby/1.9.1/webrick/httpserver.rb:138:in
service'
/home/user/.rvm/rubies/ruby-1.9.3-p385/lib/ruby/1.9.1/webrick/httpserver.rb:94:in
run'
/home/user/.rvm/rubies/ruby-1.9.3-p385/lib/ruby/1.9.1/webrick/server.rb:191:in
`block in start_thread'
You are using the wrong version of cocaine. Run bundle install then make sure you are using bundle exec rails s to start your rails server.
The run method in the newer version of cocaine (~> 0.4.0) takes an optional argument (def run(interpolations = {})) that the older version (0.3.2) didn't.
See comments above.

Resources