fix
This commit is contained in:
parent
e6e3762768
commit
2d051a1881
@ -18,7 +18,7 @@ class QueuesException(Exception):
|
|||||||
class TasksHandlerMixin:
|
class TasksHandlerMixin:
|
||||||
def poll(self):
|
def poll(self):
|
||||||
while True:
|
while True:
|
||||||
response = requests.get(f'{QUEUES_URL}/api/v1/take', headers={'queue': self.queue_name})
|
response = requests.get(f'{QUEUES_URL}/api/v1/take', headers={'queue': self.queue_name}).json()
|
||||||
task = response.get('task')
|
task = response.get('task')
|
||||||
if not task:
|
if not task:
|
||||||
time.sleep(0.2)
|
time.sleep(0.2)
|
||||||
|
Loading…
Reference in New Issue
Block a user