[New-bugs-announce] [issue8956] Incorrect ValueError message for subprocess.Popen.send_signal() on Windows

Giampaolo Rodola' report at bugs.python.org
Wed Jun 9 20:25:36 CEST 2010


New submission from Giampaolo Rodola' <g.rodola at 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 <report at bugs.python.org>
<http://bugs.python.org/issue8956>
_______________________________________


More information about the New-bugs-announce mailing list