I just upgrade to ruby 2.3 in order to take benefits of the frozen_string_literal option but it produce me the error Errno::EMFILE: Too many open files in production.
When I downgrade to ruby 2.2.3, no more errors.
Here is one of the ruby 2.3 error calltrace I have :
Errno::EMFILE: Too many open files - socket(2) for "XX.XXX.XX.XXX" port 9200 (XX.XXX.XX.XXX:9200)
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient/session.rb:597:in `initialize'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient/session.rb:597:in `new'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient/session.rb:597:in `create_socket'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient/session.rb:742:in `block in connect'
/.../.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/timeout.rb:91:in `block in timeout'
/.../.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/timeout.rb:101:in `timeout'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient/session.rb:735:in `connect'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient/session.rb:497:in `query'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient/session.rb:170:in `query'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient.rb:1238:in `do_get_block'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient.rb:1021:in `block in do_request'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient.rb:1129:in `protect_keep_alive_disconnected'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient.rb:1016:in `do_request'
/.../production/shared/bundle/ruby/2.3.0/gems/httpclient-2.7.1/lib/httpclient.rb:858:in `request'
/.../production/shared/bundle/ruby/2.3.0/gems/faraday-0.9.2/lib/faraday/adapter/httpclient.rb:36:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/faraday-0.9.2/lib/faraday/rack_builder.rb:139:in `build_response'
/.../production/shared/bundle/ruby/2.3.0/gems/faraday-0.9.2/lib/faraday/connection.rb:377:in `run_request'
/.../production/shared/bundle/ruby/2.3.0/bundler/gems/elasticsearch-ruby-a5ed3f6aa679/elasticsearch-transport/lib/elasticsearch/transport/transport/http/faraday.rb:21:in `block in perform_request'
/.../production/shared/bundle/ruby/2.3.0/bundler/gems/elasticsearch-ruby-a5ed3f6aa679/elasticsearch-transport/lib/elasticsearch/transport/transport/base.rb:201:in `perform_request'
/.../production/shared/bundle/ruby/2.3.0/bundler/gems/elasticsearch-ruby-a5ed3f6aa679/elasticsearch-transport/lib/elasticsearch/transport/transport/http/faraday.rb:20:in `perform_request'
/.../production/shared/bundle/ruby/2.3.0/bundler/gems/elasticsearch-ruby-a5ed3f6aa679/elasticsearch-transport/lib/elasticsearch/transport/client.rb:125:in `perform_request'
/.../production/shared/bundle/ruby/2.3.0/bundler/gems/elasticsearch-ruby-a5ed3f6aa679/elasticsearch-api/lib/elasticsearch/api/actions/index.rb:99:in `index'
/.../production/shared/bundle/ruby/2.3.0/bundler/gems/elasticsearch-rails-489ab24998a8/elasticsearch-model/lib/elasticsearch/model/indexing.rb:336:in `index_document'
/.../production/releases/20160128001123/app/models/concerns/elastic_search/searchable.rb:12:in `block (3 levels) in '
/.../production/releases/20160128001123/app/jobs/elasticsearch_job.rb:9:in `perform'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/execution.rb:32:in `block in perform_now'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:117:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:555:in `block (2 levels) in compile'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in `block (2 levels) in around'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:343:in `block (2 levels) in simple'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:441:in `instance_exec'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:441:in `block in make_lambda'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:342:in `block in simple'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in `block in around'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in `block (2 levels) in around'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:343:in `block (2 levels) in simple'
/.../production/shared/bundle/ruby/2.3.0/gems/i18n-0.7.0/lib/i18n.rb:257:in `with_locale'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/translation.rb:7:in `block (2 levels) in '
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:441:in `instance_exec'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:441:in `block in make_lambda'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:342:in `block in simple'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in `block in around'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in `block (2 levels) in around'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:343:in `block (2 levels) in simple'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/logging.rb:23:in `block (4 levels) in '
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:in `block in instrument'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:in `instrument'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/logging.rb:22:in `block (3 levels) in '
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/logging.rb:43:in `block in tag_logger'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/tagged_logging.rb:68:in `block in tagged'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/tagged_logging.rb:26:in `tagged'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/tagged_logging.rb:68:in `tagged'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/logging.rb:43:in `tag_logger'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/logging.rb:19:in `block (2 levels) in '
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:441:in `instance_exec'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:441:in `block in make_lambda'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:342:in `block in simple'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in `block in around'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:92:in `__run_callbacks__'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in `_run_perform_callbacks'
/.../production/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:81:in `run_callbacks'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/execution.rb:31:in `perform_now'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/execution.rb:21:in `execute'
/.../production/shared/bundle/ruby/2.3.0/gems/activejob-4.2.5.1/lib/active_job/queue_adapters/sidekiq_adapter.rb:42:in `perform'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/processor.rb:80:in `execute_job'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/processor.rb:56:in `block (2 levels) in process'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/chain.rb:127:in `block in invoke'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/chain.rb:129:in `block in invoke'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/server/active_record.rb:6:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/chain.rb:129:in `block in invoke'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/server/retry_jobs.rb:74:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/chain.rb:129:in `block in invoke'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-failures-0.4.5/lib/sidekiq/failures/middleware.rb:9:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/chain.rb:129:in `block in invoke'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/server/logging.rb:11:in `block in call'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/logging.rb:30:in `with_context'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/server/logging.rb:7:in `call'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/chain.rb:129:in `block in invoke'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/middleware/chain.rb:132:in `invoke'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/processor.rb:51:in `block in process'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/processor.rb:104:in `stats'
/.../production/shared/bundle/ruby/2.3.0/gems/sidekiq-3.5.4/lib/sidekiq/processor.rb:50:in `process'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/calls.rb:28:in `public_send'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/calls.rb:28:in `dispatch'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/call/async.rb:7:in `dispatch'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/cell.rb:50:in `block in dispatch'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/cell.rb:76:in `block in task'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/actor.rb:339:in `block in task'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/task.rb:44:in `block in initialize'
/.../production/shared/bundle/ruby/2.3.0/gems/celluloid-0.17.3/lib/celluloid/task/fibered.rb:14:in `block in create'
I did not find someone with this concern on the ruby bug tracker nor on stackoverflow and the ruby 2.3 is recent (<2 months).
How can I deal with this?
Related
I am using delayed jobs and I think I have a problem with serialization. We are using ruby 2.2.2.
In my model I have a callback that fires on save and creates a delayed job for my model. like this:
after_create :update_queue
def update_queue
self.class.delay(run_at: 1.minutes.from_now, delayed_reference_id: self.id, delayed_reference_type: "Payment", queue: "qbo_payments").delayed_task(self.id)
end
def self.delayed_task
# Do some stuff
end
However I am getting the error:
undefined method `delayed_task' for #<Class:0x0000000f93f9b8>
~/shared/bundle/ruby/2.2.0/gems/activerecord-4.2.0/lib/active_record/dynamic_matchers.rb:26:in `method_missing'
~/shared/bundle/ruby/2.2.0/gems/attr_encrypted-3.0.3/lib/attr_encrypted.rb:295:in `method_missing'
~/shared/bundle/ruby/2.2.0/gems/attr_encrypted-3.0.3/lib/attr_encrypted/adapters/active_record.rb:129:in `method_missing_with_attr_encrypted'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/performable_method.rb:26:in `perform'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/backend/base.rb:84:in `block in invoke_job'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `block in initialize'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `execute'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:40:in `run_callbacks'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/backend/base.rb:81:in `invoke_job'
~/shared/bundle/ruby/2.2.0/gems/newrelic_rpm-3.16.0.318/lib/new_relic/agent/instrumentation/delayed_job_instrumentation.rb:127:in `block in invoke_job'
~/shared/bundle/ruby/2.2.0/gems/newrelic_rpm-3.16.0.318/lib/new_relic/agent/instrumentation/controller_instrumentation.rb:363:in `perform_action_with_newrelic_trace'
~/shared/bundle/ruby/2.2.0/gems/newrelic_rpm-3.16.0.318/lib/new_relic/agent/instrumentation/delayed_job_instrumentation.rb:126:in `invoke_job'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:230:in `block (2 levels) in run'
/usr/local/rvm/rubies/ruby-2.2.2/lib/ruby/2.2.0/timeout.rb:89:in `block in timeout'
/usr/local/rvm/rubies/ruby-2.2.2/lib/ruby/2.2.0/timeout.rb:99:in `call'
/usr/local/rvm/rubies/ruby-2.2.2/lib/ruby/2.2.0/timeout.rb:99:in `timeout'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:230:in `block in run'
/usr/local/rvm/rubies/ruby-2.2.2/lib/ruby/2.2.0/benchmark.rb:303:in `realtime'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:229:in `run'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:306:in `block in reserve_and_run_one_job'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `block in initialize'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `execute'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:40:in `run_callbacks'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:306:in `reserve_and_run_one_job'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:213:in `block in work_off'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:212:in `times'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:212:in `work_off'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:175:in `block (4 levels) in start'
/usr/local/rvm/rubies/ruby-2.2.2/lib/ruby/2.2.0/benchmark.rb:303:in `realtime'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:174:in `block (3 levels) in start'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `block in initialize'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `execute'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:40:in `run_callbacks'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:173:in `block (2 levels) in start'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:172:in `loop'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:172:in `block in start'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/plugins/clear_locks.rb:7:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/plugins/clear_locks.rb:7:in `block (2 levels) in <class:ClearLocks>'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:79:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:79:in `block (2 levels) in add'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:61:in `block in initialize'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:79:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:79:in `block in add'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `call'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:66:in `execute'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/lifecycle.rb:40:in `run_callbacks'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/worker.rb:171:in `start'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/command.rb:132:in `run'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/command.rb:120:in `block in run_process'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/application.rb:265:in `call'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/application.rb:265:in `block in start_proc'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/daemonize.rb:84:in `call'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/daemonize.rb:84:in `call_as_daemon'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/application.rb:269:in `start_proc'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/application.rb:295:in `start'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/controller.rb:69:in `run'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons.rb:193:in `block in run_proc'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/cmdline.rb:88:in `call'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons/cmdline.rb:88:in `catch_exceptions'
~/shared/bundle/ruby/2.2.0/gems/daemons-1.2.3/lib/daemons.rb:192:in `run_proc'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/command.rb:118:in `run_process'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/command.rb:99:in `block in daemonize'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/command.rb:97:in `times'
~/shared/bundle/ruby/2.2.0/gems/delayed_job-4.1.2/lib/delayed/command.rb:97:in `daemonize'
script/delayed_job:5:in `<main>'"
What I have tried
After a bit of google research I found 2 fixes. The first and more widely accepted fix is to add:
require 'yaml'
YAML::ENGINE.yamler = 'syck'
#https://github.com/collectiveidea/delayed_job/issues/199
However, syck is no longer supported for ruby 2.2.2
The second solution, which only seemed to exacerbate the problem, was to add "bundle exec" to my delayed_job startup script like this:
run "cd #{current_path}; bundle exec script/delayed_job start #{rails_env}"
This will work !
after_create :update_queue
def update_queue
self.delay(run_at: 1.minutes.from_now, delayed_reference_id: self.id, delayed_reference_type: "Payment", queue: "qbo_payments").delayed_task()
end
def delayed_task
self.class.delayed_task(self.id)
end
def self.delayed_task
# Do some stuff
end
I'm new to Ruby, therefore, not much familiar with the syntaxes -
I want a Ruby code for the following curl request -
curl -X POST http://<auth_server_endpoint>/oauth/token -d "grant_type
=client_credentials" -H"Authorization: Basic encode64Of(clientid:secret)"
After following the link -
How to invoke HTTP POST method over SSL in ruby?
I've written a function to get the response -
def getToken(client_id, secret)
encodedId = Base64.encode64(client_id+":"+secret)
uri = URI.parse("auth_server_endpoint")
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_NONE
request = Net::HTTP::Post.new("/oauth/token")
request.add_field('Content-Type', 'application/json')
request.add_field('Authorization', "Basic #{encodedId}")
//FAILS BELOW
response = http.request(request, {'grant_type' => 'client_credentials'})
parsed_json = JSON.parse(response)
self.access_token = parsed_json.fetch("access_token")
self.expires_in = parsed_json.fetch("expires_in")
end
I'm not able to figure out the error. Kindly suggest the changes I need to make.
ERROR LOG -
OpenSSL::SSL::SSLError - SSL_connect returned=1 errno=0 state=SSLv2/v3 read server hello A: unknown protocol:
/netdir/http.rb:920:in `connect'
/netdir/http.rb:920:in `block in connect'
/rubydir/2.1.0/timeout.rb:76:in `timeout'
/netdir/http.rb:920:in `connect'
/netdir/http.rb:863:in `do_start'
/netdir/http.rb:852:in `start'
/netdir/http.rb:1369:in `request'
/rubydir/gems/2.1.0/gems/rest-client-1.6.7/lib/restclient/net_http_ext.rb:51:in `request'
/appdir/lib/sc_customer/auth_token.rb:30:in `getToken'
/appdir/controllers/payment_controller.rb:276:in `block (2 levels) in <module:API>'
/rubydir/gems/2.1.0/gems/rack-metrics-0.0.27/lib/probes/sinatra_probe.rb:24:in `call'
/rubydir/gems/2.1.0/gems/rack-metrics-0.0.27/lib/probes/sinatra_probe.rb:24:in `block in bind'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:569:in `call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:569:in `block in route'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `[]'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `block (3 levels) in process_destination_path'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:851:in `route_eval'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `block (2 levels) in process_destination_path'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `catch'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `block in process_destination_path'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:25:in `instance_eval'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:25:in `process_destination_path'
(eval):16:in `block (2 levels) in inject_root_methods'
(eval):6:in `catch'
(eval):6:in `block in inject_root_methods'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router/node/root.rb:554:in `[]'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router/node/root.rb:13:in `[]'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router.rb:119:in `block in call'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router.rb:119:in `catch'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router.rb:119:in `call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:910:in `route!'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:900:in `dispatch!'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:769:in `block in call!'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:921:in `block in invoke'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:921:in `catch'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:921:in `invoke'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:769:in `call!'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:755:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/logger.rb:15:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/session/abstract/id.rb:195:in `context'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/session/abstract/id.rb:190:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/head.rb:9:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/methodoverride.rb:24:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/sc_core/logger.rb:58:in `call'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:1389:in `block in call'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:1471:in `synchronize'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:1389:in `call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/router.rb:83:in `block in call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/router.rb:76:in `each'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/router.rb:76:in `call'
/rubydir/gems/2.1.0/gems/sc-mq-0.0.86/lib/sc_mq/rack/filter.rb:24:in `call'
/appdir/lib/rack/bu_aware_request_handler.rb:32:in `block in call'
/rubydir/gems/2.1.0/gems/activerecord_use_slave-0.0.5/lib/activerecord_use_slave.rb:44:in `using_connection'
/appdir/lib/rack/bu_aware_request_handler.rb:31:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/connection_release.rb:11:in `call'
/rubydir/gems/2.1.0/gems/rack-metrics-0.0.27/lib/rack-metrics/rack.rb:11:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/serial_initializer.rb:49:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/log_exceptions.rb:11:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/transaction_tracer.rb:23:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/sc_core/rack/filter.rb:14:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/lint.rb:48:in `_call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/lint.rb:36:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/showexceptions.rb:24:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/commonlogger.rb:20:in `call'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:136:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/chunked.rb:41:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/content_length.rb:14:in `call'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:552:in `process_client'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:632:in `worker_loop'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:500:in `spawn_missing_workers'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:142:in `start'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/bin/unicorn:126:in `<top (required)>'
/b2cdir/bin/unicorn:16:in `load'
/b2cdir/bin/unicorn:16:in `<main>'
ERROR -17/May/2016 10:56:42 [payment-b2c TXN-af2c9519-6e89-4fa2-8913-ee164f53523d REQ-28485d83-47a3-47cc-814d-993dc544697a] - OpenSSL::SSL::SSLError - SSL_connect returned=1 errno=0 state=SSLv2/v3 read server hello A: unknown protocol:
/netdir/http.rb:920:in `connect'
/netdir/http.rb:920:in `block in connect'
/rubydir/2.1.0/timeout.rb:76:in `timeout'
/netdir/http.rb:920:in `connect'
/netdir/http.rb:863:in `do_start'
/netdir/http.rb:852:in `start'
/netdir/http.rb:1369:in `request'
/rubydir/gems/2.1.0/gems/rest-client-1.6.7/lib/restclient/net_http_ext.rb:51:in `request'
/appdir/lib/sc_customer/auth_token.rb:30:in `getToken'
/appdir/controllers/payment_controller.rb:276:in `block (2 levels) in <module:API>'
/rubydir/gems/2.1.0/gems/rack-metrics-0.0.27/lib/probes/sinatra_probe.rb:24:in `call'
/rubydir/gems/2.1.0/gems/rack-metrics-0.0.27/lib/probes/sinatra_probe.rb:24:in `block in bind'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:569:in `call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:569:in `block in route'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `[]'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `block (3 levels) in process_destination_path'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:851:in `route_eval'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `block (2 levels) in process_destination_path'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `catch'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:51:in `block in process_destination_path'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:25:in `instance_eval'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:25:in `process_destination_path'
(eval):16:in `block (2 levels) in inject_root_methods'
(eval):6:in `catch'
(eval):6:in `block in inject_root_methods'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router/node/root.rb:554:in `[]'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router/node/root.rb:13:in `[]'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router.rb:119:in `block in call'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router.rb:119:in `catch'
/rubydir/gems/2.1.0/gems/http_router-0.10.2/lib/http_router.rb:119:in `call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:910:in `route!'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/application/routing.rb:900:in `dispatch!'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:769:in `block in call!'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:921:in `block in invoke'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:921:in `catch'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:921:in `invoke'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:769:in `call!'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:755:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/logger.rb:15:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/session/abstract/id.rb:195:in `context'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/session/abstract/id.rb:190:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/head.rb:9:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/methodoverride.rb:24:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/sc_core/logger.rb:58:in `call'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:1389:in `block in call'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:1471:in `synchronize'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:1389:in `call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/router.rb:83:in `block in call'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/router.rb:76:in `each'
/rubydir/gems/2.1.0/gems/padrino-core-0.10.5.patched/lib/padrino-core/router.rb:76:in `call'
/rubydir/gems/2.1.0/gems/sc-mq-0.0.86/lib/sc_mq/rack/filter.rb:24:in `call'
/appdir/lib/rack/bu_aware_request_handler.rb:32:in `block in call'
/rubydir/gems/2.1.0/gems/activerecord_use_slave-0.0.5/lib/activerecord_use_slave.rb:44:in `using_connection'
/appdir/lib/rack/bu_aware_request_handler.rb:31:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/connection_release.rb:11:in `call'
/rubydir/gems/2.1.0/gems/rack-metrics-0.0.27/lib/rack-metrics/rack.rb:11:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/serial_initializer.rb:49:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/log_exceptions.rb:11:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/rack/transaction_tracer.rb:23:in `call'
/rubydir/gems/2.1.0/gems/sc-core-1.1.36/lib/sc_core/rack/filter.rb:14:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/lint.rb:48:in `_call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/lint.rb:36:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/showexceptions.rb:24:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/commonlogger.rb:20:in `call'
/rubydir/gems/2.1.0/gems/sinatra-1.3.3/lib/sinatra/base.rb:136:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/chunked.rb:41:in `call'
/rubydir/gems/2.1.0/gems/rack-1.3.6/lib/rack/content_length.rb:14:in `call'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:552:in `process_client'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:632:in `worker_loop'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:500:in `spawn_missing_workers'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/lib/unicorn/http_server.rb:142:in `start'
/rubydir/gems/2.1.0/gems/unicorn-4.6.3/bin/unicorn:126:in `<top (required)>'
/b2cdir/bin/unicorn:16:in `load'
/b2cdir/bin/unicorn:16:in `<main>'
DEBUG -17/May/2016 10:56:42 [payment-b2c TXN-af2c9519-6e89-4fa2-8913-ee164f53523d REQ-28485d83-47a3-47cc-814d-993dc544697a] - POST [1.085s DB: 0.009s ( 0.8%) 7 queries] /payments - 500 Internal Server Error
Bellow are some parts of my code:
class VizApp < Sinatra::Base
get '/rubygems' do
#process_downloads_days = HTTParty.get('http://localhost:4567/api/v1/rubygems/version_downloads_days_process', timeout: 180)
#version_downloads = HTTParty.get('http://localhost:4567/api/v1/rubygems/version_downloads')
#version_downloads_days = HTTParty.get('http://localhost:4567/api/v1/rubygems/version_downloads_days')
#version_downloads_stack = HTTParty.get('http://localhost:4567/api/v1/rubygems/version_downloads_stack')
#version_downloads_nest_drilldown = HTTParty.get('http://localhost:4567/api/v1/rubygems/version_downloads_nest')
erb :rubygems
end
What I do is calling the api that I wrote in the same project. When I using WEBrick as my web server, everything goes ok. However, when I change the web server to Thin, I get following error:
Net::ReadTimeout - Net::ReadTimeout: /Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/protocol.rb:158:in `rescue in rbuf_fill'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/protocol.rb:152:in `rbuf_fill'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/protocol.rb:134:in `readuntil'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/protocol.rb:144:in `readline'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http/response.rb:39:in `read_status_line'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http/response.rb:28:in `read_new'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http.rb:1423:in `block in transport_request'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http.rb:1420:in `catch'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http.rb:1420:in `transport_request'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http.rb:1393:in `request'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http.rb:1386:in `block in request'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http.rb:853:in `start'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/2.3.0/net/http.rb:1384:in `request'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/httparty-0.13.7/lib/httparty/request.rb:117:in `perform'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/httparty-0.13.7/lib/httparty.rb:545:in `perform_request'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/httparty-0.13.7/lib/httparty.rb:476:in `get'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/httparty-0.13.7/lib/httparty.rb:583:in `get'
/Users/chenlizhan/Desktop/Lee/Projects/repo-miner/visualization/app.rb:39:in `block in <class:VizApp>'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1610:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1610:in `block in compile!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:974:in `[]'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:974:in `block (3 levels) in route!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:993:in `route_eval'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:974:in `block (2 levels) in route!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1014:in `block in process_route'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1012:in `catch'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1012:in `process_route'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:972:in `block in route!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:971:in `each'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:971:in `route!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1084:in `block in dispatch!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1066:in `block in invoke'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1066:in `catch'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1066:in `invoke'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1081:in `dispatch!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:906:in `block in call!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1066:in `block in invoke'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1066:in `catch'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1066:in `invoke'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:906:in `call!'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:894:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-protection-1.5.3/lib/rack/protection/xss_header.rb:18:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-protection-1.5.3/lib/rack/protection/path_traversal.rb:16:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-protection-1.5.3/lib/rack/protection/json_csrf.rb:18:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-protection-1.5.3/lib/rack/protection/frame_options.rb:31:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/nulllogger.rb:9:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/head.rb:13:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/show_exceptions.rb:21:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:181:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:2021:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1486:in `block in call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1795:in `synchronize'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:1486:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/tempfile_reaper.rb:15:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/lint.rb:49:in `_call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/lint.rb:37:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/showexceptions.rb:24:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/commonlogger.rb:33:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/sinatra-1.4.6/lib/sinatra/base.rb:218:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/chunked.rb:54:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/content_length.rb:15:in `call'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/thin-1.6.3/lib/thin/connection.rb:86:in `block in pre_process'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/thin-1.6.3/lib/thin/connection.rb:84:in `catch'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/thin-1.6.3/lib/thin/connection.rb:84:in `pre_process'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/thin-1.6.3/lib/thin/connection.rb:53:in `process'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/thin-1.6.3/lib/thin/connection.rb:39:in `receive_data'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/eventmachine-1.0.7/lib/eventmachine.rb:187:in `run_machine'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/eventmachine-1.0.7/lib/eventmachine.rb:187:in `run'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/thin-1.6.3/lib/thin/backends/base.rb:73:in `start'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/thin-1.6.3/lib/thin/server.rb:162:in `start'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/handler/thin.rb:19:in `run'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/server.rb:286:in `start'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/lib/rack/server.rb:147:in `start'
/Users/chenlizhan/.rvm/rubies/ruby-head/lib/ruby/gems/2.3.0/gems/rack-1.6.4/bin/rackup:4:in `<top (required)>'
/Users/chenlizhan/.rvm/gems/ruby-head/bin/rackup:23:in `load'
/Users/chenlizhan/.rvm/gems/ruby-head/bin/rackup:23:in `<main>'
/Users/chenlizhan/.rvm/gems/ruby-head/bin/ruby_executable_hooks:15:in `eval'
/Users/chenlizhan/.rvm/gems/ruby-head/bin/ruby_executable_hooks:15:in `<main>'
Anyone has the similar problems as me? Please give me a help, thanks!
I would create a thin.yml file within /config and then set timeout: 90 or play around with a value that you find best.
You can then specify the config file when you execute thin via thin -C config/thin.yml
I'm trying to update font-awesome to last release using .scss.
When i try to compile using campass it throws this error:
>>> Change detected at 17:51:13 to: ui/_font_awesome.scss
NoMethodError on line ["323"] of /usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb: undefined method `perform' for nil:NilClass
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:321:in `map'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:321:in `run_interp_no_strip'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:331:in `run_interp'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:295:in `visit_directive'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:37:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:20:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:146:in `block in visit_import'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:146:in `map'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:146:in `visit_import'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:37:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:20:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:146:in `block in visit_import'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:146:in `map'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:146:in `visit_import'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:37:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:20:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:53:in `block in visit_children'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:53:in `map'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:53:in `visit_children'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:29:in `block in visit_children'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:41:in `with_environment'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:28:in `visit_children'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:37:in `block in visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:49:in `visit_root'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/base.rb:37:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:20:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/visitors/perform.rb:7:in `visit'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/tree/root_node.rb:20:in `render'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/engine.rb:305:in `_render'
/usr/local/lib/ruby/gems/1.9.1/gems/sass-3.2.0.alpha.64/lib/sass/engine.rb:252:in `render'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:140:in `block (2 levels) in compile'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:126:in `timed'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:139:in `block in compile'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/logger.rb:45:in `red'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:138:in `compile'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:118:in `compile_if_required'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:103:in `block (2 levels) in run'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:101:in `each'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:101:in `block in run'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:126:in `timed'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/compiler.rb:100:in `run'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/commands/watch_project.rb:147:in `recompile'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/path.rb:73:in `call'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/path.rb:73:in `run_callback'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/path.rb:55:in `callback_action'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/path.rb:35:in `update'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/state/directory.rb:39:in `block in modified'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/state/directory.rb:37:in `each'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/state/directory.rb:37:in `modified'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/state/directory.rb:18:in `refresh'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/backends/inotify.rb:12:in `block in add_handler'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/notifier.rb:200:in `call'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/notifier.rb:200:in `block in watch'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/watcher.rb:41:in `[]'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/watcher.rb:41:in `callback!'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/event.rb:128:in `callback!'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/notifier.rb:233:in `block in process'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/notifier.rb:233:in `each'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/notifier.rb:233:in `process'
/usr/local/lib/ruby/gems/1.9.1/gems/rb-inotify-0.8.8/lib/rb-inotify/notifier.rb:216:in `run'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/backends/inotify.rb:20:in `run'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm/monitor.rb:26:in `run'
/usr/local/lib/ruby/gems/1.9.1/gems/fssm-0.2.8.1/lib/fssm.rb:70:in `monitor'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/commands/watch_project.rb:87:in `perform'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/commands/base.rb:18:in `execute'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/commands/project_base.rb:19:in `execute'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/exec/sub_command_ui.rb:43:in `perform!'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/lib/compass/exec/sub_command_ui.rb:15:in `run!'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/bin/compass:29:in `block in <top (required)>'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/bin/compass:43:in `call'
/usr/local/lib/ruby/gems/1.9.1/gems/compass-0.12.1/bin/compass:43:in `<top (required)>'
/usr/local/bin/compass:19:in `load'
/usr/local/bin/compass:19:in `<main>'
I've spent all afternoon searching to find someone with same problem but didn't find anything...
Any guess about what could be the problem?
Ty!
Check any directives you have added to your sass files recently (#include, #import, #extend) and verify that there are no typos.
You may get this error when sass tries to execute a directive it does not recognize.
eg. say you typed #includ when you meant #include
I'm trying to upgrade my app to Mongoid 3 and ruby 1.9.3. I was on 1.9.2 before. My app also uses Redis as a temp data store. No code changes have occurred and this was working fine before... now I'm getting the following error when I run the task that connects to Redis:
Can't assign requested address - connect(2)
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/connection/ruby.rb:113:in `connect_nonblock'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/connection/ruby.rb:113:in `connect'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/connection/ruby.rb:170:in `connect'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/client.rb:257:in `establish_connection'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/client.rb:63:in `connect'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/client.rb:276:in `ensure_connected'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/client.rb:167:in `block in process'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/client.rb:242:in `logging'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/client.rb:166:in `process'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis/client.rb:78:in `call'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis.rb:912:in `block in rpop'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis.rb:36:in `block in synchronize'
/Users/kevin/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis.rb:36:in `synchronize'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/redis-3.0.1/lib/redis.rb:911:in `rpop'
/Users/kevin/myapp/app/models/tweet.rb:34:in `block (3 levels) in load_from'
/Users/kevin/myapp/app/models/tweet.rb:33:in `times'
/Users/kevin/myapp/app/models/tweet.rb:33:in `block (2 levels) in load_from'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/eventmachine-1.0.0.rc.4/lib/eventmachine.rb:959:in `call'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/eventmachine-1.0.0.rc.4/lib/eventmachine.rb:959:in `block in run_deferred_callbacks'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/eventmachine-1.0.0.rc.4/lib/eventmachine.rb:956:in `times'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/eventmachine-1.0.0.rc.4/lib/eventmachine.rb:956:in `run_deferred_callbacks'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/eventmachine-1.0.0.rc.4/lib/eventmachine.rb:187:in `run_machine'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/eventmachine-1.0.0.rc.4/lib/eventmachine.rb:187:in `run'
/Users/kevin/myapp/app/models/tweet.rb:30:in `load_from'
/Users/kevin/myapp/lib/tasks/tweet.rake:11:in `block (2 levels) in <top (required)>'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `call'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `block in execute'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `each'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `execute'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:158:in `block in invoke_with_call_chain'
/Users/kevin/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:151:in `invoke_with_call_chain'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/task.rb:144:in `invoke'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:116:in `invoke_task'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block (2 levels) in top_level'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `each'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block in top_level'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:88:in `top_level'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:66:in `block in run'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/lib/rake/application.rb:63:in `run'
/Users/kevin/myapp/.bundle/ruby/1.9.1/gems/rake-0.9.2.2/bin/rake:33:in `<top (required)>'
/Users/kevin/myapp/.bundle/ruby/1.9.1/bin/rake:23:in `load'
/Users/kevin/myapp/.bundle/ruby/1.9.1/bin/rake:23:in `<main>'
Tasks: TOP => tweet:load
My Redis is running and I checked the port #.
Are you using Redis 3.0.1? Try using Redis 2.2.2