Open robcole opened 2 years ago
ps output seems helpful here as well:
# overmind
➜ lucky_nox_bug git:(main) ✗ ps aux | grep yarn
robcole 8431 4.3 0.1 35052572 79280 s003 S+ 8:29AM 0:00.15 node /Users/robcole/.n/bin/yarn run browser-sync start -c bs-config.js --port 3001 -p http://127.0.0.1:3000
robcole 8435 0.0 0.0 34253900 952 s000 S+ 8:29AM 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn --exclude-dir=.idea --exclude-dir=.tox yarn
robcole 8370 0.0 0.1 35115800 77196 s005 S+ 8:29AM 0:00.18 /Users/robcole/.n/bin/node /Users/robcole/.n/bin/yarn build:css --watch
robcole 8356 0.0 0.1 34994968 80756 s004 S+ 8:29AM 0:00.18 /Users/robcole/.n/bin/node /Users/robcole/.n/bin/yarn build:js --watch
robcole 8342 0.0 0.1 35361820 81072 s005 S+ 8:29AM 0:00.16 node /Users/robcole/.n/bin/yarn dev:css
robcole 8341 0.0 0.1 35324956 79840 s004 S+ 8:29AM 0:00.16 node /Users/robcole/.n/bin/yarn dev:js
# nox
➜ lucky_nox_bug git:(main) ✗ ps aux | grep yarn
robcole 8588 1.3 0.1 35043356 79460 s001 S+ 8:30AM 0:00.15 node /Users/robcole/.n/bin/yarn run browser-sync start -c bs-config.js --port 3001 -p http://127.0.0.1:3000
robcole 8592 0.0 0.0 34253900 952 s000 S+ 8:30AM 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=CVS --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn --exclude-dir=.idea --exclude-dir=.tox yarn
For context, horseshoe is a very vanilla lucky build, but the asset builder is using esbuild --watch
I'm pretty sure this must relate to exit codes and how yarn wraps different types of ongoing watch processes + how Nox traps exit codes, but haven't dug in deeply yet.
https://github.com/robcole/lucky_nox_bug has a repo that can repro this (this is just a one-off creation from @grepsedawk's https://github.com/grepsedawk/horseshoe template starter).
Steps to replicate:
1 - Clone the repo. 2 - Run script/setup. 3 - Run
lucky dev
You'll note the following in the logs:
That alone isn't problematic, but any save events won't trigger a recompilation, as Nox seems to think the process has exited completely:
Compare this to overmind, and you'll note that overmind will continue to properly pick up on filesystem events and recompilation will be triggered in Lucky: