Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.5 not compatible with thinking-sphinx #143

Open
ledermann opened this issue Mar 9, 2011 · 3 comments
Open

2.5 not compatible with thinking-sphinx #143

ledermann opened this issue Mar 9, 2011 · 3 comments

Comments

@ledermann
Copy link

Since version 2.5 searchlogic can not be used in apps which uses the gem "ts-delayed_delta" from thinking-sphinx, too. On startup, this error message is raised:

Mysql::Error: Table 'myapp.jobs' doesn't exist: SHOW FIELDS FROM `jobs` (ActiveRecord::StatementInvalid)

It seems there is a bug in searchlogic (since 2.5, 2.4.32 is fine) handling AR models using set_table_name like ts-delayed_delta does: https://github.com/freelancing-god/ts-delayed-delta/blob/master/lib/thinking_sphinx/deltas/delayed_delta/job.rb

@ghost
Copy link

ghost commented Mar 9, 2011

I can't reproduce this. set_table_name is working fine for me. Can you tell me what to do to reproduce this? Or better yet, create a failing test that I can fix. Thanks.

@ledermann
Copy link
Author

It seems it's an issue with the ordering of gems in the Gemfile: If searchlogic is the last gem defined, it all works fine. But if searchlogic is defined before ts-delayed-delta, the error occurs.

I can not reproduce it within an simple dummy application, perhaps it only occurs if another gem defines an AR model using set_table_name. You are right, it works fine if a model of the application uses set_table_name.

Sorry, I'm not able to create a failing test.

My environment: RubyGems 1.6.2, Bundler 1.0.10, Rails 2.3.11, Ruby 1.8.7-334, OS X

@moiristo
Copy link

Probably related to the pull request I just sent: https://github.com/freelancing-god/ts-delayed-delta/pull/14

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants