“ImportError: file_cache is unavailable” when using Python client for Google service account file_cache

I am a bit late to the party here but I had a similar problem today and found the answer here

Solution to only the error : file_cache is unavailable when using oauth2client >= 4.0.0

Solution:

change your discovery.build() to have the field cache_discovery=False
i.e

discovery.build(api, version, http=http, cache_discovery=False)

Leave a Comment