code: def deserialize(self, value, environment=None):
          
  
          value = self._resolve_value(value, environment)
  
          try:
              value = self._deserialize(value, environment)
  
              if self._validator is not None:
                  value = self._validator(self, value, environment)     # pylint: disable=E1102
  
          except exc.InvalidValue as ex:
              # just reraise
              raise
  
          except (exc.Invalid, ValueError, TypeError) as ex:
              # we convert a bare Invalid into InvalidValue
              raise exc.InvalidValue(self, value=value, origin=ex)
  
          return value
docs: Deserialize a value into a special application specific format or type.
  
          `value` can be `Missing`, `None` or something else.
  
          :param value: the value to be deserialized
          :param environment: additional environment