活动管理员和Sass错误

时间:2012-09-07 06:15:37

标签: ruby-on-rails sass activeadmin

/usr/local/rvm/gems/ruby-1.9.3-p194/gems/activeadmin 0.5.0/lib/active_admin/application.rb:283:in `generate_stylesheets': uninitialized constant Sass::Plugin (NameError)
from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/activeadmin-0.5.0/lib/active_admin/application.rb:105:in `prepare!'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/activeadmin-0.5.0/lib/active_admin.rb:72:in `setup'
    from /Users/devinross/Desktop/music-server1/config/initializers/active_admin.rb:1:in `<top (required)>'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/engine.rb:588:in `block (2 levels) in <class:Engine>'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/engine.rb:587:in `each'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/engine.rb:587:in `block in <class:Engine>'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/initializable.rb:30:in `instance_exec'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/initializable.rb:30:in `run'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/initializable.rb:55:in `block in run_initializers'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/initializable.rb:54:in `each'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/initializable.rb:54:in `run_initializers'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/application.rb:136:in `initialize!'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/railtie/configurable.rb:30:in `method_missing'
    from /Users/devinross/Desktop/music-server1/config/environment.rb:5:in `<top (required)>'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/application.rb:103:in `require_environment!'
    from /usr/local/rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/commands.rb:25:in `<top (required)>'
    from script/rails:6:in `require'
    from script/rails:6:in `<main>'

有谁知道如何解决这个问题?

gem 'rails', '~> 3.2.8'

group :assets do
  gem 'sass-rails',   '~> 3.2.3'
  gem 'coffee-rails', '~> 3.2.1'
  gem 'uglifier',     '>= 1.0.3'
  gem 'yui-compressor'
end


gem 'nokogiri'

# infrastructure
gem 'rake', require: false
gem 'pg'
gem 'dalli'

# web server
# gem 'thin'    # for evented server
# gem 'goliath' # for evented server
gem 'puma'    # for multi-threaded server
# gem 'unicorn' # for multi-processor server

# queue
gem 'sidekiq'
gem 'slim'
gem 'sinatra', :require => nil

# support
gem 'newrelic_rpm'
gem 'airbrake'
gem 'heroku'

1 个答案:

答案 0 :(得分:0)

点击此处查看此问题:https://github.com/gregbell/active_admin/issues/1686

在该问题中有针对此问题的拉取请求:https://github.com/gregbell/active_admin/pull/2028

您也可以通过预编译管理资产来解决此问题,如4.1节中所述:http://guides.rubyonrails.org/asset_pipeline.html