delete_all is failing with v1.2.0

miika's Avatar


27 Aug, 2018 09:03 AM

Hi there,

So we are experiencing the same problem as described here:

Then again we are tied to:
ruby 2.3.4
rails 5.1.1
gem 'thinking-sphinx' ~> 3.3.0
gem 'flying-sphinx' ~> 1.2.0

Any way to get this patch to v1.2? Or workaround by forking git repo and creating branch with patch?

  1. Support Staff 1 Posted by Pat Allan on 27 Aug, 2018 12:02 PM

    Pat Allan's Avatar

    Hi Miika

    Ideally, I’d recommend upgrading thinking-sphinx to v4.0.0 and flying-sphinx to 2.1.2, because that’s going to be far more reliable with Rails 5.x. The changelogs and release notes are pretty thorough about any potential issues: <> <> <> <>

    Particularly in the case of flying-sphinx, I would expect upgrading to be a pretty simple affair. TS might be a little more complicated depending on how you’re using it.

    The flying-sphinx 1.x releases currently support Rails 2.x-4.x, and nominally 5.x, but as you’ve found out, this only works to a point. The patch supplied in the other conversation you’ve linked to will break Rails 2.x support - which I know is not really a big deal, but I’d rather keep the 1.x releases of flying-sphinx happy with those old Rails versions.

    Certainly, as a workaround you could fork flying-sphinx and apply this commit, and then you’ve got a version that works for you without going through the upgrading: <>

    But from a long-term perspective, upgrading the gems is definitely the better approach if you’ve got the time.

    If you get stuck with any of this, do let me know.



  2. 2 Posted by miika on 27 Aug, 2018 12:46 PM

    miika's Avatar

    Thanks for the quick reply!
    I went with the fork option for now... was stuck for a while (not running "bundle install" locally to generate a new Gemfile.lock before pushing to Heroku). But I think it's working now.

    Off-topic and maybe a dumb question but on Heroku is fs:index and ts:index aliases? Should one prefer one over the other? Thanks again.

  3. Support Staff 3 Posted by Pat Allan on 27 Aug, 2018 12:56 PM

    Pat Allan's Avatar

    It’s not a dumb question at all!

    If you’re using flying-sphinx 1.x or earlier, then you should use `fs:index`. It’s only since v2 that `ts:index` performs as expected no matter where you’re running it. Really, I should have taken this approach from the very beginning, because it’s been a source of confusion for a long time.

    But yes: flying-sphinx < v2: use `fs:index`. flying-sphinx >= v2: use `ts:index`.

  4. 4 Posted by miika on 27 Aug, 2018 01:17 PM

    miika's Avatar

    Wow, thanks for the heads up!
    Really glad I asked :)

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Already uploaded files

  • error.png 13.8 KB

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac