code: def validate_queues(queues):
      
      if not isinstance(queues, dict):
          raise exceptions.ConfigurationException(
              "'queues' must be a dictionary mapping queue names to settings."
          )
  
      for queue, settings in queues.items():
          if not isinstance(settings, dict):
              raise exceptions.ConfigurationException(
                  "the {} queue in the 'queues' setting has a value of type {}, but it "
                  "should be a dictionary of settings.".format(queue, type(settings))
              )
          missing_keys = []
          for key in ("durable", "auto_delete", "exclusive", "arguments"):
              if key not in settings:
                  missing_keys.append(key)
          if missing_keys:
              raise exceptions.ConfigurationException(
                  "the {} queue is missing the following keys from its settings "
                  "value: {}".format(queue, missing_keys)
              )
docs: Validate the queues configuration.
  
      Raises:
          exceptions.ConfigurationException: If the configuration provided is of an
              invalid format.