code: def task_ref_role(name, rawtext, text, lineno, inliner,
                    options=None, content=None):
      
      # app = inliner.document.settings.env.app
      node = pending_task_xref(rawsource=text)
      return [node], []
docs: Process a role that references the target nodes created by the
      ``lsst-task`` directive.
  
      Parameters
      ----------
      name
          The role name used in the document.
      rawtext
          The entire markup snippet, with role.
      text
          The text marked with the role.
      lineno
          The line number where ``rawtext`` appears in the input.
      inliner
          The inliner instance that called us.
      options
          Directive options for customization.
      content
          The directive content for customization.
  
      Returns
      -------
      nodes : `list`
          List of nodes to insert into the document.
      messages : `list`
          List of system messages.