Skip to content

Loading…

Stack level too deep error in 3.1.5 #78

Closed
kendagriff opened this Issue · 19 comments
@kendagriff

Hi,

I'm not sure which mix of gems triggers the problem, but downgrading from 3.1.5 to 3.1.4 fixes it. Here's list of relevant gems, and a stack trace:

Gemfile

gem 'rails', '3.1.3'
gem 'bson', '1.4.0'
gem 'bson_ext', '1.4.0'
gem 'jquery-rails'
gem 'eco'

group :assets do
  gem "compass", :git => "git://github.com/chriseppstein/compass.git", :tag => "v0.12.alpha.2"
  gem 'sass-rails', :git => 'git://github.com/rails/sass-rails.git', :branch => '3-1-stable'
  gem 'coffee-rails', "~> 3.1.0"
  gem 'uglifier'
  gem 'oily_png'
end

Trace


** Invoke assets:precompile (first_time)
** Execute assets:precompile
/Users/kendallbuchanan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby /Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets --trace
** Invoke assets:precompile:all (first_time)
** Execute assets:precompile:all
** Invoke assets:precompile:primary (first_time)
** Invoke assets:environment (first_time)
** Execute assets:environment
** Invoke environment (first_time)
** Execute environment
** Invoke tmp:cache:clear (first_time)
** Execute tmp:cache:clear
** Execute assets:precompile:primary
rake aborted!
stack level too deep
  (in /Users/kendallbuchanan/Repositories/education/app/assets/stylesheets/admins/index.css.scss)
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:162
Tasks: TOP => assets:precompile:primary
rake aborted!
Command failed with status (1): [/Users/kendallbuchanan/.rvm/rubies/ruby-1....]
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/file_utils.rb:53:in `block in create_shell_runner'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/file_utils.rb:45:in `call'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/file_utils.rb:45:in `sh'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/file_utils_ext.rb:39:in `sh'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/file_utils.rb:80:in `ruby'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/file_utils_ext.rb:39:in `ruby'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/bundler/gems/rails-df932c4ae229/actionpack/lib/sprockets/assets.rake:9:in `ruby_rake_task'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/bundler/gems/rails-df932c4ae229/actionpack/lib/sprockets/assets.rake:17:in `invoke_or_reboot_rake_task'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/bundler/gems/rails-df932c4ae229/actionpack/lib/sprockets/assets.rake:25:in `block (2 levels) in <top (required)>'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `call'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:205:in `block in execute'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `each'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:200:in `execute'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:158:in `block in invoke_with_call_chain'
/Users/kendallbuchanan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:151:in `invoke_with_call_chain'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/task.rb:144:in `invoke'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:116:in `invoke_task'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block (2 levels) in top_level'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `each'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:94:in `block in top_level'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:88:in `top_level'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:66:in `block in run'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/lib/rake/application.rb:63:in `run'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/gems/rake-0.9.2.2/bin/rake:33:in `<top (required)>'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/bin/rake:19:in `load'
/Users/kendallbuchanan/.rvm/gems/ruby-1.9.2-p290@support/bin/rake:19:in `<main>'
Tasks: TOP => assets:precompile

Additional note: If I tinker with the stylesheet that has causes the error, it'll simply appear in another stylesheet. Again, downgrading to 3.1.4 appears to fix it.

@nddrylliog

Just had the same problem, downgrading to 3.1.4 fixed it, thanks for the tip!

@guilhermesimoes

Same issue with 3.1.6 while deploying to Heroku. The stack trace isn't that helpful but my issue is well documented here: http://stackoverflow.com/questions/9787766/rake-assetsprecompile-not-working-on-heroku/9794114
The answer I accepted points exactly to this page so we have come full circle here.
Downgrading to 3.1.4 fixed it.

@stevenh512 stevenh512 added a commit to stevenh512/diaspora that referenced this issue
@stevenh512 stevenh512 Correctly enable the asset pipeline
* Add the Rails 3.1+ Bundler.require statement to config/application.rb
  (properly enabling the :assets group)
* Move handlebars_assets gem into the :assets group where it belongs. :)
* Downgrade sass-rails to 3.1.4 since enabling the :assets group exposed
  a known bug in sass-rails ~> 3.1.5 [rails/sass-rails#78].
e55547e
@Envek Envek added a commit to AmurSU/taurus that referenced this issue
@Envek Envek Asset pipeline fixes
* On deployment precompile assets after the configs get copied
* Downgrade sass-rails to 3.1.4 since enabling the :assets group exposed
  a known bug in sass-rails ~> 3.1.5 [rails/sass-rails#78]
* Ignore precompiled assets by git
bf9f78f
@Envek

I think, this bug should be introduced here
3.1.4...3.1.5#diff-2
or here
3.1.4...3.1.5#diff-3

@stevenh512 stevenh512 added a commit to diaspora/diaspora that referenced this issue
@stevenh512 stevenh512 Correctly enable the asset pipeline
* Add the Rails 3.1+ Bundler.require statement to config/application.rb
  (properly enabling the :assets group)
* Move handlebars_assets gem into the :assets group where it belongs. :)
* Downgrade sass-rails to 3.1.4 since enabling the :assets group exposed
  a known bug in sass-rails ~> 3.1.5 [rails/sass-rails#78].
b24a4a7
@shedd

I'm also getting this with 3.1.6. Downgrading to 3.1.4 also fixed this for us.

@mgiraldo

+1: Downgrade worked here too.

@NZKoz
Ruby on Rails member

Likewise, only 3.1.4 works for me on this.

@coderanger

Just to be clear, this was fixed a month ago in 3-1-stable but a release hasn't been made.

@mike-sandler

would be nice to see the month-old fix released. We just ran into the same problem, downgrading to 3.1.4 for now.

@jclay

Going from 3.1.6 to 3.1.4 fixed it for me also!

@stengland

This was an issue for me as well. Reverting to 3.1.4 solved it.

@asilano asilano added a commit to asilano/free-dom that referenced this issue
@asilano asilano Force sass-rails version (see rails/sass-rails#78) 34b4ce9
@hakimovis

My solution is to replace application.css with *= require_self and *= require_tree . to application.sass with @include directives

@leehambley

Still an issue on 3.1.6, reverted to 3.1.4 solved this for me (Rails 3.1.5)

@penmanglewood

This issue is still open. My Heroku deploy was broken with 3.1.6. Switching to 3.1.4 fixed the problem on a Rails 3.1.3 app.

@jfeldstein

Yup still open.

Please keep in mind that keeping an old version of Sass-Rails around isn't health for people's projects. I'm running into other gems being blocked from getting upgrades and bug fixes now, as a result of 3.1.4's dependencies.

Bundler could not find compatible versions for gem "actionpack":
In Gemfile:
  draper (= 0.17.0) ruby depends on
    actionpack (~> 3.1.3) ruby

  sass-rails (= 3.1.4) ruby depends on
    actionpack (3.1.1)
@jipiboily

Any work has been done here or is on the table?

@nat

Will upgrading to 3.2.x fix this? -- or is downgrading to 3.1.4 still what people do? I'm curious like @jipiboily.

@guilhermesimoes

@jipiboily, @nat, @jfeldstein You can now switch to the latest rails version (3.2.8) and the latest sass-rails (3.2.5) safely but with a single hiccup.

You will go from the previous

rake aborted! stack level too deep

to the new error

rake aborted! could not connect to server:
Connection refused Is the server running on host "127.0.0.1" and
accepting TCP/IP connections on port 5432`.

This issue is mentioned here activeadmin/activeadmin#474 and is easily fixed with this single line of code on config/application.rb:

config.assets.initialize_on_precompile = false
@frodsan

Is this still an issue?

@rafaelfranca
Ruby on Rails member

I'll close this one from now. Feel free to ask to reopen if you think it is still an issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.