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

NoMethodError: undefined method `register_engine' for nil:NilClass #609

Closed
samanmohamadi opened this issue Dec 20, 2015 · 7 comments
Closed

Comments

@samanmohamadi
Copy link

After adding solidus in gems,I face following Error :
oMethodError: undefined method 'register_engine' for nil:NilClass
.../.rvm/gems/ruby-2.2.3/gems/handlebars_assets-0.19.1/lib/handlebars_assets.rb:20:in block in register_extensions'

@ashwin47
Copy link

Same here.

@tvdeyen
Copy link
Member

tvdeyen commented Dec 20, 2015

It is possible for you to share your Gemfile.lock with us? So we can debug potential gem conflicts.

Also, please show us what steps you take to install Solidus. Step by step, please :)

Thanks

@lexuszhi1990
Copy link

i got the same error here. I create a new rails app, and add

gem 'solidus'
gem 'solidus_auth_devise'

to gemfile, then bundle install, run bundle exec rails g spree:install, then got this error:

/.rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/handlebars_assets-0.22.0/lib/handlebars_assets.rb:20:in `block in register_extensions': undefined method `register_engine' for nil:NilClass (NoMethodError)
    from /Users/david/.rbenv/versions/2.2.1/lib/ruby/gems/2.2.0/gems/handlebars_assets-0.22.0/lib/handlebars_assets.rb:19:in `each'

here is my gemfile.lock

# Gemfile.lock
GEM
  remote: https://rubygems.org/
  specs:
    actionmailer (4.2.2)
      actionpack (= 4.2.2)
      actionview (= 4.2.2)
      activejob (= 4.2.2)
      mail (~> 2.5, >= 2.5.4)
      rails-dom-testing (~> 1.0, >= 1.0.5)
    actionpack (4.2.2)
      actionview (= 4.2.2)
      activesupport (= 4.2.2)
      rack (~> 1.6)
      rack-test (~> 0.6.2)
      rails-dom-testing (~> 1.0, >= 1.0.5)
      rails-html-sanitizer (~> 1.0, >= 1.0.1)
    actionview (4.2.2)
      activesupport (= 4.2.2)
      builder (~> 3.1)
      erubis (~> 2.7.0)
      rails-dom-testing (~> 1.0, >= 1.0.5)
      rails-html-sanitizer (~> 1.0, >= 1.0.1)
    activejob (4.2.2)
      activesupport (= 4.2.2)
      globalid (>= 0.3.0)
    activemerchant (1.48.0)
      activesupport (>= 3.2.14, < 5.0.0)
      builder (>= 2.1.2, < 4.0.0)
      i18n (>= 0.6.9)
      nokogiri (~> 1.4)
    activemodel (4.2.2)
      activesupport (= 4.2.2)
      builder (~> 3.1)
    activerecord (4.2.2)
      activemodel (= 4.2.2)
      activesupport (= 4.2.2)
      arel (~> 6.0)
    activesupport (4.2.2)
      i18n (~> 0.7)
      json (~> 1.7, >= 1.7.7)
      minitest (~> 5.1)
      thread_safe (~> 0.3, >= 0.3.4)
      tzinfo (~> 1.1)
    acts_as_list (0.7.2)
      activerecord (>= 3.0)
    addressable (2.4.0)
    arel (6.0.3)
    awesome_nested_set (3.0.2)
      activerecord (>= 4.0.0, < 5)
    bcrypt (3.1.10)
    binding_of_caller (0.7.2)
      debug_inspector (>= 0.0.1)
    bourbon (4.2.6)
      sass (~> 3.4)
      thor (~> 0.19)
    builder (3.2.2)
    byebug (8.2.1)
    camertron-eprun (1.1.0)
    cancancan (1.13.1)
    canonical-rails (0.0.11)
      rails (>= 3.1, < 5.0)
    carmen (1.0.2)
      activesupport (>= 3.0.0)
    cldr-plurals-runtime-rb (1.0.1)
    climate_control (0.0.3)
      activesupport (>= 3.0)
    cocaine (0.5.8)
      climate_control (>= 0.0.3, < 1.0)
    coffee-rails (4.1.1)
      coffee-script (>= 2.2.0)
      railties (>= 4.0.0, < 5.1.x)
    coffee-script (2.4.1)
      coffee-script-source
      execjs
    coffee-script-source (1.10.0)
    colorize (0.7.7)
    concurrent-ruby (1.0.0)
    css_parser (1.3.7)
      addressable
    debug_inspector (0.0.2)
    deface (1.0.2)
      colorize (>= 0.5.8)
      nokogiri (~> 1.6.0)
      polyglot
      rails (>= 3.1)
    devise (3.5.3)
      bcrypt (~> 3.0)
      orm_adapter (~> 0.1)
      railties (>= 3.2.6, < 5)
      responders
      thread_safe (~> 0.1)
      warden (~> 1.2.3)
    devise-encryptable (0.1.2)
      devise (>= 2.1.0)
    erubis (2.7.0)
    execjs (2.6.0)
    ffaker (1.32.1)
    font-awesome-rails (4.5.0.0)
      railties (>= 3.2, < 5.0)
    friendly_id (5.0.5)
      activerecord (>= 4.0.0)
    globalid (0.3.6)
      activesupport (>= 4.1.0)
    handlebars_assets (0.22.0)
      execjs (~> 2.0)
      multi_json (~> 1.0)
      sprockets (>= 2.0.0, < 4.0)
      tilt (~> 1.2)
    highline (1.6.21)
    htmlentities (4.3.4)
    i18n (0.7.0)
    jbuilder (2.3.2)
      activesupport (>= 3.0.0, < 5)
      multi_json (~> 1.2)
    jquery-rails (4.0.5)
      rails-dom-testing (~> 1.0)
      railties (>= 4.2.0)
      thor (>= 0.14, < 2.0)
    jquery-ui-rails (5.0.5)
      railties (>= 3.2.16)
    json (1.8.3)
    kaminari (0.16.3)
      actionpack (>= 3.0.0)
      activesupport (>= 3.0.0)
    loofah (2.0.3)
      nokogiri (>= 1.5.9)
    mail (2.6.3)
      mime-types (>= 1.16, < 3)
    mime-types (2.99)
    mini_portile2 (2.0.0)
    minitest (5.8.3)
    monetize (1.3.1)
      money (~> 6.6)
    money (6.6.1)
      i18n (>= 0.6.4, <= 0.7.0)
    multi_json (1.11.2)
    nokogiri (1.6.7.1)
      mini_portile2 (~> 2.0.0.rc2)
    orm_adapter (0.5.0)
    paperclip (4.2.4)
      activemodel (>= 3.2.0)
      activesupport (>= 3.2.0)
      cocaine (~> 0.5.5)
      mime-types
    paranoia (2.1.4)
      activerecord (~> 4.0)
    polyamorous (1.3.0)
      activerecord (>= 3.0)
    polyglot (0.3.5)
    premailer (1.8.6)
      css_parser (>= 1.3.6)
      htmlentities (>= 4.0.0)
    premailer-rails (1.8.2)
      actionmailer (>= 3, < 5)
      premailer (~> 1.7, >= 1.7.9)
    rabl (0.11.7)
      activesupport (>= 2.3.14)
    rack (1.6.4)
    rack-test (0.6.3)
      rack (>= 1.0)
    rails (4.2.2)
      actionmailer (= 4.2.2)
      actionpack (= 4.2.2)
      actionview (= 4.2.2)
      activejob (= 4.2.2)
      activemodel (= 4.2.2)
      activerecord (= 4.2.2)
      activesupport (= 4.2.2)
      bundler (>= 1.3.0, < 2.0)
      railties (= 4.2.2)
      sprockets-rails
    rails-deprecated_sanitizer (1.0.3)
      activesupport (>= 4.2.0.alpha)
    rails-dom-testing (1.0.7)
      activesupport (>= 4.2.0.beta, < 5.0)
      nokogiri (~> 1.6.0)
      rails-deprecated_sanitizer (>= 1.0.1)
    rails-html-sanitizer (1.0.2)
      loofah (~> 2.0)
    railties (4.2.2)
      actionpack (= 4.2.2)
      activesupport (= 4.2.2)
      rake (>= 0.8.7)
      thor (>= 0.18.1, < 2.0)
    rake (10.4.2)
    ransack (1.6.6)
      actionpack (>= 3.0)
      activerecord (>= 3.0)
      activesupport (>= 3.0)
      i18n
      polyamorous (~> 1.2)
    rdoc (4.2.0)
    responders (2.1.1)
      railties (>= 4.2.0, < 5.1)
    sass (3.4.20)
    sass-rails (5.0.4)
      railties (>= 4.0.0, < 5.0)
      sass (~> 3.1)
      sprockets (>= 2.8, < 4.0)
      sprockets-rails (>= 2.0, < 4.0)
      tilt (>= 1.1, < 3)
    sdoc (0.4.1)
      json (~> 1.7, >= 1.7.7)
      rdoc (~> 4.0)
    select2-rails (3.5.9.1)
      thor (~> 0.14)
    solidus (1.1.0)
      solidus_api (= 1.1.0)
      solidus_backend (= 1.1.0)
      solidus_core (= 1.1.0)
      solidus_frontend (= 1.1.0)
      solidus_sample (= 1.1.0)
    solidus_api (1.1.0)
      rabl (>= 0.9.4.pre1, < 0.12.0)
      solidus_core (= 1.1.0)
      versioncake (~> 2.3.1)
    solidus_auth_devise (1.2.3)
      deface (~> 1.0.0)
      devise (~> 3.5.1)
      devise-encryptable (= 0.1.2)
      json
      multi_json
      solidus_core (>= 1.1.0.alpha, < 2)
    solidus_backend (1.1.0)
      bourbon
      handlebars_assets
      jquery-rails
      jquery-ui-rails (~> 5.0.0)
      select2-rails (= 3.5.9.1)
      solidus_api (= 1.1.0)
      solidus_core (= 1.1.0)
    solidus_core (1.1.0)
      activemerchant (~> 1.48.0)
      acts_as_list (~> 0.3)
      awesome_nested_set (~> 3.0.1)
      cancancan (~> 1.10)
      carmen (~> 1.0.0)
      deface (~> 1.0.0)
      ffaker (~> 1.16)
      font-awesome-rails (~> 4.0)
      friendly_id (~> 5.0.4)
      highline (~> 1.6.18)
      json (~> 1.7)
      kaminari (~> 0.15, >= 0.15.1)
      monetize (~> 1.1)
      paperclip (~> 4.2.0)
      paranoia (~> 2.1.0)
      premailer-rails
      rails (~> 4.2.0)
      ransack (~> 1.6.0)
      responders
      state_machines-activerecord (~> 0.2)
      stringex (~> 1.5.1)
      truncate_html (= 0.9.2)
      twitter_cldr (~> 3.0)
    solidus_frontend (1.1.0)
      canonical-rails (~> 0.0.4)
      jquery-rails
      solidus_api (= 1.1.0)
      solidus_core (= 1.1.0)
    solidus_sample (1.1.0)
      solidus_core (= 1.1.0)
    spring (1.6.0)
    sprockets (3.5.2)
      concurrent-ruby (~> 1.0)
      rack (> 1, < 3)
    sprockets-rails (3.0.0)
      actionpack (>= 4.0)
      activesupport (>= 4.0)
      sprockets (>= 3.0.0)
    sqlite3 (1.3.11)
    state_machines (0.4.0)
    state_machines-activemodel (0.3.0)
      activemodel (~> 4.1)
      state_machines (>= 0.4.0)
    state_machines-activerecord (0.3.0)
      activerecord (~> 4.1)
      state_machines-activemodel (>= 0.3.0)
    stringex (1.5.1)
    thor (0.19.1)
    thread_safe (0.3.5)
    tilt (1.4.1)
    truncate_html (0.9.2)
    turbolinks (2.5.3)
      coffee-rails
    twitter_cldr (3.2.1)
      camertron-eprun
      cldr-plurals-runtime-rb (~> 1.0.0)
      json
      tzinfo
    tzinfo (1.2.2)
      thread_safe (~> 0.1)
    uglifier (2.7.2)
      execjs (>= 0.3.0)
      json (>= 1.8.0)
    versioncake (2.3.1)
      actionpack (>= 3.2)
      activesupport (>= 3.2)
      railties (>= 3.2)
      tzinfo
    warden (1.2.4)
      rack (>= 1.0)
    web-console (2.2.1)
      activemodel (>= 4.0)
      binding_of_caller (>= 0.7.2)
      railties (>= 4.0)
      sprockets-rails (>= 2.0, < 4.0)

PLATFORMS
  ruby

DEPENDENCIES
  byebug
  coffee-rails (~> 4.1.0)
  jbuilder (~> 2.0)
  jquery-rails
  rails (= 4.2.2)
  sass-rails (~> 5.0)
  sdoc (~> 0.4.0)
  solidus
  solidus_auth_devise
  spring
  sqlite3
  turbolinks
  uglifier (>= 1.3.0)
  web-console (~> 2.0)

@samanmohamadi
Copy link
Author

This is a known bug with handlebars-assets gem, which is resolved in master.
Adding the line :
gem 'handlebars_assets', github: 'leshill/handlebars_assets'
to your Gemfile will solve your problem until a new version contains the relevant fix.
http:https://stackoverflow.com/questions/34379554/solidus-installation-failure

@jordan-brough
Copy link
Contributor

FYI, see also jhawthorn@5988804 (from #597) and also #605. cc @jhawthorn

@jhawthorn
Copy link
Contributor

As @samanmohamadi pointed out this was breakage due to the new version of sprockets-rails. We will probably have a new point release this week locking us to sprockets-rails 2.x

@jhawthorn
Copy link
Contributor

I've released v1.1.1 which should resolve this issue. I've split the future task of compatibility with sprockets-rails 3.0 into #618.

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

6 participants