code: def comparator(operator):
      
      @wraps(operator)
      def wrapper(self, other):
          if not isinstance(other, (VersionInfo, dict)):
              return NotImplemented
          return operator(self, other)
      return wrapper
docs: Wrap a VersionInfo binary op method in a type-check