bmustiata / fast-live-reload

A live reload that works with all the possible browsers.
18 stars 5 forks source link

EPERM operation not permitted, lstat #12

Closed markknol closed 4 years ago

markknol commented 5 years ago

Issue: I get a EPERM operation not permitted, lstat error which crashes fast-live-reload.

My structure is this (simplified):

The weird thing is when I perform some heavy tasks inside the C:/mark/game/ folder but outside the C:/mark/game/build it crashes the server. That suggests the fast-live-reload is observing more files than I expect.

$ fast-live-reload -s build/ -sp 7000 -p 9001 build-debug.hxml -e "yarn run build:init" build.hxml -e "yarn run build:init" build/.temp/ -e "true"
warning package.json: No license field
1. Will notify the changes for clients on port 9001
2. and will serve the content from build/ on port 7000
3. and will monitor and execute when files change in subfolders:
   a: build-debug.hxml -> yarn run build:init
   b: build.hxml       -> yarn run build:init
   c: build/.temp/     -> true
events.js:183
      throw er; // Unhandled 'error' event
      ^

Error: EPERM: operation not permitted, lstat 'C:\mark\game\assets\global\game_animations'
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Any idea why it is crashing?

bmustiata commented 5 years ago

Implicitly it should observe the parent folder where the file is, and filter for only notifying when the monitored file changed. That's due to the monitoring API I'm using.

bmustiata commented 5 years ago

So is this still an issue?

markknol commented 5 years ago

Yes I dont think its solved

bmustiata commented 4 years ago

BTW, I just found out that the API I'm using supports monitoring individual files. So I changed it to do exactly that, also monitor individual files. Just now I did a push for 2.10.0 where individual files are being monitored using the API, and not my workaround of checking the parent folder.

Just know that if it still doesn't work then really there's nothing else I can do. :)

markknol commented 4 years ago

Cool, thanks for looking into it! Will check this later!