docs: def _cleandoc(doc):
      """Remove uniform indents from ``doc`` lines that are not empty
  
      :returns: Cleaned ``doc``
      """
      indent_length = lambda s: len(s) - len(s.lstrip(" "))
      not_empty = lambda s: s != ""
  
      lines = doc.split("\n")
      indent = min(map(indent_length, filter(not_empty, lines)))
  
      return "\n".join(s[indent:] for s in lines)