Я не могу установить установить firebase-admin - PullRequest
0 голосов
/ 21 февраля 2020

У меня ошибка следующая:

MacBook-Air:Firebase takeyuki$ python -m pip install --upgrade firebase-admin
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.

... some lines are omitted ...

Installing collected packages: futures, googleapis-common-protos, grpcio, google-api-core, uritemplate, httplib2, google-auth-httplib2, google-api-python-client, google-cloud-core, google-resumable-media, google-cloud-storage, google-cloud-firestore, msgpack, cachecontrol, firebase-admin
  Found existing installation: futures 3.0.3
Cannot uninstall 'futures'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.

В этом сообщении упоминается, что futures модуль, похоже, не принадлежит пипу, но

MacBook-Air:Firebase takeyuki$ python -m pip list | grep futures
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
futures                            3.0.3     

Итак, как я могу это исправить? Спасибо за ваше предложение!

1 Ответ

1 голос
/ 21 февраля 2020

Не могли бы вы попробовать следующие шаги?

pip install --upgrade --force-reinstall pip==20.0.0
pip install futures --disable-pip-version-check
pip install --upgrade pip

Другой вариант - работать в virtualenv:

pip install virtualenv
virtualenv -p python venv
source venv/bin/activate
python pip install firebase-admin

Обновление: опция, которая действительно работала:

pip install --ignore-installed futures
...