You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 13, 2026. It is now read-only.
Any service using an older release of six will encounter this ImportError:
Traceback (most recent call last):
. . .
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/main.py", line 16, in <module>
from google.cloud import ndb
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/ndb/__init__.py", line 28, in <module>
from google.cloud.ndb.client import Client
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/ndb/client.py", line 26, in <module>
from google.cloud.datastore_v1.gapic import datastore_client
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/datastore_v1/__init__.py", line 18, in <module>
from google.cloud.datastore_v1.gapic import datastore_client
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/datastore_v1/gapic/datastore_client.py", line 39, in <module>
from google.cloud.datastore.version import __version__
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/datastore/__init__.py", line 60, in <module>
from google.cloud.datastore.client import Client
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/datastore/client.py", line 26, in <module>
from google.cloud.datastore._http import HTTPDatastoreAPI
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/datastore/_http.py", line 19, in <module>
from google.cloud import _http as connection_module
File "/base/data/home/apps/m~PROJECT_ID/20201117t171012.431016593202024462/lib/google/cloud/_http.py", line 22, in <module>
from six.moves import collections_abc
ImportError: cannot import name collections_abc
The current workaround is to reference the immediately preceding version by adding google-cloud-core==1.4.1 in any affected application's requirements.txt file until either App Engine revs six to a newer release (>=1.13.0), orLine 22 of google/cloud/_http.py is patched, perhaps with something like this:
# catch six<1.13.0
try:
from six.moves import collections_abc
except ImportError:
# catch python<3.3.0
try:
import collections.abc as collections_abc # only works on 3.3+
except ImportError:
import collections as collections_abc
six>=1.13.0and is in releases 1.4.2 & newer.sixwill encounter thisImportError:six==1.12.0is built-ingoogle-cloud-core==1.4.1in any affected application'srequirements.txtfile until either App Engine revssixto a newer release (>=1.13.0), or Line 22 of google/cloud/_http.py is patched, perhaps with something like this: