def et_node_to_string(et_node, default=''):
    """Simple method to get stripped text from node or ``default`` string if None is given.

    :param et_node: Element or None
    :param default: string returned if None is given, default ``''``
    :type et_node: xml.etree.ElementTree.Element, None
    :type default: str
    :return: text from node or default
    :rtype: str
    """

    return str(et_node.text).strip() if et_node is not None and et_node.text else default
def et_node_to_string ( et_node , default = '' ) : return str ( et_node . text ) . strip ( ) if et_node is not None and et_node . text else default
Simple method to get stripped text from node or ``default`` string if None is given.

    :param et_node: Element or None
    :param default: string returned if None is given, default ``''``
    :type et_node: xml.etree.ElementTree.Element, None
    :type default: str
    :return: text from node or default
    :rtype: str