code: def _validate_choices(options):
      
  
      def func(value):
          if value not in options:
              raise click.BadParameter(
                  'Possible choices are: {0}.'.format(', '.join(options))
              )
          return value
  
      return func
docs: Callback wrapper for validating click.prompt input.
  
      Parameters
      ----------
      options : list
          List of allowed choices
  
      Returns
      -------
      :func:`callable`
          callback function for value_proc in :func:`click.prompt`.
  
      Raises
      ------
      :class:`click.BadParameter`