def get_dict_key_by_value(source_dict: dict, dict_value):
    """Return the first key of the ``source_dict`` that has the ``dict_value`` as value."""

    for k, v in source_dict.items():
        if v == dict_value:
            return k
    return