python - 具有上游 pypi 的 AWS Codeartifact 未获取最新版本
问题描述
我有一个 python Codeartifact 存储库,它有一个上游 PyPI 存储库。在 PyPI 中,一个新版本的库(google-auth 2.3.1)于 10 月 25 日发布,但每当我尝试通过 Codeartifact 安装它时,最新的可用版本是 2.3.0。
有没有办法告诉 Codeartifact 上游有更新的版本?Codeartifact 在 PyPI 中获取更新需要多长时间?这是我从 AWS 找到的唯一来源,它指出这可能发生,但没有解决方法:https ://docs.aws.amazon.com/codeartifact/latest/ug/external-connection.html#external-connection-不可用
错误信息:
ERROR: No matching distribution found for google-authpip3 install google-auth==2.3.1
Looking in indexes: https://aws:****@packages-****.d.codeartifact.eu-central-1.amazonaws.com/pypi/common/simple/
ERROR: Could not find a version that satisfies the requirement google-auth==2.3.1 (from versions: 0.0.1, 0.1.0, 0.2.0, 0.3.0, 0.3.1, 0.3.2, 0.4.0, 0.5.0, 0.6.0, 0.7.0, 0.8.0, 0.9.0, 0.10.0, 1.0.0, 1.0.1, 1.0.2, 1.1.0, 1.1.1, 1.2.0, 1.2.1, 1.3.0, 1.4.0, 1.4.1, 1.4.2, 1.5.0, 1.5.1, 1.6.0, 1.6.1, 1.6.2, 1.6.3, 1.7.0, 1.7.1, 1.7.2, 1.8.0, 1.8.1, 1.8.2, 1.9.0, 1.10.0, 1.10.1, 1.10.2, 1.11.0, 1.11.1, 1.11.2, 1.11.3, 1.12.0, 1.13.0, 1.13.1, 1.14.0, 1.14.1, 1.14.2, 1.14.3, 1.15.0, 1.16.0, 1.16.1, 1.17.0, 1.17.1, 1.17.2, 1.18.0, 1.19.0, 1.19.1, 1.19.2, 1.20.0, 1.20.1, 1.21.0, 1.21.1, 1.21.2, 1.21.3, 1.22.0, 1.22.1, 1.23.0, 1.24.0, 1.25.0, 1.26.0, 1.26.1, 1.27.0, 1.27.1, 1.28.0, 1.28.1, 1.29.0, 1.30.0, 1.30.1, 1.30.2, 1.31.0, 1.32.0, 1.32.1, 1.33.0, 1.33.1, 1.34.0, 1.35.0, 2.0.0.dev0, 2.0.0b1, 2.0.0, 2.0.1, 2.0.2, 2.1.0, 2.2.0, 2.2.1, 2.3.0)
解决方案
现在适合我的解决方案:
- 如果不可用则创建 venv
python3 -m venv .venv
- 激活它
source .venv/bin/activate
- 安装日志语句中给出的包,例如
pip install google-authpip3 --no-cache
- 再次运行诗歌
poetry install
- 如果出现更多错误,请继续 3)
我的假设是,本地 pip/诗歌缓存不是最新的。所以我强制 pip 获取最新版本
推荐阅读
- c++ - 如何提高 iOS 上 std::sin 函数的精度
- html - 保持段落标签中的多行均匀对齐
- javascript - 使用 Promise 和 xhr 复制 fetch - JavaScript
- consul - 使用预先分配的 secretID 创建 consul ACL 令牌(1.4 系统)
- vb.net - 填写 PDF 和打印 PDF 时出现问题
- r - gpuR - 求解矩阵
- google-sheets - 复制一个范围的特定选择/不相邻的单元格并以相同的顺序粘贴到另一个范围内
- javascript - 即使在使用的测试中未使用 jest.mock('request-promise-native') 时,Jest 手动模拟也始终用于 request-promise-native
- python - 使用 Pandas join 填充列
- java - 如何从android中的颜色标签获取颜色代码