code: def unwrap(self, value, session=None):
          ''' Unwrap value using the unwrap function from ``EnumField.item_type``.
              Since unwrap validation could not happen in is_valid_wrap, it
              happens in this function.'''
          self.validate_unwrap(value)
          value = self.item_type.unwrap(value, session=session)
          for val in self.values:
              if val == value:
                  return val
          self._fail_validation(value, 'Value was not in the enum values'f unwrap(self, value, session=None):
          ''' Unwrap value using the unwrap function from ``EnumField.item_type``.
              Since unwrap validation could not happen in is_valid_wrap, it
              happens in this function.'''
          self.validate_unwrap(value)
          value = self.item_type.unwrap(value, session=session)
          for val in self.values:
              if val == value:
                  return val
          self._fail_validation(value, 'Value was not in the enum values')
docs: Unwrap value using the unwrap function from ``EnumField.item_type``.
              Since unwrap validation could not happen in is_valid_wrap, it
              happens in this function.