def unregisterReapProcessHandler(pid, process):
    """
    Unregister a process handler previously registered with
    L{registerReapProcessHandler}.
    """
    if not (pid in reapProcessHandlers
            and reapProcessHandlers[pid] == process):
        raise RuntimeError("Try to unregister a process not registered.")
    del reapProcessHandlers[pid]

    Unregister a process handler previously registered with
    L{registerReapProcessHandler}.
    
stackoverflow/venv/lib/python3.6/site-packages/twisted/internet/process.py