Trying to run a few simple tasks via celery. The header of the workerfile looks like
from celery import Celery, group
from time import sleep
celery = Celery('workerprocess', broker='redis://localhost:6379/0', backend='redis://localhost:6379/0')
After passing the jobs, I am trying to read the results like this.
jobresult=group(signatureList).apply_async()
while not jobresult.ready():sleep(30) #Line 6
The code is running perfectly in my desktop. The configuration is Python 3.6.7 and 4.15.0-20-generic #21-Ubuntu SMP.
When I try to run the same thing on my staging server (with the worker node running there too in the background), #Line 6
above throws the following error.
kombu.exceptions.DecodeError: 'utf-8' codec can't decode byte 0x80 in position 0: invalid start byte
From the log, it appears the task is sent to the redis queue, is executed correctly, but the main process can not perform any operation on the jobresult variable to retrieve the output of the calculations. I have checked by pinging the redis-cli, and it echoes PONG. The server configuration (the ones which I think are relevant) are Python 3.5.2 and 4.4.0-89-generic #112-Ubuntu.
Since the task is already running in my local desktop, I guess it is a matter of dependency. But the error does not give any clue about what other libraries should I install, whether using PIP or apt-get. I looked up, Kombu (don't know what it does, but guess something important) and it is already installed. So how to resolve this?
This is the output from the redis-cli from a comment to the question. I am not sure what it means, though.
127.0.0.1:6379> lrange celery 0 0
(empty list or set)
127.0.0.1:6379>