I have the same issue on a previously working site, after updating from
Ruby 2.6.3, Jekyll 3.8.6, jekyll-sass-converter 2.0.0 (i think, or 1.5.2)
to
Ruby 3.2.1, Jekyll 4.3.2, jekyll-sass-converter 3.0.0
It’s not related to “main.scss”, I am getting the error on everything in assets/css that includes an
@import "whatever";
eg
╷
3 │ @import "gallery";
│ ^
╵
/srv/jekyll/assets/css/gallery.scss 3:18 @import
/srv/jekyll/assets/css/gallery.scss 1:9 root stylesheet
Conversion error: Jekyll::Converters::Scss encountered an error while converting 'assets/css/gallery.scss':
expected "{".
------------------------------------------------
Jekyll 4.3.2 Please append `--trace` to the `serve` command
for any additional information or backtrace.
------------------------------------------------
/usr/gem/gems/jekyll-sass-converter-3.0.0/lib/jekyll/converters/scss.rb:175:in `rescue in convert': expected "{". (Jekyll::Converters::Scss::SyntaxError)
raise SyntaxError, e.message
^^^^^^^^^^^^^^^^^^^^^^
from /usr/gem/gems/jekyll-sass-converter-3.0.0/lib/jekyll/converters/scss.rb:159:in `convert'
from /usr/gem/gems/jekyll-4.3.2/lib/jekyll/renderer.rb:105:in `block in convert'
I did have a main.scss
and tried converting that and it’s import to base
on the off chance it was also affecting the other ones but to no avail.
I have a tenuous intuition it’s trying to use some different flavor of sass now
Edit: I just noticed this VS Code “error” I’ve been ignoring in these sass files since the beginning is related:
I ignored this in the past because I got the syntax from the Jekyll tutorial, and it worked before.