-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Segmentation fault with Webpack & node sass #1464
Comments
Tested w/ 3.4.2 and works fine |
@robcalcroft please confirm your segfault still happens with node-sass@v3.5.3 |
|
@steadweb can you please create a small github repo that reproduce this issue so I debug it locally? |
Same problem, came back to 3.4.2 works fine |
Gonna vote for this one. I build by software with docker, and the webpack fails with segfault. I'm trying to go back to 3.4.2. |
These comments are not helpful. Saying "I have a problem" does not give me any information I can use to fix this problem. The only way to progress this issue is to create a small github repo that produces this error so I can debug it and create a patch. Help me help you. |
Seems to be issue with libsass sass/libsass#2017 I am using grunt-sass so had to created a fork and roll back to node-sass 3.4.2 https://github.com/liamkeaton/grunt-sass |
@liamkeaton Grunt-sass caused my issue also, explicitly defining node-sass as a dep at 3.4.2 worked and meant I didn't need to fork. https://github.com/jadu/pulsar/pull/167/files @xzyfer I don't have time right now to try track down the specific sass throwing the seg fault but I'll see if I can pinpoint it this evening/tomorrow. |
@Stanton awesome, didn't realise that would work! |
@Stanton @liamkeaton I don't believe that works if you do a clean |
@travm from my tests earlier today I'm pretty sure it works if you use '3.4.2' and not '^3.4.2' |
@travm it has also worked for me from a clean install using '3.4.2' |
@Stanton thanks works perfectly |
+1, getting seg faults with latest 3.5.x node-sass. Switched package.json to |
Error in 3.5.* version, i changed to the 3.4.2 and worked well, |
if it helps at all the root of the 'Backtrace' that gets printed out stems from this in our error logs:
If I have more time I will try to get a basic example up.. EDIT: |
Seeing this via grunt-sass - confirmed to break on osx with node 5.10, centos running jenkins, and debian linux via docker... had to fork and change the node-sass version because grunt-sass is using the ^ for versions... |
I'm also seeing this when building materialize-css with webpack. I was able to track it down to this line of sass: https://github.com/Dogfalo/materialize/blob/v0.97.5/sass/components/_buttons.scss#L169 Removing that line (or downgrading node-sass versions) fixed the issue. |
Everbody: without a self contained sample that you can confirm segfaults we cannot do much here. |
Trouble is @mgreter it isn't as simple as writing a "self contained sample" when really basic examples work as expected. The application that I work on has many other dependencies and the scss compilation isn't small. I understand you guys need testing steps in order to replicate, but to have that to hand and know where the problems lies may take some time. |
I'm trying to put together a small example, but not having much luck yet. I have, however, isolated a single The line in question for me: Which extends: Which imports mixins and functions from: I appreciate that this may not be useful information on it's own, but these notes will come in handy for myself at least. |
I can only further suggest to also check your code base with official ruby sass and also sassc (or any other binding that links to libsass with the same version). Then we would at least know if the segfault happens in libsass or node-sass binding. I also wonder if your code base produces an error in ruby sass and your seeing a variant of sass/libsass#1962 in combination of #1457. |
@mgreter I can confirm that the issue is probably is either in libsass or node-sass. Official ruby sass works fine, node-sass segfaults. Command I ran:
main.scss
Where |
Here you go, @mgreter, tested this as @prashcr stated, and it segfaults -
|
Is that really a minimal test case? It pulls in all of the sass of |
Great point, but I tried to put a minimal version with 2 or 3 imports, and it worked fine... seems to be an issue with bigger projects. |
At least it's straight forward to setup and the first one to actually post something we can try ourself without too much guessing on our part. I can confirm the segfault and incidentally it is already fixed on master -> sass/libsass#2022. So this will be fixed in next versions. |
I guess node-sass keeps issues open until libsass is updated ... On another note: It looks like materialize was never fully libsass compatible (it was silently dropping some |
The segfault with materialize-css has been fixed in v3.6.0. I'll publish it as stable in 48hrs after my weekend. Until then you can install is by specifying the version manually.
or in your package.json
|
node-sass@3.6.0 was released today which fixes the segfault with normalize-css |
The below code will still cause node-sass@3.8.0 to encounter this error Notice the syntax error in line 2 ul.menu {
width:
li {
margin: 5px auto;
a {
color: #333;
}
}
} Screenshot:
|
@xieranmaya this seems unrelated to this issue and you may want to open a new ticket for that. Just checked perl-libsass bindings, and it shows the correct error without a segfault. |
@mgreter so it seems a bug of node-sass or node? |
@xieranmaya you can see that the code supplied errors as expected with the latest node-sass on sassmeister. There appears be an environmental issue. I suggest cleaning your local environment
After a fresh npm install, if you're still experiencing issues please provide the output the following commands
|
I'm getting this message: Segmentation fault I'm using a docker container with Alpine, this is my ouput: $ 4.0.5 |
@calbertts your issue is unrelated. Alpine support was only added in node-sass@v4.1.0 |
Hi, we are still seeing a seg-fault. os: alpine (node:8-alpine docker image) It works if we use very simple sass. |
@torvitas I was having this segmentation fault just now, and I was based on an I "just" changed my |
…rser Add unicode sequence parsing
Same issue as webpack/webpack#2371, not sure if this is a 3.5.2 issue or not?
The text was updated successfully, but these errors were encountered: