ruby-on-railsherokuthinking-sphinx

How to diagnose thinking sphinx failing on Heroku (but succeeding locally)?


On a relatively old Rails app and Heroku Stack (16) trying to run rake ts:rebuild:

rake aborted!
NoMethodError: undefined method `running?' for #<FlyingSphinx::Controller:0x00000005d7ae10>
/app/vendor/bundle/ruby/2.3.0/gems/thinking-sphinx-3.1.4/lib/thinking_sphinx/rake_interface.rb:70:in `stop'
/app/vendor/bundle/ruby/2.3.0/gems/thinking-sphinx-3.1.4/lib/thinking_sphinx/tasks.rb:47:in `block (2 levels) in <top (required)>'
/app/vendor/bundle/ruby/2.3.0/gems/rake-11.2.2/exe/rake:27:in `<top (required)>'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:74:in `load'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:74:in `kernel_load'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/cli/exec.rb:28:in `run'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/cli.rb:463:in `exec'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/cli.rb:27:in `dispatch'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/cli.rb:18:in `start'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/exe/bundle:30:in `block in <top (required)>'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/lib/bundler/friendly_errors.rb:124:in `with_friendly_errors'
/app/vendor/bundle/ruby/2.3.0/gems/bundler-1.17.3/exe/bundle:22:in `<top (required)>'
/app/bin/bundle:3:in `load'
/app/bin/bundle:3:in `<main>'
Tasks: TOP => ts:rebuild => ts:stop
(See full trace by running task with --trace)

Locally rake ts:rebuild succeeds, so any tips on what diagnostic steps to take are appreciated!


Solution

  • I couldn't figure out a good way to debug this, but I upgraded thinking_sphinx (3.1.4 -> 4.4.1) and flying_sphinx (1.2.1 -> 2.2.0) and the error went away!