0

Am noob.. when am trying to bundle install a spree theme am finding the error like this i added

gem 'spree_rdr_theme', :git => 'git://github.com/spree/spree_rdr_theme.git'

to gemfile then I did with bundle install then when i gave

rails g spree_rdr_theme:install

I find the error as below

shany@shany:~/mystore$ rails g spree_rdr_theme:install
/home/shany/.rvm/gems/ruby-1.9.3-p448@rails3tutorial2ndEd/bundler/gems/spree_rdr_
theme-b5d6a80caa6b/app/overrides/spree/shared/redefine_recently_viewed_overrides.rb
:1:in `<top (required)>': undefined method `all' for #<Rails::Engine::Railties:
0x954ee04> (NoMethodError)......

Why does this happen ? Please help me

Imane Fateh
  • 2,418
  • 3
  • 19
  • 23
shany
  • 1

1 Answers1

1

You're using a very old version of Spree (0.70.1) and Rails (3.1.1). Both are very old (released in 2012), and have outstanding security vulnerabilities, and are no longer maintained.

The spree_rdr_theme that you're trying to install has not been updated to work with newer versions of Rails, and therefore is causing you problems.

To get things working on your existing version try this line in your Gemfile instead:

gem 'spree_rdr_theme', :git => 'git://github.com/spree/spree_rdr_theme.git', :branch => '0-70-stable'

That being said. I would instead look at upgrading Spree to 2.0, Rails to 3.2.14 (or Spree to 2.1, Rails to 4.0), and use the new spree_fancy theme instead of spree_rdr_theme (which is also no longer maintained). You should do that anyway, in order to be up to date on the latest security fixes.

If this is a new project, you can easily follow the Spree guide to create a new project. If this is an upgrade of an existing project, you're going to have your work cut out for you, but running code with known security vulnerabilities is asking for trouble.

GeekOnCoffee
  • 1,155
  • 5
  • 15
gmacdougall
  • 4,901
  • 1
  • 16
  • 21