code: def positive_int(string):
      
      error_msg = 'Positive integer required, {string} given.'.format(string=string)
      try:
          value = int(string)
      except ValueError:
          raise ArgumentTypeError(error_msg)
      if value < 0:
          raise ArgumentTypeError(error_msg)
      return value
docs: Convert string to positive integer.