code: def find_by_attr(node, value, name="name", maxlevel=None):
      
      return _find(node, filter_=lambda n: _filter_by_name(n, name, value),
                   maxlevel=maxlevel)
docs: Search for *single* node with attribute `name` having `value` but stop at `maxlevel`.
  
      Return tuple with matching nodes.
  
      Args:
          node: top node, start searching.
          value: value which need to match
  
  
      Keyword Args:
          name (str): attribute name need to match
          maxlevel (int): maximum decending in the node hierarchy.
  
      Example tree:
  
      >>> from anytree import Node, RenderTree, AsciiStyle
      >>> f = Node("f")
      >>> b = Node("b", parent=f)
      >>> a = Node("a", parent=b)
      >>> d = Node("d", parent=b)
      >>> c = Node("c", parent=d, foo=4)
      >>> e = Node("e", parent=d)
      >>> g = Node("g", parent=f)
      >>> i = Node("i", parent=g)
      >>> h = Node("h", parent=i)
      >>> print(RenderTree(f, style=AsciiStyle()).by_attr())
      f
      |-- b
      |   |-- a
      |   +-- d
      |       |-- c
      |       +-- e
      +-- g
          +-- i
              +-- h
  
      >>> find_by_attr(f, "d")
      Node('/f/b/d')
      >>> find_by_attr(f, name="foo", value=4)
      Node('/f/b/d/c', foo=4)
      >>> find_by_attr(f, name="foo", value=8)