-
Notifications
You must be signed in to change notification settings - Fork 330
undefined method `environment' for nil:NilClass #191
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
Comments
/cc @rafaelfranca |
This is going to be tricky to get working on sass 3.3. I think sass-rails will have to pin to 3.2 for now and use the old |
Make SassImporter safely marshalable
All of the glob stuff requires a dynamic reference to context which won't be possible if the importer reference needs to be marshable. A pretty annoying requirement by sass core. I'd probably guess they didn't realize this was the case but theres a ton of circular references that looped the importer into whatever instance is actually being cached. |
Right! I really wish we could remove our |
Since current version of sass-rails is incompatible with sprockets 2.11.1, wouldn't the expedient fix be to release a patch version locked to sprockets 2.11.0? |
Another approach for supporting globs would be to disable sass caching. That avoids all the marshaling problems. You'll still have sprockets caching to help keep things fast. |
Yes. I'm doing this right now. But I'm more concerned about the future of this project. I don't want to lock sprockets forever. |
Excellent. Thanks @rafaelfranca. |
I get this too, whenever I try to import files. This is on a new project running vanilla everything. |
Thank you @rafaelfranca |
had to fix sprokets for now: rails/sass-rails#191
4.0.2 released |
I really don't know how this continue this gem if We also can't just deprecate it because sprockets alone doesn't work with Rails features. |
|
I'm more stumped to how to make glob importers work in Sass >= 3.3. |
@josh What issues are you seeing specific to Sass 3.3? I haven't noticed any difference in behaviour between 3.2 and 3.3. |
See rails/sass-rails#191 for more information
See rails/sass-rails#191 for more information
See rails/sass-rails#191 for more information
See rails/sass-rails#191 for more information
See rails/sass-rails#191 for more information
See rails/sass-rails#191 for more information
See rails/sass-rails#191 for more information
See rails/sass-rails#191 for more information
For more information see: rails/sass-rails#191
more information: rails/sass-rails#191
While locking sprockets is working for Rails version 4.02. for Rails version 4.0.4 it isn't:
|
@gracegimon locking sass-rails to 4.0.2 seem to work around this issue temporarily.
Or if you prefer,
|
do not work with Rails 4.0.4
|
Similar problem with Rails 4.1.0. |
@SharpV : You should |
Thanks @robin850. I followed your instructions and Is there a 'known-good' combination of sass & sass-rails that works with Rail 4.1.0? |
Yep, through a lot of trial and error I found a working combination: https://gist.github.com/dogweather/11150333 That's simply my app's Gemfile and Gemfile.lock. Note that a |
@dogweather Thanks, will give it a shot! |
There seems to be a lot going on here can someone summarize the status of this issue, is anyone working it? |
This specific issue is already fixed. Make sure you use sass-rails 4.0.3. |
I'm sorry, I don't understand. It seems like, if we're using Rails 4.1, then we need to remember to lock sass-rails to 4.0.3. Otherwise, the dependencies can't be resolved. Is this right? And so it seems like the issue isn't fixed: Sass-rails depends on an older version of sprockets while Rails depends on a newer version. Is this accurate? Is there a GitHub issue or branch where this is being worked on? |
No, it is not correct. In fact Rails 4.1.0 generates the Gemfile already using sass-rails 4.0.3. Also rails doesn't define a newer version of sprockets. One thing that is correct is that we are depending on an older version of sprockets and we need to remove that. But this doesn't mean that sass-rails or rails is broken. It just means you have to be sure you are using the right version. In the next weeks I hope I can remove this dependency freeze and release sass-rails 4.0.4. |
+1 for fixing this |
+1 |
Is anyone fixing this? |
It is already fixed in the latest version |
A change in sprockets broke sass-rails in 4.0.0. See: * rails/sass-rails#191 * sstephenson/sprockets#537
A change in sprockets broke sass-rails in 4.0.0. See: * rails/sass-rails#191 * sstephenson/sprockets#537
sstephenson/sprockets#537
The error occurs when sprockets is upgraded from 2.11.0 to 2.11.1 using Rails 4.
@josh says:
The text was updated successfully, but these errors were encountered: