GCP SDK won't install with latest Python from Python.org

Documentation claims that any Python 3.X is supported. However install script in google-cloud-sdk-364.0.0-darwin-arm.tar.gz with latest Python 3.10 from python.org fails with the following error message below. This is with a clean Monterrey install on a latest gen MBP with Arm.

Others have noted this issue as well, e.g.:

https://issueexplorer.com/issue/GoogleCloudPlatform/gsutil/1331

Any workarounds or ETA for a fix?


appenz@MBP14inch2021 google-cloud-sdk % ./install.sh

Welcome to the Google Cloud SDK!

Traceback (most recent call last):

File “/Users/appenz/dev/google-cloud-sdk/bin/bootstrapping/install.py”, line 12, in

import bootstrapping

File “/Users/appenz/dev/google-cloud-sdk/bin/bootstrapping/bootstrapping.py”, line 46, in

from googlecloudsdk.core.updater import update_manager

File “/Users/appenz/dev/google-cloud-sdk/lib/googlecloudsdk/core/updater/update_manager.py”, line 39, in

from googlecloudsdk.core.console import progress_tracker

File “/Users/appenz/dev/google-cloud-sdk/lib/googlecloudsdk/core/console/progress_tracker.py”, line 651, in

class _BaseStagedProgressTracker(collections.Mapping):

AttributeError: module ‘collections’ has no attribute ‘Mapping’

If it’s an issue with the Python version being too new, perhaps you can consider using pyenv to manage multiple Python versions. If it’s a Monterrey issue then shrug (I remembered I upgraded to Big Sur when it got released and Brew wasn’t compatible with it yet. It took a few weeks for that to come thru I think…)

Good luck!

I’ll give it a try. I’d suggest to update the Google GCP SDK documentation though noting that it is not compatible with the current version of Python.