Debug rubymine 8.0 and ruby 2.2.1 - ruby-on-rails

I'm trying to debug my rails application on rubymine 8.0.1 and but when I put a breakpoint it's interrupted with exit code -1.
I use a remote server with vagrant I set in rubymine debug config the host and the port that I use.
My workspace
ruby 2.2.1
rails 4.2
rubymine 8.0.1
vagrant
Gem file
actionmailer (4.2.5, 4.2.0)
actionpack (4.2.5, 4.2.0)
actionview (4.2.5, 4.2.0)
activejob (4.2.5, 4.2.0)
activemodel (4.2.5, 4.2.0)
activerecord (4.2.5, 4.2.0)
activesupport (4.2.5, 4.2.0)
arel (6.0.3)
aws-sdk (2.2.1)
aws-sdk-core (2.2.1)
aws-sdk-resources (2.2.1)
bcrypt (3.1.10)
bigdecimal (1.2.6)
builder (3.2.2)
bundler (1.8.4)
bundler-unload (1.0.2)
capistrano (3.4.0)
capistrano-bundler (1.1.4)
capistrano-rails (1.1.5)
coffee-rails (4.1.0)
coffee-script (2.4.1)
coffee-script-source (1.10.0)
colorize (0.7.7)
debase (0.2.1)
debase-ruby_core_source (0.8.1)
erubis (2.7.0)
execjs (2.6.0)
executable-hooks (1.3.2)
gem-wrappers (1.2.7)
globalid (0.3.6)
i18n (0.7.0)
io-console (0.4.3)
jbuilder (2.3.2)
jmespath (1.1.3)
json (1.8.3, 1.8.1)
libv8 (3.16.14.7 x86_64-linux)
loofah (2.0.3)
mail (2.6.3)
mime-types (2.99, 2.6.2)
mini_portile (0.6.2)
minitest (5.8.3, 5.4.3)
mock_redis (0.15.4)
multi_json (1.11.2)
net-scp (1.2.1)
net-ssh (3.0.1)
nokogiri (1.6.6.4)
power_assert (0.2.2)
psych (2.0.8)
rack (1.6.4)
rack-cors (0.4.0)
rack-test (0.6.3)
rails (4.2.5, 4.2.0)
rails-deprecated_sanitizer (1.0.3)
rails-dom-testing (1.0.7)
rails-html-sanitizer (1.0.2)
railties (4.2.5, 4.2.0)
rake (10.4.2)
rdoc (4.2.0)
redis (2.1.1)
ref (2.0.0)
responders (2.1.0)
ruby-debug-ide (0.6.0)
rubygems-bundler (1.4.4)
rvm (1.11.3.9)
sdoc (0.4.1)
spring (1.4.4)
sprockets (3.4.1, 3.4.0)
sprockets-rails (2.3.3)
sqlite3 (1.3.11)
sshkit (1.7.1)
test-unit (3.0.8)
therubyracer (0.12.2)
thor (0.19.1)
thread_safe (0.3.5)
turbolinks (2.5.3)
tzinfo (1.2.2)
Error shows.
Fast Debugger (ruby-debug-ide 0.6.0, debase 0.2.1, file filtering is supported) listens on 127.0.0.1:45202
^C/home/vagrant/.rvm/gems/ruby-2.2.1/gems/ruby-debug-ide-0.6.0/lib/ruby-debug-ide.rb:80:in `sleep': Interrupt
from /home/vagrant/.rvm/gems/ruby-2.2.1/gems/ruby-debug-ide-0.6.0/lib/ruby-debug-ide.rb:80:in `wait'
from /home/vagrant/.rvm/gems/ruby-2.2.1/gems/ruby-debug-ide-0.6.0/lib/ruby-debug-ide.rb:80:in `block in prepare_debugger'
from /home/vagrant/.rvm/gems/ruby-2.2.1/gems/ruby-debug-ide-0.6.0/lib/ruby-debug-ide.rb:79:in `synchronize'
from /home/vagrant/.rvm/gems/ruby-2.2.1/gems/ruby-debug-ide-0.6.0/lib/ruby-debug-ide.rb:79:in `prepare_debugger'
from /home/vagrant/.rvm/gems/ruby-2.2.1/gems/ruby-debug-ide-0.6.0/lib/ruby-debug-ide.rb:85:in `debug_program'
from /home/vagrant/.rvm/gems/ruby-2.2.1/gems/ruby-debug-ide-0.6.0/bin/rdebug-ide:130:in `<top (required)>'
from -e:1:in `load'
from -e:1:in `<main>'
Process finished with exit code -1

Related

Debugging Rails 5 with RubyMine: Breakpoints Don't Work

I have just installed the latest RubyMine (2018.1.1) and I created a Rails 5.2 application using the wizard in RubyMine. I then generated a single scaffold so that I would have something to test with.
If I set a breakpoint inside a unit test, the breakpoint works. However, if I run the web server (I tried both - the default Puma and WEBrick), no breakpoints work. I can see the print statements from my controller, but the breakpoint is never triggered.
What am I doing wrong?
Here's the list of my gems:
actioncable (5.2.0)
actionmailer (5.2.0)
actionpack (5.2.0)
actionview (5.2.0)
activejob (5.2.0)
activemodel (5.2.0)
activerecord (5.2.0)
activestorage (5.2.0)
activesupport (5.2.0)
addressable (2.5.2)
archive-zip (0.11.0)
arel (9.0.0)
bigdecimal (default: 1.3.4)
bindex (0.5.0)
bootsnap (1.3.0)
builder (3.2.3)
bundler (1.16.1)
byebug (10.0.2)
capybara (3.0.3)
childprocess (0.9.0)
chromedriver-helper (1.2.0)
cmath (default: 1.0.0)
coffee-rails (4.2.2)
coffee-script (2.4.1)
coffee-script-source (1.12.2)
concurrent-ruby (1.0.5)
crass (1.0.4)
csv (default: 1.0.0)
date (default: 1.0.0)
debase (0.2.2)
debase-ruby_core_source (0.10.3)
erubi (1.7.1)
etc (default: 1.0.0)
execjs (2.7.0)
fcntl (default: 1.0.0)
ffi (1.9.23)
fiddle (default: 1.0.0)
fileutils (default: 1.0.2)
globalid (0.4.1)
i18n (1.0.1)
io-console (default: 0.4.6)
io-like (0.3.0)
ipaddr (default: 1.2.0)
jbuilder (2.7.0)
json (default: 2.1.0)
listen (3.1.5)
loofah (2.2.2)
mail (2.7.0)
marcel (0.3.2)
method_source (0.9.0)
mimemagic (0.3.2)
mini_mime (1.0.0)
mini_portile2 (2.3.0)
minitest (5.11.3)
msgpack (1.2.4)
multi_json (1.13.1)
nio4r (2.3.0)
nokogiri (1.8.2)
openssl (default: 2.1.0)
psych (default: 3.0.2)
public_suffix (3.0.2)
puma (3.11.4)
rack (2.0.5)
rack-test (1.0.0)
rails (5.2.0)
rails-dom-testing (2.0.3)
rails-html-sanitizer (1.0.4)
railties (5.2.0)
rake (12.3.1)
rb-fsevent (0.10.3)
rb-inotify (0.9.10)
rdoc (default: 6.0.1)
ruby-debug-ide (0.7.0.beta4)
ruby_dep (1.5.0)
rubyzip (1.2.1)
sass (3.5.6)
sass-listen (4.0.0)
sass-rails (5.0.7)
scanf (default: 1.0.0)
sdbm (default: 1.0.0)
selenium-webdriver (3.11.0)
spring (2.0.2)
spring-watcher-listen (2.0.1)
sprockets (3.7.1)
sprockets-rails (3.2.1)
sqlite3 (1.3.13)
stringio (default: 0.0.1)
strscan (default: 1.0.0)
thor (0.20.0)
thread_safe (0.3.6)
tilt (2.0.8)
turbolinks (5.1.1)
turbolinks-source (5.1.0)
tzinfo (1.2.5)
uglifier (4.1.10)
web-console (3.6.2)
webrick (default: 1.4.2)
websocket-driver (0.7.0)
websocket-extensions (0.1.3)
xpath (3.0.0)
zlib (default: 1.0.0)
I am using ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-linux]
This problem is documented here: https://youtrack.jetbrains.com/issue/RUBY-20684
There's also a workaround specified: comment bootsnap requiring in the Gemfile and in the boot.rb
Commenting out bootsnap worked for me - breakpoints now work.

Error running Rails Server - unable to load gem 'sass-rails'

I'm new to Rails and trying to load and configure it for the first time. I'm following the instructions on http://installrails.com/steps/rails_for_linux_and_other for installing on Linux (I'm actually using an Ubuntu Virtual Machine that is installed on a Windows 10 Host).
I keep getting this error:
`rescue in block (2 levels) in require': There was an error while trying to load the gem 'sass-rails'. (Bundler::GemRequireError)
Gem Load Error is: uninitialized constant Sass::Rails::Tilt
There is nothing that seems to be able to tell me what to do from here. I've actually uninstalled, and re-installed Rails once, because I thought my Rails version was creating problems (I did have Rails 5.1.1), but the same thing is happening now (with Rails 4.2.6).
Ruby Version:
ruby 2.3.3p222 (2016-11-21 revision 56859) [x86_64-linux]
Gem List:
*** LOCAL GEMS ***
actioncable (5.1.1)
actionmailer (5.1.1, 4.2.6)
actionpack (5.1.1, 4.2.6)
actionview (5.1.1, 4.2.6)
activejob (5.1.1, 4.2.6)
activemodel (5.1.1, 4.2.6)
activerecord (5.1.1, 4.2.6)
activesupport (5.1.1, 4.2.6)
addressable (2.5.1)
arel (8.0.0, 6.0.4)
bigdecimal (1.2.8)
bindex (0.5.0)
binding_of_caller (0.7.2)
builder (3.2.3)
bundler (1.14.6)
bundler-unload (1.0.2)
byebug (9.0.6)
capybara (2.14.0)
childprocess (0.7.0)
coffee-rails (4.2.1, 4.1.1)
coffee-script (2.4.1)
coffee-script-source (1.12.2)
concurrent-ruby (1.0.5)
debug_inspector (0.0.3)
did_you_mean (1.0.0)
erubi (1.6.0)
erubis (2.7.0)
execjs (2.7.0)
executable-hooks (1.3.2)
ffi (1.9.18)
gem-wrappers (1.2.7)
globalid (0.4.0)
i18n (0.8.1)
io-console (0.4.5)
jbuilder (2.6.4)
jquery-rails (4.3.1)
json (1.8.6, 1.8.3)
listen (3.1.5)
loofah (2.0.3)
mail (2.6.5)
method_source (0.8.2)
mime-types (3.1)
mime-types-data (3.2016.0521)
mini_portile2 (2.1.0)
minitest (5.10.2, 5.8.5)
multi_json (1.12.1)
mustermann (1.0.0)
net-telnet (0.1.1)
nio4r (2.0.0)
nokogiri (1.7.2)
power_assert (0.2.6)
psych (2.1.0)
public_suffix (2.0.5)
puma (3.8.2)
rack (2.0.3, 1.6.8)
rack-protection (2.0.0)
rack-test (0.6.3)
rails (4.2.6)
rails-deprecated_sanitizer (1.0.3)
rails-dom-testing (2.0.3, 1.0.8)
rails-html-sanitizer (1.0.3)
railties (4.2.6)
rake (12.0.0, 10.4.2)
rb-fsevent (0.9.8)
rb-inotify (0.9.8)
rdoc (4.3.0, 4.2.1)
ruby_dep (1.5.0)
rubygems-bundler (1.4.4)
rubyzip (1.2.1)
rvm (1.11.3.9)
sass (3.4.24)
sass-rails (5.0.6)
sdoc (0.4.2)
selenium-webdriver (3.4.0)
sinatra (2.0.0)
spring (2.0.1)
spring-watcher-listen (2.0.1)
sprockets (3.7.1)
sprockets-rails (3.2.0)
sqlite3 (1.3.13)
test-unit (3.1.5)
thor (0.19.4)
thread_safe (0.3.6)
tilt (2.0.7)
turbolinks (5.0.1)
turbolinks-source (5.0.3)
tzinfo (1.2.3)
uglifier (3.2.0)
web-console (3.5.1, 2.3.0)
websocket (1.2.4)
websocket-driver (0.6.5)
websocket-extensions (0.1.2)
xpath (2.0.0)
Thanks for any help.
try to run following command:
bundle update
If it failed then try to comment below code:
saas-rails
bundle install
I commented out
gem 'sass-rails'
Then did a
bundle update
The server seems to work now. The only thing I'm not completely sure of is if I need that gem for something. (Like I said, I'm new to Rails).

Sunspot - RSolr::Error::Http - 404 Not Found

Hi I recently got a hold of a Rails 3.2.0 project that makes use of sunspot
I've been running into an error below:
RSolr::Error::Http - 404 Not Found
Error: Not Found
URI: http://localhost:8982/solr/select?wt=ruby
Request Headers: {"Content-Type"=>"application/x-www-form-urlencoded; charset=UTF-8"}
Request Data: "fq=type%3APost&fq=-kind_s%3A%28event+OR+contest+OR+job+OR+review%29&fq=-category_im%3A%28%29&fq=exclude_from_explore_b%3Afalse&fq=-destroyed_at_d%3A%5B*+TO+*%5D&fq=published_at_ds%3A%5B*+TO+2016%5C-04%5C-26T12%5C%3A07%5C%3A29Z%5D&fq=published_at_ds%3A%5B*+TO+*%5D&fq=verified_author_b%3Atrue&sort=published_at_ds+desc&start=0&rows=24&q=*%3A*"
Backtrace: /home/revrun/.rvm/gems/ruby-2.1.2/gems/rsolr-1.0.13/lib/rsolr/client.rb:284:in `adapt_response'
/home/revrun/.rvm/gems/ruby-2.1.2/gems/rsolr-1.0.13/lib/rsolr/client.rb:190:in `execute'
/home/revrun/.rvm/gems/ruby-2.1.2/gems/rsolr-1.0.13/lib/rsolr/client.rb:176:in `send_and_receive'
(eval):2:in `post'
/home/revrun/.rvm/gems/ruby-2.1.2/gems/sunspot-1.3.3/lib/sunspot/search/abstract_search.rb:38:in `execute'
/home/revrun/.rvm/gems/ruby-2.1.2/gems/sunspot_rails-1.3.3/lib/sunspot/rails/searchable.rb:329:in `solr_execute_search'
/home/revrun/.rvm/gems/ruby-2.1.2/gems/sunspot_rails-1.3.3/lib/sunspot/rails/searchable.rb:153:in `solr_search'
/home/revrun/Code/saf/safarious/app/controllers/explore/posts_controller.rb:76:in `post_search'
/home/revrun/Code/saf/safarious/app/controllers/explore/posts_controller.rb:15:in `category'
/home/revrun/.rvm/gems/ruby-2.1.2/gems/actionpack-3.2.13/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
/home/revrun/.rvm/gems/ruby-2.1.2/gems/actionpack-3.2.13/lib/abstract_controller/base.rb:167:in `process_action'
My installed gems are as follows:
*** LOCAL GEMS ***
actionmailer (4.2.6, 4.1.0, 3.2.13)
actionpack (4.2.6, 4.1.0, 3.2.13)
actionview (4.2.6, 4.1.0)
activejob (4.2.6)
activemodel (4.2.6, 4.1.0, 3.2.13)
activerecord (4.2.6, 4.1.0, 3.2.13)
activeresource (3.2.13)
activesupport (4.2.6, 4.1.0, 3.2.13)
acts-as-taggable-on (2.3.3)
acts_as_votable (0.8.0)
addressable (2.4.0, 2.3.6, 2.3.2)
afm (0.2.0)
annotate (2.5.0)
arel (6.0.3, 5.0.1.20140414130214, 3.0.2)
Ascii85 (1.0.2)
authlogic (3.2.0)
autoprefixer-rails (6.3.6)
awesome_print (1.6.1, 1.1.0)
base58 (0.1.0)
bcrypt (3.1.7)
bcrypt-ruby (3.0.1)
bigdecimal (1.2.4)
binding_of_caller (0.7.2)
bootstrap (4.0.0.alpha3)
bootstrap-sass (3.1.1.1, 3.1.1.0)
bourbon (3.0.1)
braintree (2.22.0)
browser (0.1.6)
bson (3.2.6)
builder (3.2.2, 3.0.4)
bundler (1.8.3)
bundler-unload (1.0.2)
byebug (8.2.2)
callsite (0.0.11)
cancan (1.6.10)
capistrano (3.2.1)
capistrano-bundler (1.1.2)
capistrano-rails (1.1.1)
capistrano-rvm (0.1.1)
capybara (2.3.0, 2.0.2)
carmen (0.2.13)
carrierwave (0.8.0)
carrierwave_backgrounder (0.1.3)
childprocess (0.5.3, 0.3.6)
chronic (0.10.2)
client_side_validations (3.2.1)
client_side_validations-simple_form (2.0.1)
coderay (1.1.1)
coffee-rails (4.1.1, 4.0.0, 3.2.2)
coffee-script (2.4.1, 2.3.0)
coffee-script-source (1.10.0, 1.8.0)
colorize (0.7.3)
commonjs (0.2.7)
concurrent-ruby (1.0.1)
connection_pool (2.2.0)
cookiejar (0.3.0)
crack (0.4.2, 0.3.2)
daemons (1.2.3, 1.1.9)
dante-editor (0.0.14)
database_cleaner (1.3.0, 0.9.1)
debug_inspector (0.0.2)
declarative_authorization (0.5.7)
delayed_job (4.1.1, 3.0.4)
delayed_job_active_record (0.3.3)
delayed_job_mongoid (2.2.0)
diff-lcs (1.2.5, 1.1.3)
domain_name (0.5.20160309)
dotenv (0.9.0)
dotenv-rails (0.9.0)
em-http-request (1.1.3)
em-socksify (0.3.1)
email_validator (1.4.0)
erubis (2.7.0)
eventmachine (1.2.0.1, 1.0.3)
exceptional (2.0.33)
excon (0.49.0, 0.16.10)
execjs (2.6.0, 2.2.1, 1.4.0)
executable-hooks (1.3.2)
factory_girl (4.4.0, 4.1.0)
factory_girl_rails (4.4.1, 4.1.0)
fakeredis (0.4.1)
faraday (0.9.2, 0.9.0, 0.8.11, 0.7.6)
faraday_middleware (0.10.0, 0.9.0)
fattr (2.2.1)
faye (1.1.2)
faye-websocket (0.10.3)
ffi (1.9.3, 1.3.1)
filepicker-rails (0.1)
fog (1.9.0)
foreman (0.78.0)
formatador (0.2.4)
garb (0.9.1)
gem-wrappers (1.2.7)
globalid (0.3.6)
god (0.13.7)
haml (4.0.7)
haml-rails (0.9.0)
handlebars_assets (0.19.1)
hashdiff (0.3.0)
hashery (2.1.0)
hashie (3.4.3, 1.2.0)
heroku (3.43.0)
heroku-api (0.4.2)
highline (1.7.8, 1.6.15)
hike (1.2.3, 1.2.2)
hiredis (0.4.5)
html2haml (2.0.0)
htmlentities (4.3.1)
http-cookie (1.0.2)
http_parser.rb (0.6.0)
httpauth (0.2.0)
i18n (0.7.0, 0.6.11, 0.6.1)
io-console (0.4.2)
jbuilder (2.4.1, 1.5.3)
journey (1.0.4)
jquery-rails (4.1.1, 3.1.0, 2.2.0)
jquery-ui-rails (4.2.1)
json (1.8.3, 1.8.1, 1.8.0)
jwt (1.5.1, 1.0.0)
launchy (2.4.3, 2.1.2)
less (2.6.0)
less-rails (2.7.1)
letter_opener (1.0.0)
libv8 (3.16.14.13 x86-linux)
linkedin (0.3.7)
lograge (0.2.0)
loofah (2.0.3)
mail (2.6.3, 2.5.4, 2.5.3)
mail_view (1.0.3)
medium-editor-rails (2.2.0)
meta_request (0.2.5)
method_source (0.8.2)
mime-types (2.99.1, 1.25.1, 1.21)
mini_magick (3.4)
mini_portile (0.6.0)
mini_portile2 (2.0.0)
minitest (5.8.4, 5.3.5, 4.7.5)
mongo (2.1.2)
mongoid (5.1.1)
mongoid-compatibility (0.3.1)
mono_logger (1.1.0)
multi_json (1.11.2, 1.10.1, 1.7.3)
multi_xml (0.5.5)
multipart-post (2.0.0, 1.2.0, 1.1.5)
nesty (1.0.2)
net-scp (1.2.1, 1.0.4)
net-ssh (2.9.2, 2.9.1, 2.6.3)
net-ssh-gateway (1.2.0)
netrc (0.11.0, 0.10.3)
newrelic_rpm (3.6.4.122)
nokogiri (1.6.7.2, 1.6.2.1, 1.5.5)
oauth (0.5.1, 0.4.7)
oauth2 (1.1.0, 0.9.4, 0.6.1)
omniauth (1.3.1, 1.1.1)
omniauth-facebook (3.0.0, 1.4.0)
omniauth-linkedin (0.0.8)
omniauth-oauth (1.0.1)
omniauth-oauth2 (1.4.0, 1.0.2)
omniauth-twitter (0.0.14)
optionable (0.2.0)
options (2.3.2, 2.3.0)
origin (2.2.0)
panda (1.6.0)
pdf-inspector (1.1.0)
pdf-reader (1.3.2)
pg (0.17.1)
polyglot (0.3.5, 0.3.3)
pr_geohash (1.0.0)
prawn (0.12.0)
prawn-qrcode (0.2.0)
prawn_rails (0.0.11)
progress_bar (1.0.5, 0.4.0)
pry (0.10.3)
pry-byebug (3.3.0)
psych (2.0.5)
public_activity (1.5.0)
quiet_assets (1.1.0, 1.0.2)
rack (1.6.4, 1.5.2, 1.4.7, 1.4.5)
rack-cache (1.2)
rack-contrib (1.1.0)
rack-protection (1.5.3)
rack-ssl (1.3.3)
rack-test (0.6.3, 0.6.2)
rails (4.2.6, 4.1.0, 3.2.13)
rails-deprecated_sanitizer (1.0.3)
rails-dom-testing (1.0.7)
rails-html-sanitizer (1.0.3)
rails-sanitize-js (1.0.0)
rails_autolink (1.1.0)
rails_config (0.4.2)
railties (4.2.6, 4.1.0, 3.2.13)
rake (11.1.1, 10.3.2, 10.1.0, 10.0.4)
rdoc (4.1.2, 4.1.0, 3.12.2)
recaptcha (0.3.5)
redis (3.2.2, 3.1.0, 3.0.4)
redis-actionpack (3.2.3)
redis-activesupport (3.2.3)
redis-namespace (1.5.1)
redis-rack (1.4.2)
redis-rails (3.2.3)
redis-store (1.1.4)
ref (2.0.0)
resque (1.25.2)
rest-client (1.8.0, 1.6.9, 1.6.8)
rest-client-components (1.4.0)
rqrcode (0.4.2)
rsolr (1.1.1, 1.0.13, 1.0.10)
rspec-core (2.14.8, 2.12.2)
rspec-expectations (2.14.5, 2.12.1)
rspec-mocks (2.14.6, 2.12.1)
rspec-rails (2.14.0, 2.12.2)
ruby-hmac (0.4.0)
ruby-oembed (0.8.8)
ruby-prof (0.12.1)
ruby-rc4 (0.1.5)
ruby_parser (3.8.1)
rubygems-bundler (1.4.4)
rubyzip (1.1.7, 1.1.6, 0.9.9)
rvm (1.11.3.9)
safe_yaml (1.0.3)
sass (3.4.22, 3.4.21, 3.2.19, 3.2.5)
sass-rails (5.0.4, 4.0.2, 3.2.6)
sdoc (0.4.1)
selenium-webdriver (2.42.0, 2.29.0)
sequel (3.20.0)
sexp_processor (4.7.0)
simple_form (2.0.4)
sinatra (1.4.5, 1.0)
sitemap_generator (4.0.1)
slop (3.6.0)
sorcery (0.8.6)
spring (1.6.4)
sprockets (3.5.2, 2.11.0, 2.2.2)
sprockets-rails (3.0.4, 2.0.1)
sqlite3 (1.3.9)
sshkit (1.5.1)
state_machine (1.1.2)
subexec (0.2.2)
sunspot (1.3.3)
sunspot_rails (1.3.3)
sunspot_solr (2.2.5)
taps (0.3.24)
test-unit (2.1.2.0)
test_after_commit (0.2.0)
therubyracer (0.12.2)
thin (1.6.4, 1.5.1)
thor (0.19.1, 0.18.1)
thread_safe (0.3.5, 0.3.4)
tilt (2.0.2, 1.4.1)
treetop (1.4.15, 1.4.12)
ttfunk (1.0.3)
turbolinks (2.2.3)
typhoeus (0.2.4)
tzinfo (1.2.2, 0.3.37)
uglifier (2.7.2, 1.3.0)
underscore-rails (1.8.3)
unf (0.1.4)
unf_ext (0.0.7.2)
vegas (0.1.11)
web-console (2.3.0)
webmock (1.18.0)
websocket (1.0.7, 1.0.6)
websocket-driver (0.6.3)
websocket-extensions (0.1.2)
whenever (0.9.4)
will_paginate (3.0.4)
xpath (2.0.0, 1.0.0)
yaml_db (0.2.3)
And my sunspot.yml:
production:
solr:
hostname: localhost
port: 8983
log_level: WARNING
development:
solr:
hostname: localhost
port: 8982
log_level: INFO
test:
solr:
hostname: localhost
port: 8981
log_level: WARNING
I've tried numerous other suggestions on SO but nothing seems to be fixing the issue. I have no experience with sunspot so indepth answers are most welcome :-D
Thanks.
start the solr server by using the below command:
rake sunspot:solr:start
After starting check whether it is started or not by opening the http://localhost:8982 in your browser
You should provider path in the sunspot.yml file:
development:
solr:
hostname: localhost
port: 8982
log_level: INFO
path: /solr/your_collection
Notice that path is used in Solr's requests like this:
http://localhost:8982/solr/#/your_collection
Also, if you use predefined Solr you should start it via an rake task:
bundle exec rake sunspot:solr:start
Just had the same problem. In my case there was a stale sunspot process running. What I did was:
Open the Activity Monitor
Search for 'java'
Kill 'java ' processes
Started Sunspot ( rake sunspot:solr:start )
Reindex Sunspot ( rake sunspot:solr:reindex )

Shoulda not working in Padrino, fails with undefined method `delegate'

I've recently set up a couple of Padrino projects and each time I generated the project, I used Shoulda as the test option. But when I try to run 'padrino rake test,' it fails with the following error:
Sonnys-MacBook-Pro:sample_blog sonnyjitsu$ padrino rake test
=> Executing Rake test ...
/Users/sonnyjitsu/.rvm/rubies/ruby-2.0.0-p353/bin/ruby -I"lib" -I"/Users/sonnyjitsu/.rvm/gems/ruby-2.0.0-p353/gems/rake-10.1.0/lib" "/Users/sonnyjitsu/.rvm/gems/ruby-2.0.0-p353/gems/rake-10.1.0/lib/rake/rake_test_loader.rb" "test/app/**/*_test.rb"
/Users/sonnyjitsu/.rvm/gems/ruby-2.0.0-p353/gems/shoulda-matchers-2.4.0/lib/shoulda/matchers/active_record/association_matcher.rb:77:in `<class:AssociationMatcher>': undefined method `delegate' for Shoulda::Matchers::ActiveRecord::AssociationMatcher:Class (NoMethodError)
Here is my gem list
actionmailer (4.0.1, 3.2.3)
actionpack (4.0.1, 3.2.3)
activemodel (4.0.1, 3.2.15, 3.2.3)
activerecord (4.0.1, 3.2.15, 3.2.3)
activerecord-deprecated_finders (1.0.3)
activeresource (3.2.3)
activesupport (4.0.1, 3.2.15, 3.2.3)
addressable (2.3.5)
arel (4.0.1, 3.0.3, 3.0.2)
atomic (1.1.14)
backports (3.3.5)
bcrypt-ruby (3.1.2)
bigdecimal (1.2.0)
builder (3.1.4, 3.0.4, 3.0.0)
bundler (1.3.5)
bundler-unload (1.0.2)
classifier (1.3.3)
coffee-rails (4.0.1, 3.2.2)
coffee-script (2.2.0)
coffee-script-source (1.6.3, 1.3.3)
colorator (0.1)
commander (4.1.5)
daemons (1.1.9)
data_mapper (1.2.0)
data_objects (0.10.13)
dm-aggregates (1.2.0)
dm-constraints (1.2.0)
dm-core (1.2.1)
dm-do-adapter (1.2.0)
dm-migrations (1.2.0)
dm-mysql-adapter (1.2.0)
dm-serializer (1.2.2)
dm-sqlite-adapter (1.2.0)
dm-timestamps (1.2.0)
dm-transactions (1.2.0)
dm-types (1.2.2)
dm-validations (1.2.0)
do_mysql (0.10.13)
do_sqlite3 (0.10.13)
erubis (2.7.0)
eventmachine (1.0.3)
execjs (2.0.2, 1.4.0)
executable-hooks (1.2.6)
fast-stemmer (1.0.2)
fastercsv (1.5.5)
ffi (1.9.3)
git (1.2.6)
haml (4.0.4)
highline (1.6.20)
hike (1.2.3, 1.2.1)
htmlentities (4.3.1)
http_router (0.11.0, 0.5.4)
i18n (0.6.5, 0.6.0)
io-console (0.4.2)
jbuilder (1.5.2)
jekyll (1.3.1)
jekyll-import (0.1.0.rc1)
journey (1.0.4)
jquery-rails (3.0.4, 2.0.2)
json (1.8.1, 1.7.7, 1.7.3)
json_pure (1.8.1)
libv8 (3.16.14.3 x86_64-darwin-13)
liquid (2.5.4)
listen (1.3.1)
mail (2.5.4, 2.4.4)
maruku (0.6.1)
metaclass (0.0.1)
mime-types (1.25.1, 1.18)
mini_portile (0.5.2)
minitest (4.7.5, 4.3.2)
mocha (0.14.0)
multi_json (1.8.2, 1.3.6)
mysql2 (0.3.14)
nokogiri (1.6.0)
padrino (0.11.4, 0.9.21)
padrino-admin (0.11.4, 0.9.21)
padrino-cache (0.11.4, 0.9.21)
padrino-core (0.11.4, 0.9.21)
padrino-gen (0.11.4, 0.9.21)
padrino-helpers (0.11.4, 0.9.21)
padrino-mailer (0.11.4, 0.9.21)
polyglot (0.3.3)
pony (1.6.1, 1.5.1)
posix-spawn (0.3.6)
psych (2.0.0)
pygments.rb (0.5.4)
rack (1.5.2, 1.4.1)
rack-cache (1.2)
rack-protection (1.5.1)
rack-ssl (1.3.2)
rack-test (0.6.2, 0.6.1)
rails (3.2.3)
railties (4.0.1, 3.2.3)
rake (10.1.0, 0.9.6, 0.9.2.2)
rb-fsevent (0.9.3)
rb-inotify (0.9.2)
rb-kqueue (0.2.0)
rdoc (4.0.0, 3.12.2, 3.12)
redcarpet (2.3.0)
ref (1.0.5)
rubygems-bundler (1.4.2)
rvm (1.11.3.8)
safe_yaml (0.9.7)
sass (3.2.12, 3.1.19)
sass-rails (4.0.1, 3.2.5)
sdoc (0.3.20)
sequel (4.4.0)
shoulda (3.5.0)
shoulda-context (1.1.6)
shoulda-matchers (2.4.0)
sinatra (1.4.4)
sinatra-contrib (1.4.1)
sinatra-extension (1.0)
sinatra-flash (0.3.0)
slim (2.0.2)
sprockets (2.10.1, 2.1.3)
sprockets-rails (2.0.1)
sqlite3 (1.3.8, 1.3.6)
sqlite3-ruby (1.3.3)
stringex (1.5.1)
syntax (1.0.0)
temple (0.6.7)
test-unit (2.0.0.0)
therubyracer (0.12.0)
thin (1.6.1)
thor (0.18.1, 0.17.0, 0.14.6)
thread_safe (0.1.3)
tilt (1.4.1, 1.3.3)
treetop (1.4.15, 1.4.10)
turbolinks (1.3.1)
tzinfo (0.3.38, 0.3.33)
uglifier (2.3.1, 1.2.4)
url_mount (0.2.1)
uuidtools (2.1.4)
yajl-ruby (1.1.0)
I've not tried to use shoulda-matchers outside of rails before, but it looks like they make use of the delegate macro provided by ActiveSupport. Try require 'activesupport' (or a more limited subset if you'd rather) in your tests to see if that helps.
require 'active_support/core_ext/module/delegation'
worked for me

sqlite and ruby generate command problem

When I run the command
$rails generate scaffold User name:string email:string
/home/user/.rvm/gems/ruby-1.9.2-p290#rails3tutorial/gems/sqlite3-1.3.3/lib/sqlite3/sqlite3_native.so: [BUG] Segmentation fault
ruby 1.8.7 (2010-08-16 patchlevel 302) [i686-linux]
I get the above error...
I installed sqlite but it is version 2.8.17
my gem list returns this:
actionmailer (3.1.0.rc8)
actionpack (3.1.0.rc8)
activemodel (3.1.0.rc8)
activerecord (3.1.0.rc8)
activeresource (3.1.0.rc8)
activesupport (3.1.0.rc8)
addressable (2.2.6)
ansi (1.3.0)
arel (2.2.1)
bcrypt-ruby (3.0.0)
builder (3.0.0)
bundler (1.0.18)
coffee-rails (3.1.0.rc.7)
coffee-script (2.2.0)
coffee-script-source (1.1.2)
erubis (2.7.0)
execjs (1.2.4)
heroku (2.6.1)
hike (1.2.1)
i18n (0.6.0)
jquery-rails (1.0.13)
launchy (2.0.5)
mail (2.3.0)
mime-types (1.16)
multi_json (1.0.3)
polyglot (0.3.2)
rack (1.3.2)
rack-cache (1.0.3)
rack-mount (0.8.3, 0.8.2)
rack-ssl (1.3.2)
rack-test (0.6.1)
rails (3.1.0.rc8)
railties (3.1.0.rc8)
rake (0.9.2 ruby)
rdoc (3.9.4)
rest-client (1.6.7)
rubyzip (0.9.4)
sass (3.1.7)
sass-rails (3.1.0, 3.1.0.rc.7)
sprockets (2.0.0, 2.0.0.beta.15)
sqlite3 (1.3.4, 1.3.3)
term-ansicolor (1.0.6)
thor (0.14.6)
tilt (1.3.3)
treetop (1.4.10)
turn (0.8.2)
tzinfo (0.3.29)
uglifier (1.0.2)
any ideas ? :/

Resources