You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: app/server/ruby/bin/daemon.rb
+14-3Lines changed: 14 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -438,7 +438,7 @@ def wait
438
438
439
439
defkill
440
440
441
-
ifprocess_running?
441
+
ifprocess_running? && @pid
442
442
Util.log"Process Booter - killing #{@cmd} with pid #{@pid} and args #{@args.inspect}, wait_thr status: #{@wait_thr}, #{@wait_thr.status}"
443
443
444
444
unlessUtil.os == :windows
@@ -489,9 +489,16 @@ def kill
489
489
Util.log"Process Booter - no need to kill #{@cmd} with pid #{@pid} and args #{@args.inspect} - already terminated, wait_thr status: #{@wait_thr}, #{@wait_thr.status}"
490
490
end
491
491
492
+
493
+
unless@pid
494
+
Util.log"Process Booter - Unfortunately we don't have a @pid for #{@cmd} with args #{@args.inspect}. wait_thr: #{@wait_thr}"
495
+
end
496
+
492
497
@io_thr.killif@io_thr
493
498
@log_file.closeif@log_file
499
+
494
500
end
501
+
495
502
end
496
503
497
504
@@ -612,7 +619,12 @@ def process_running?
612
619
end
613
620
614
621
defkill
615
-
@pid=@tau_pid.get
622
+
begin
623
+
@pid=@tau_pid.get(30)
624
+
rescueSonicPi::PromiseTimeoutError
625
+
@pid=nil
626
+
Util.log"Didn't receive Tau's Pid after waiting for 30s..."
0 commit comments