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

Add multiprocessing.Process.kill() #74977

pitrou opened this issue Jun 28, 2017 · 4 comments

Add multiprocessing.Process.kill() #74977

pitrou opened this issue Jun 28, 2017 · 4 comments
3.7 stdlib type-feature


Copy link

@pitrou pitrou commented Jun 28, 2017

BPO 30794
Nosy @pitrou, @applio, @vmsp
  • #2528
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2017-07-18.15:34:58.644>
    created_at = <Date 2017-06-28.20:03:41.527>
    labels = ['3.7', 'type-feature', 'library']
    title = 'Add multiprocessing.Process.kill()'
    updated_at = <Date 2017-07-18.15:35:11.987>
    user = '' fields:

    activity = <Date 2017-07-18.15:35:11.987>
    actor = 'pitrou'
    assignee = 'none'
    closed = True
    closed_date = <Date 2017-07-18.15:34:58.644>
    closer = 'pitrou'
    components = ['Library (Lib)']
    creation = <Date 2017-06-28.20:03:41.527>
    creator = 'pitrou'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 30794
    keywords = []
    message_count = 4.0
    messages = ['297216', '297681', '297685', '298600']
    nosy_count = 3.0
    nosy_names = ['pitrou', 'davin', 'vmsp']
    pr_nums = ['2528']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = ''
    versions = ['Python 3.7']

    Copy link
    Member Author

    @pitrou pitrou commented Jun 28, 2017

    subprocess.Popen() has both terminate() and kill() methods. Under Unix, the first sends SIGTERM and the second SIGKILL.

    multiprocessing.Process() only has terminate(), which sends SIGTERM. It may be useful to add a kill() method to send SIGKILL (on Windows, kill() would be the same as terminate()).

    One possible use case is when the child process has redefined the SIGTERM handler to something that doesn't trigger an exit (or takes a long time to exit). Or if something non-interruptible is running...

    @pitrou pitrou added 3.7 stdlib type-feature labels Jun 28, 2017
    Copy link

    @vmsp vmsp mannequin commented Jul 4, 2017

    Hey, I submitted a PR and just signed the CLA. If you could please take a look. Thanks!

    Copy link
    Member Author

    @pitrou pitrou commented Jul 4, 2017

    Thank you Vitor! I posted some review comments on your PR.

    Copy link
    Member Author

    @pitrou pitrou commented Jul 18, 2017

    New changeset ba75af7 by Antoine Pitrou (Vitor Pereira) in branch 'master':
    bpo-30794: added kill() method to multiprocessing.Process (bpo-2528)

    @pitrou pitrou added the invalid label Jul 18, 2017
    @pitrou pitrou closed this as completed Jul 18, 2017
    @pitrou pitrou removed the invalid label Jul 18, 2017
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    3.7 stdlib type-feature
    None yet

    No branches or pull requests

    1 participant