New submission from Giampaolo Rodola' <g.rod...@gmail.com>: def send_signal(self, sig): """Send a signal to the process """ if sig == signal.SIGTERM: self.terminate() elif sig == signal.CTRL_C_EVENT: os.kill(self.pid, signal.CTRL_C_EVENT) elif sig == signal.CTRL_BREAK_EVENT: os.kill(self.pid, signal.CTRL_BREAK_EVENT) else: raise ValueError("Only SIGTERM is supported on Windows")
Just noticed right now while I was reading subprocess source code. I guess that should be "Only SIGTERM, CTRL_C_EVENT or CTRL_BREAK_EVENT are supported on Windows". ---------- components: Library (Lib) messages: 107408 nosy: astrand, giampaolo.rodola priority: normal severity: normal status: open title: Incorrect ValueError message for subprocess.Popen.send_signal() on Windows versions: Python 2.7, Python 3.2 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue8956> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com