Note that there are some explanatory texts on larger screens.

plurals
  1. POrails3.1.1 and sunspot: Solr Response: Not Found error
    primarykey
    data
    text
    <p>I'm trying to build an application with sunspot_solr and I keep getting this error:</p> <pre><code>rsolr (0.12.1) lib/rsolr/connection/requestable.rb:39:in `request' rsolr (0.12.1) lib/rsolr/client.rb:34:in `request' sunspot (1.2.1) lib/sunspot/search/abstract_search.rb:35:in `execute' sunspot_rails (1.2.1) lib/sunspot/rails/searchable.rb:306:in `solr_execute_search' sunspot_rails (1.2.1) lib/sunspot/rails/searchable.rb:139:in `solr_search' app/controllers/search_controller.rb:7:in `results' </code></pre> <p>Here is my sunspot.yml:</p> <pre><code>solr: hostname: localhost port: 8980 log_level: INFO path: /solr pid_dir: /solr/pids/development auto_commit_after_delete_request: true </code></pre> <p>And the solr instance at <a href="http://localhost:8980/solr/admin/" rel="nofollow">http://localhost:8980/solr/admin/</a> does work, I get all the desired results when I run the queries there. But when I run through my application I get the above error.</p> <p>My configuration: Rails 3.1.1 Sunspot: 1.2.1</p> <p>Please let me know what other information you need from me and thanks in advance for the answers.</p> <p>I went through the logs files and found out this error:</p> <pre><code>DEPRECATION WARNING: class_inheritable_attribute is deprecated, please use class_attribute method instead. Notice their behavior are slightly different, so refer to class_attribute documentation first. (called from &lt;class:User&gt; at /home/romio/hummingtown_v1/app/models/user.rb:17) </code></pre> <p>Here is my user.rb:</p> <pre><code>require 'digest/sha2' class User &lt; ActiveRecord::Base has_many :userauths, :dependent =&gt; :destroy attr_accessor :password attr_accessible :first_name, :last_name, :email, :password, :salt email_regex = /\A[\w+\-.]+@[a-z\d\-.]+\.[a-z]+\z/i validates :first_name, :presence =&gt; true, :length =&gt; { :maximum =&gt; 50 } validates :last_name, :presence =&gt; true, :length =&gt; { :maximum =&gt; 50 } validates :email, :presence =&gt; true, :format =&gt; { :with =&gt; email_regex }, :uniqueness =&gt; { :case_sensitive =&gt; false } searchable :auto_index =&gt; true, :auto_remove =&gt; true do text :first_name, :default_boost =&gt; 2 text :last_name text :email end </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload