docs: def convert_rst_to_basic_text(contents):
      """Convert restructured text to basic text output.
  
      This function removes most of the decorations added
      in restructured text.
  
      This function is used to generate documentation we
      can show to users in a cross platform manner.
  
      Basic indentation and list formatting are kept,
      but many RST features are removed (such as
      section underlines).
  
      """
      # The report_level override is so that we don't print anything
      # to stdout/stderr on rendering issues.
      converted = publish_string(
          contents, writer=BasicTextWriter(),
          settings_overrides={'report_level': 5})
      return converted.decode('utf-8')