code: def specs_to_string(specs):
      # type: (List[Union[STRING_TYPE, Specifier]]) -> AnyStr
      
  
      if specs:
          if isinstance(specs, six.string_types):
              return specs
          try:
              extras = ",".join(["".join(spec) for spec in specs])
          except TypeError:
              extras = ",".join(["".join(spec._spec) for spec in specs])  # type: ignore
          return extras
      return ""
docs: Turn a list of specifier tuples into a string