nodes: 0, module; 1, function_definition; 2, function_name:all; 3, parameters; 4, block; 5, expression_statement; 6, return_statement; 7, comment:"""Returns all active registered goals, sorted alphabetically by name.
  
      :API: public
      """; 8, list_comprehension; 9, identifier:goal; 10, for_in_clause; 11, if_clause; 12, pattern_list; 13, call; 14, attribute; 15, identifier:_; 16, identifier:goal; 17, identifier:sorted; 18, argument_list; 19, identifier:goal; 20, identifier:active; 21, call; 22, attribute; 23, argument_list; 24, attribute; 25, identifier:items; 26, identifier:Goal; 27, identifier:_goal_by_name
code: def all():
      """Returns all active registered goals, sorted alphabetically by name.
  
      :API: public
      """
      return [goal for _, goal in sorted(Goal._goal_by_name.items()) if goal.active]