On dockerized deployment, The worker node is not initialising. It gives the following error:
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/celery/utils/dispatch/signal.py", line 288, in send
response = receiver(signal=self, sender=sender, **named)
File "/app/redash/worker.py", line 80, in init_celery_flask_app
app = safe_create_app()
File "/app/redash/__init__.py", line 151, in safe_create_app
return create_app()
File "/app/redash/__init__.py", line 136, in create_app
setup_authentication(app)
File "/app/redash/authentication/__init__.py", line 236, in setup_authentication
from redash.authentication import google_oauth, saml_auth, remote_user_auth, ldap_auth
File "/app/redash/authentication/google_oauth.py", line 4, in <module>
from flask_oauthlib.client import OAuth
File "/usr/local/lib/python2.7/dist-packages/flask_oauthlib/client.py", line 20, in <module>
from .utils import to_bytes
File "/usr/local/lib/python2.7/dist-packages/flask_oauthlib/utils.py", line 5, in <module>
from oauthlib.common import to_unicode, bytes_type
ImportError: cannot import name bytes_type
The deployment works locally on minikube, but this error is reported on GKE.
A summary of the issue and the browser/OS environment in which it occurs.
For builiding the image i first built a base image using dockerfile here
I changed the Dockerfile provided in the repository to reference my locally built base image and used that as the final image.
I compared the output of pip freeze on my local _working_ minikube instance vs deployed instance and found version differences in the requests and requests-oauthlib.
Versions in my local copy:
python-dateutil==2.4.2
python-editor==1.0.3
python-geoip==1.2
requests-oauthlib==1.0.0
oauthlib==2.1.0
Versions in GKE:
requests-oauthlib==1.1.0
oauthlib==3.0.0
This was fixed here: https://github.com/getredash/redash/pull/3262.
Thanks, verified that its working now (y)
Most helpful comment
This was fixed here: https://github.com/getredash/redash/pull/3262.