Skip to content
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

color.adjust not supported on GitHub pages? #54

Closed
samuelgruetter opened this issue Oct 14, 2024 · 3 comments
Closed

color.adjust not supported on GitHub pages? #54

samuelgruetter opened this issue Oct 14, 2024 · 3 comments
Labels

Comments

@samuelgruetter
Copy link

Thank you for providing and maintaining this awesome jekyll theme!
It has worked seemlessly for my website for many years.
But today, when I wanted to update my website (which is hosted on GitHub pages), GitHub's build log showed the following error:

  Conversion error: Jekyll::Converters::Scss encountered an error while converting 'assets/main.scss':
                    Invalid CSS after "...or-light: color": expected selector or at-rule, was ".adjust($grey-c..." on line 19
/usr/local/bundle/gems/jekyll-sass-converter-1.5.2/lib/jekyll/converters/scss.rb:123:in `rescue in convert': Invalid CSS after "...or-light: color": expected selector or at-rule, was ".adjust($grey-c..." on line 19 (Jekyll::Converters::Scss::SyntaxError)

        raise SyntaxError, "#{e} on line #{e.sass_line}"
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	from /usr/local/bundle/gems/jekyll-sass-converter-1.5.2/lib/jekyll/converters/scss.rb:118:in `convert'
	from /usr/local/bundle/gems/jekyll-3.10.0/lib/jekyll/renderer.rb:101:in `block in convert'

To debug, I installed jekyll locally, and first tried updating all the dependencies (in Gemfile.lock) to the latest versions, but the problem still remained.

Then I noticed that this commit modified the line for which an error is reported. It is part of v1.11.6, so I tried reverting to v1.11.5 by replacing the line

gem "jekyll-whiteglass"

with

gem "jekyll-whiteglass", "= 1.11.5"

in my Gemfile. This change solved the problem locally, but on GitHub Pages, the error remained. To fix it there, I had to replace the line

remote_theme: yous/whiteglass

with

remote_theme: yous/[email protected]

in my _config.yml.

Now, finally my website works again 😅

I'm opening this issue in case some other users get bitten by this as well, and also to suggest that maybe this could be fixed so that the latest version also works on GitHub pages, and maybe you could even add CI to this repo that prevents such breakages in the future?

@yous
Copy link
Owner

yous commented Oct 15, 2024

I can confirm that color.adjust() is not recognized by jekyll-sass-converter with Jekyll < 4, and github-pages gem still uses Jekyll 3.10.0.

It seems that adjust-color() is available instead of color.adjust(): https://sass-lang.com/documentation/modules/color/#adjust

I'll release a new version with the fix.

@yous yous added the bug label Oct 15, 2024
@yous
Copy link
Owner

yous commented Oct 15, 2024

Fixed in e3b734d, and released in v1.11.7. Please have a check.

@samuelgruetter
Copy link
Author

I unpinned the whiteglass version in my website configuration and it seems to work on GitHub pages, thanks for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants