Closed webfaqtory closed 6 years ago
Looks like we don't have any tests around the remove right now https://github.com/sass/node-sass/blob/master/test/watcher.js
I would have thought that removed
would have been correct since that is the function in lib/watcher
@xzyfer thoughts?
I guess this is related to https://github.com/sass/node-sass/pull/2181/files
I'm new to using node-sass
but I tried the watch option and got the exact same error as OP. The error appears on the first change, which was not deleting anything. Here is the full error I get (with the filepath removed).
...node-sass\bin\node-sass:266
handler(watcher.deleted(file));
^
TypeError: watcher.deleted is not a function
at Gaze.<anonymous> (...node-sass\bin\node-sass:266:21)
at Gaze.emit (events.js:160:13)
at Gaze.emit (...node-sass\node_modules\gaze\lib\gaze.js:128:32)
at ...node-sass\node_modules\gaze\lib\gaze.js:408:18
at Array.forEach (<anonymous>)
at ...node-sass\node_modules\gaze\lib\gaze.js:404:12
at FSReqWrap.oncomplete (fs.js:149:20)
I'm on Windows, and using 4.7.2 as well. Could be relevant, but I have other error warnings (not worth explaining unless you think it has to do with this error).
Getting the same error as @CaitlinWeb. What is the best way to fix ? Thanks.
node-sass 4.7.2 (Wrapper) [JavaScript]
libsass 3.5.0.beta.2 (Sass Compiler) [C/C++]
This is fixed in 4.8.1. We've temporarily unpublished it due #2280. The fix is to wait until we 4.8.2 is released.
@xzyfer Thanks for the fast response. When do you plan to release 4.8.2 ?
When there is a resolution to #2280. You can subscribe to that issue for updates.
After updating to 4.8.2 I haven't gotten the error yet. Seems to be fixed. Thanks!
Same in 4.8.3
fs.js:994
binding.lstat(pathModule._makeLong(path), statValues);
^
Error: ENOENT: no such file or directory, lstat 'path\to\test.scss'
Everything works fine until I delete a watched .scss file then I get
TypeError: watcher.deleted is not a function at Gaze. (/var/www/dev/web/themes/custom/acas/node_modules/node-sass/bin/node-sass:266:21)
at emitOne (events.js:116:13)
at Gaze.emit (events.js:211:7)
at Gaze.emit (/var/www/dev/web/themes/custom/acas/node_modules/gaze/lib/gaze.js:128:32)
at /var/www/dev/web/themes/custom/acas/node_modules/gaze/lib/gaze.js:408:18
at Array.forEach ()
at /var/www/dev/web/themes/custom/acas/node_modules/gaze/lib/gaze.js:404:12
at FSReqWrap.oncomplete (fs.js:135:15)
5.6.0
):8.9.4
):{ http_parser: '2.7.0', node: '8.9.4', v8: '6.1.534.50', uv: '1.15.0', zlib: '1.2.11', ares: '1.10.1-DEV', modules: '57', nghttp2: '1.25.0', openssl: '1.0.2n', icu: '59.1', unicode: '9.0', cldr: '31.0.1', tz: '2017b' }
):linux
):x64
):"node-sass 4.7.2 (Wrapper) [JavaScript] libsass 3.5.0.beta.2 (Sass Compiler) [C/C++]
):node-sass@4.7.2
):In watcher.js there is no function called watcher.deleted but there is watcher.removed. Editing node-sass to call this instead gives 'Error: ENOENT: no such file or directory,'. Had to give up