docs: def docpie(self, argv=None):
          """match the argv for each usages, return dict.
  
          if argv is None, it will use sys.argv instead.
          if argv is str, it will call argv.split() first.
          this function will check the options in self.extra and handle it first.
          Which means it may not try to match any usages because of the checking.
          """
  
          token = self._prepare_token(argv)
          # check first, raise after
          # so `-hwhatever` can trigger `-h` first
          self.check_flag_and_handler(token)
  
          if token.error is not None:
              # raise DocpieExit('%s\n\n%s' % (token.error, help_msg))
              self.exception_handler(token.error)
  
          try:
              result, dashed = self._match(token)
          except DocpieExit as e:
              self.exception_handler(e)
  
          # if error is not None:
          #     self.exception_handler(error)
  
          value = result.get_value(self.appeared_only, False)
          self.clear()
          self.update(value)
          if self.appeared_only:
              self._drop_non_appeared()
  
          logger.debug('get all matched value %s', self)
          rest = list(self.usages)  # a copy
          rest.remove(result)
          self._add_rest_value(rest)
          logger.debug('merged rest values, now %s', self)
          self._add_option_value()
          self._dashes_value(dashed)
  
          return dict(self)