@staticmethod<EOL><INDENT>def _pool_put(pool_semaphore, tasks, put_to_pool_in, pool_size, id_self,is_stopping):<DEDENT>
log.debug('<STR_LIT>' % id_self)<EOL>last_tasks = {}<EOL>for task in range(tasks.lenght):<EOL><INDENT>last_tasks[task] = -<NUM_LIT:1><EOL><DEDENT>stop_tasks = []<EOL>while True:<EOL><INDENT>if is_stopping():<EOL><INDENT>log.debug('<STR_LIT>' %id_self)<EOL>tasks.stop()<EOL><DEDENT>try:<EOL><INDENT>log.debug('<STR_LIT>' %id_self)<EOL>task = next(tasks)<EOL>log.debug('<STR_LIT>' % id_self)<EOL><DEDENT>except StopIteration:<EOL><INDENT>stop_task = tasks.i <EOL>log.debug('<STR_LIT>' %(id_self, stop_task))<EOL>if stop_task not in stop_tasks:<EOL><INDENT>log.debug('<STR_LIT>' %(id_self, stop_task))<EOL>stop_tasks.append(stop_task)<EOL>pool_semaphore.acquire()<EOL>log.debug('<STR_LIT>' %(id_self, stop_task))<EOL>put_to_pool_in((stop_task, None, last_tasks[stop_task]))<EOL><DEDENT>if len(stop_tasks) == tasks.lenght:<EOL><INDENT>log.debug('<STR_LIT>' %id_self)<EOL>for _worker in range(pool_size):<EOL><INDENT>put_to_pool_in(None)<EOL><DEDENT>log.debug('<STR_LIT>' %(id_self, pool_size))<EOL>break<EOL><DEDENT>continue<EOL><DEDENT>last_tasks[tasks.i] = task[-<NUM_LIT:1>][<NUM_LIT:0>] <EOL>log.debug('<STR_LIT>' %(id_self, task))<EOL>pool_semaphore.acquire()<EOL>log.debug('<STR_LIT>' %(id_self, task))<EOL>put_to_pool_in(task)<EOL>log.debug('<STR_LIT>' %(id_self, task))<EOL><DEDENT>log.debug('<STR_LIT>' % id_self)<EOL>
(internal) Intended to be run in a seperate thread. Feeds tasks into 
to the pool whenever semaphore permits. Finishes if self._stopping is 
set.