python - boto3、aiobotocore、awscli 和 botocore 的版本不兼容;无法解决

标签 python amazon-web-services boto3 aws-cli botocore

如果我尝试安装最新版本的 aiobotocore pip3 install aiobotocore==0.10.3它说我的 botocore 版本不兼容,我需要它的旧版本。

ERROR: aiobotocore 0.10.3 has requirement botocore<1.12.190,>=1.12.189, but you'll have botocore 1.12.224 which is incompatible.

因此,如果我将 botocore 的版本更改为 1.12.189,它会中断 awscliboto3
ERROR: boto3 1.9.224 has requirement botocore<1.13.0,>=1.12.224, but you'll have botocore 1.12.189 which is incompatible.
ERROR: awscli 1.16.234 has requirement botocore==1.12.224, but you'll have botocore 1.12.189 which is incompatible.

似乎没有可以与它们一起使用的软件包版本。有人能告诉我什么版本都兼容吗?有没有办法让 pip 自动确定这一点?

最佳答案

试试 aioboto3而不是 boto3 ?
添加到 requirements.in

aioboto3
aiobotocore
赶紧跑
 python3.8 -m pip install pip --upgrade
 python3.8 -m pip install pip-tools
 python3.8 -m piptools compile requirements.in
你会得到类似的东西
#
# This file is autogenerated by pip-compile
# To update, run:
#
#    pip-compile requirements.in
#
aioboto3==8.0.5           # via -r requirements.in
aiobotocore==1.0.4        # via -r requirements.in, aioboto3
aiohttp==3.6.2            # via aiobotocore
aioitertools==0.7.0       # via aiobotocore
async-timeout==3.0.1      # via aiohttp
attrs==19.3.0             # via aiohttp
boto3==1.12.32            # via aiobotocore
botocore==1.15.32         # via aiobotocore, boto3, s3transfer
chardet==3.0.4            # via aiohttp
docutils==0.15.2          # via botocore
idna==2.10                # via yarl
jmespath==0.10.0          # via boto3, botocore
multidict==4.7.6          # via aiohttp, yarl
python-dateutil==2.8.1    # via botocore
s3transfer==0.3.3         # via boto3
six==1.15.0               # via python-dateutil
typing-extensions==3.7.4.2  # via aioitertools
urllib3==1.25.10          # via botocore
wrapt==1.12.1             # via aiobotocore
yarl==1.5.1               # via aiohttp

关于python - boto3、aiobotocore、awscli 和 botocore 的版本不兼容;无法解决,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57830582/

相关文章:

python - 如果字符串以特定值 Pandas 数据框结尾,则替换值

python - 在 python 中拆分字符串

amazon-web-services - aws 引用代码 - 不工作 - 无法访问 S3 图像

amazon-web-services - 如何为aws log groups找到相应的资源?

python - 为什么 .pyc 文件有时在同一目录中创建,有时在 __pycache__ 子目录中创建?

Python:创建一系列有序数字,跳过第 N 个到第 N+D 个数字的倒数

amazon-web-services - 捕获 eventBridge 中不匹配任何规则的事件

amazon-web-services - 如何让一个 Kubernetes LoadBalancer 平衡多个服务?

python - 您如何将 KeyManager 添加到使用 moto 模拟的 kms key 中

amazon-web-services - 如何更改 aws-ec2 实例类型?