import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.yaml.snakeyaml.Yaml;
+import org.zeroturnaround.exec.InvalidExitValueException;
import org.zeroturnaround.exec.ProcessExecutor;
import org.zeroturnaround.exec.StartedProcess;
import org.zeroturnaround.exec.stream.slf4j.Slf4jDebugOutputStream;
if (Files.exists(getPid())) {
String pid = new String(Files.readAllBytes(getPid()));
PidProcess pr = Processes.newPidProcess(Integer.parseInt(pid));
- pr.destroyForcefully();
+ try {
+ pr.destroyForcefully();
+ } catch (InvalidExitValueException e) {
+ // ignore,
+ } catch (Exception e) {
+ LOGGER.error("Could not destroy process with pid {}", pid, e);
+ }
}
// check that npm dependencies are satisfied