Skip to content
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

plz watch: --run flag is broken #599

Closed
katzdm opened this issue Apr 17, 2019 · 3 comments
Closed

plz watch: --run flag is broken #599

katzdm opened this issue Apr 17, 2019 · 3 comments

Comments

@katzdm
Copy link
Contributor

katzdm commented Apr 17, 2019

Running plz watch --run <TARGET>does not run the executable.

@katzdm
Copy link
Contributor Author

katzdm commented Apr 18, 2019

Hey @peterebden , thanks for the quick turnaround on this! There's a small problem with your change - After killing the plz watch invocation with CTRL+C, the process(es) started by plz (i.e. the binary targets) continue to run.

This was especially problematic since the binary I'm testing with is a webserver, so the next time I ran plz watch --run //example_service, the program couldn't start because port 8080 was already in use (by the abandoned process). kill -9 did the trick, but I'm sure plz can be smart enough to handle the signal and kill the process :)

@peterebden
Copy link
Member

Yup fair - to be honest the current implementation isn't great for persistent processes (it really needs to kill them when changes happen). Was thinking about that as I wrote that fix but didn't have time for it then.

peterebden added a commit that referenced this issue Apr 19, 2019
Interestingly they now seem to be getting a SIGINT when I ctrl+c the parent, although I haven't done anything explicit to handle that?
@peterebden
Copy link
Member

594a0ec should improve this considerably. Somewhat surprisingly it now seems to terminate subprocesses although I've not done anything explicit for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants