NoMethodError undefined method `' for "image":Sass::Script::Value::String #279
I am getting this one. I haven't yet figured out where it's coming from in the source SCSS.
But the last linse in the stacktrace are:
Anyone have any idea what's going on, or suggestions for how I might debug this further? I'm not sure where to go from here -- or even how to figure out what line in source SASS is triggering this.
Okay, I had to force downgrade sprockets to latest 2.x (2.12.4) and downgrade sprockets-rails to 2.3.2.
Despite the fact that sprockets-rails 2.3.3 and 2.3.2 both say they should work with sprockets [">= 2.8", "< 4.0"] -- that was the only combination I could get that would actually compile my Sass.
Downgrading both, my Sass compiles again.
I have no idea if this is a bug in sprockets, sprockets-rails, both, neither, whatever. This is super confusing.
I don't like having to lock to older versions of sprockets and sprockets-rails in my Gemfile.
Any ideas? This is pretty confusing.
Okay, I never completely got to the bottom of this and created an isolated reproduction.
However, it appears to be working for me without this error now, with latest versions of sprockets and sprockets-rails allowed by Rails 4.2.4 -- sprockets 3.4.0, and sprockets-rails 2.3.3 -- I think those are the same versions I was using when I had the problem I originally reported here though.
One thing I did change: I still had some lines in my scss that used the old two-argument asset-url, eg:
I thought this two argument from was deprecated but still allowed? However, the two argument from was sometimes, unpredictably giving me errors "Wrong number of arguments, 2 for 1", and other times working -- I can't explain it. It seemed to even depend on the Rails environment in use (I have a 'staging' environment i created myself, whose environments/staging.rb is just a copy of production.rb, but which has different database.yml and other config).
I don't know if that could have also been responsible for this error, but since I fixed the two-arg asset-url's to one... I don't seem to have seen it. Hopefully it will stay that way. If it comes back, I'll add another comment.
From the time you commented, probably you resolved. But, to future guys, I think this can be your problem. This resolved to me, when upgrading my app from 3.2 to 4.2 too: