logging_format/visitor.py
def get_id_attr(self, value):
        """Check if value has id attribute and return it.

        :param value: The value to get id from.
        :return: The value.id.
        """
        if not hasattr(value, "id") and hasattr(value, "value"):
            value = value.value
        return value.id
def get_id_attr(self, value):
        """Check if value has id attribute and return it.

        :param value: The value to get id from.
        :return: The value.id.
        """
        if not hasattr(value, "id") and hasattr(value, "value"):
            value = value.value
        return value.id
Check if value has id attribute and return it.

        :param value: The value to get id from.
        :return: The value.id.