          self.shutdown = threading.Event()
          self.queues = dict()
          logger.debug("Initialized %s", self.__class__.__name__)
  
      def add_queue(self, name, maxsize=0):
          """ Add a queue to the manager
  
              Adds an event "shutdown" to the queue that can be used to indicate
              to a process that any activity on the queue should cease """
  
          logger.debug("QueueManager adding: (name: '%s', maxsize: %s)", name, maxsize)
          if name in self.queues.keys():
              raise ValueError("Queue '{}' already exists.".format(name))
  
          queue = Queue(maxsize=maxsize)
  
          setattr(queue, "shutdown", self.shutdown)
 
</s> remove         self._queue = queue_manager.get_queue(name=self.__class__.__name__, maxsize=queue_size)
 </s> add         queue_name = queue_manager.add_queue(name=self.__class__.__name__,
                                             maxsize=queue_size,
                                             create_new=True)
        self._queue = queue_manager.get_queue(queue_name) </s> remove         else:
            self._extractor_input_thread.join()
 </s> add         self._extractor_input_thread.join()
        if self._saver is not None: </s> remove         for q_name in self.queues.keys():
 </s> add         for q_name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
          self.shutdown = threading.Event()
          self.queues = dict()
          logger.debug("Initialized %s", self.__class__.__name__)
  
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
    def add_queue(self, name, maxsize=0, create_new=False):
        """ Add a queue to the manager.

        Adds an event "shutdown" to the queue that can be used to indicate to a process that any
        activity on the queue should cease.

        Parameters
        ----------
        name: str
            The name of the queue to create
        maxsize: int, optional
            The maximum queue size. Set to `0` for unlimited. Default: `0`
        create_new: bool, optional
            If a queue of the given name exists, and this value is ``False``, then an error is
            raised preventing the creation of duplicate queues. If this value is ``True`` and
            the given name exists then an integer is appended to the end of the queue name and
            incremented until the given name is unique. Default: ``False``

        Returns
        -------
        str
            The final generated name for the queue
        """
        logger.debug("QueueManager adding: (name: '%s', maxsize: %s, create_new: %s)",
                     name, maxsize, create_new)
        if not create_new and name in self.queues:
              raise ValueError("Queue '{}' already exists.".format(name))
  
          queue = Queue(maxsize=maxsize)
  
          setattr(queue, "shutdown", self.shutdown)
keep keep keep keep replace replace replace replace replace replace replace replace keep keep keep keep keep
 bugfix: lib.image ImageIO. Ensure unique queues are created 
lib/queue_manager.py