import signal


def signal_to_human(value):
    """signal_to_human() -- provide signal name based on subprocess return code

    Args:
        value (int) - Popen.returncode

    Returns:
        Signal name if it exists, otherwise the original value provided
    """
    signals = {getattr(signal, name) * -1 : name for name in dir(signal) if name.startswith("SIG")}

    if value < 0 and value in signals:
        return signals[value]

    return value