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
CSS: Parse Error where none was before #35011
Comments
Curious if this is the same issue I'm having after running a Yarn upgrade for my Rails project. Can't compile Bootstrap 5 because of css-loader and postcss-loader or updates to different Babel packages.
|
Speaking of keyframes: We have some in own CSS as well, minified, which does not cause issues. I'll compare the syntax around those. |
I can confirm the same behavior that @bradbajuz is talking about with a Rails 6.1 application using Bootstrap 5 and webpack
|
We use clean-css to minify our CSS. @MichaIng if you've spotted something specific let me know so that we make an upstream issue to clean-css. If it's a CSS parser issue, you should probably ask upstream and I'm pretty sure @sideshowbarker will try to take care of the issue. Otherwise let's close this issue. |
Hello there, I also ran into the same issue with a new Rails webpacker project that uses Module build failed (from ./node_modules/postcss-loader/src/index.js):
ParserError: Syntax Error at line: 1, column 25 However, I was using I haven't been able to figure out which dependency change causes this issue, but I found out the problem lies within the following lines: bootstrap/scss/mixins/_grid.scss Lines 10 to 12 in 9437973
If I update these lines to the following, it no longer have issues compiling: margin-top: calc(-1 * var(--#{$variable-prefix}gutter-y) * 1); // stylelint-disable-line function-disallowed-list
margin-right: calc(-1 * var(--#{$variable-prefix}gutter-x) * .5); // stylelint-disable-line function-disallowed-list
margin-left: calc(-1 * var(--#{$variable-prefix}gutter-x) * .5); // stylelint-disable-line function-disallowed-list TL;DRHere are the differences in the dependencies:
|
After a little bit more research, I found out the If you use Possibly related to the |
Can you please open an upstream issue and reference this issue there? |
The issue could be invalid CSS we output or a bug in sass indeed. BTW we do have a PR #35033 |
@XhmikosR, I opened an issue on the dart-sass repo sass/dart-sass#1516. Thanks! |
The interesting thing is that I actually wanted to open this issue at the repository of the validator and not here 😅. I'm glad that it was beneficial here as well. The v.Nu uses css-validator, so I guess an update there caused it to be stricter or implied a bug, so probably it is not even related to the SASS issue. In the meantime it works again (without applying the SASS related workaround), probably as the CSS validator got updated as well. The older v.Nu jar's are not available for download anymore and I'm a bit lazy to compile them, but it looks like here is the reported error and fix (older Bootstrap but same symptom): w3c/css-validator#330 |
Going to close this issue then. @ilunglee yours is a different issue, but I'm not sure if it's our problem or sass yet. Feel free to make a new one, but if you don't, no worries since we have the PR. |
This reverts commit 90dbf36.
As a reference. Here is the issue: shellscape/postcss-values-parser#138 |
To replicate on Debian 11 or Ubuntu 20.04 with Java 17:
The exactly same worked well 3 days before, so I assume something with the CSS parser changed. The failing parts are those around keyframes definitions, from what I see.
The non-minified CSS does not throw the error, but the minification is done correctly, no syntax errors implied. Running the non-minified version through some other minifiers leads to the same parser errors.
The text was updated successfully, but these errors were encountered: