Breaking change for google-api-python-client 1.8.1 - AttributeError: module 'googleapiclient' has no attribute '__version__'
Environment details
- Python version: python-3.8.2
- pip version: pip-9.0.1
google-api-python-clientversion: 1.8.1
Steps to reproduce
Dependencies: Flask==1.1.1 werkzeug==1.0
Application server for both development and production.
gunicorn==19.9.0
Testing and static analysis.
pytest==5.1.0 pytest-cov==2.7.1 mock==3.0.5 flake8==3.7.8
CLI.
Click==6.4
Data and workers.
psycopg2==2.6.1
psycopg2==2.8.4 Flask-SQLAlchemy==2.4.1 SQLAlchemy==1.3.7 redis==3.3.11 celery==4.4.0
Forms.
Flask-WTF==0.14.3 WTForms-Components==0.10.4 WTForms-Alchemy==0.16.9
Utils.
fake-factory==0.5.7
faker==3.0.0
Extensions.
flask-debugtoolbar==0.10.1 Flask-Mail==0.9.1 Flask-Login==0.4.1
Payments.
stripe==2.41.0 gocardless_pro==1.10.0
Google API requirements
google-api-core==1.16.0 google-api-python-client==1.8.0 httplib2 oauth2client google-auth-oauthlib==0.4.1 google-cloud-pubsub==1.4.3
google-auth-httplib2
google-auth
- Running docker-compose with docker container python:3.8.1-slim-buster
Stack trace
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/gunicorn/arbiter.py", line 583, in spawn_worker
worker.init_process()
File "/usr/local/lib/python3.8/site-packages/gunicorn/workers/base.py", line 129, in init_process
self.load_wsgi()
File "/usr/local/lib/python3.8/site-packages/gunicorn/workers/base.py", line 138, in load_wsgi
self.wsgi = self.app.wsgi()
File "/usr/local/lib/python3.8/site-packages/gunicorn/app/base.py", line 67, in wsgi
self.callable = self.load()
File "/usr/local/lib/python3.8/site-packages/gunicorn/app/wsgiapp.py", line 52, in load
return self.load_wsgiapp()
File "/usr/local/lib/python3.8/site-packages/gunicorn/app/wsgiapp.py", line 41, in load_wsgiapp
return util.import_app(self.app_uri)
File "/usr/local/lib/python3.8/site-packages/gunicorn/util.py", line 350, in import_app
import(module)
File "/prosebit/prosebit/app.py", line 10, in
Thanks!
I just got this too:
Traceback (most recent call last):
File "foo.py", line 8, in <module>
from apiclient.discovery import build
File "/home/runner/.local/lib/python3.6/site-packages/apiclient/__init__.py", line 22, in <module>
__version__ = googleapiclient.__version__
AttributeError: module 'googleapiclient' has no attribute '__version__'
Edit: just noticed this is a duplicate of #870
just started this am
import apiclient
--
21-Apr-2020 13:12:17 | File "/usr/local/lib/python3.6/dist-packages/apiclient/__init__.py", line 22, in <module>
21-Apr-2020 13:12:17 | __version__ = googleapiclient.__version__
21-Apr-2020 13:12:17 | AttributeError: module 'googleapiclient' has no attribute '__version__'
Closing as this is a duplicate of #870. A fix has been merged and will be released today.
Fix is in 1.8.2