pylock.toml export drops wheels when the sdist sorts between wheels
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 35/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 停滞
- 技术栈
- python
- 领域
- backend, build-system
调研方向
Inspect Exporter._export_pylock_toml and the grouping of package.files; the report identifies itertools.groupby and the dict comprehension as the failure path. Reproduce with ruamel.yaml.clib 0.2.14 and confirm the exported wheels array includes all 56 wheels. Check the issue’s linked pull request #379 for work already underway.
由索引模型根据 Issue 内容生成。
描述
poetry export --format pylock.toml can leave wheels out of packages.wheels.
Exporter._export_pylock_toml splits package.files into sdists and wheels with itertools.groupby. groupby only groups consecutive items, and the lock file sorts files by file name. If the sdist file name sorts between wheel file names, groupby returns two "wheel" groups. The dict comprehension keeps only the last group, so every wheel before the sdist is missing from the exported file.
This happens with real packages whose wheel file names use different name normalizations. For example, ruamel.yaml.clib 0.2.14 has these files on PyPI, in lock file order:
ruamel.yaml.clib-0.2.14-cp310-cp310-macosx_10_9_universal2.whl
... (54 wheels named ruamel.yaml.clib-*)
ruamel.yaml.clib-0.2.14.tar.gz
ruamel_yaml_clib-0.2.14-cp314-cp314-win_amd64.whl
... (2 wheels named ruamel_yaml_clib-*)
The exported pylock.toml lists only the last 2 wheels. Installers that use the file then fall back to building the sdist on every platform that the 54 dropped wheels cover.
Steps to reproduce
- Lock a project that depends on
ruamel.yaml.clib==0.2.14with lock file format 2.1. - Run
poetry export --format pylock.toml --output pylock.toml. - Check the
wheelsarray of theruamel-yaml-clibpackage.
Expected: all 56 wheels from the lock file.
Actual: only the 2 ruamel_yaml_clib-* wheels.
Environment
- poetry-plugin-export: main (cc06037), 1.10.1
- Poetry: 2.5.1
- 主要语言
- Python
- 星标
- 336
- 派生
- 60
- 平均合并
- 10 分钟
- 30 天内合并 PR
- 1
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
python-poetry/poetry-plugin-export 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 45/100
-
难度 3/5 1-2 天 新手友好度 48/100
-
Does not install未关闭
难度 4/5 3-5 天 新手友好度 35/100
python-poetry/poetry-plugin-export#341 · 5 条评论 · 1 个 reaction ·
-
难度 3/5 1-2 天 新手友好度 42/100
python-poetry/poetry-plugin-export#340 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 52/100
查看 python-poetry/poetry-plugin-export 的全部 Issue
相似的 Issue
-
LLVM versions未关闭
难度 2/5 1-3 小时 新手友好度 67/100
维护者通常 1 天内回复
-
documentation good first issue language
难度 2/5 1-3 小时 新手友好度 91/100
-
good first issue help wanted translation
难度 2/5 1-3 小时 新手友好度 75/100
-
难度 2/5 1-3 小时 新手友好度 84/100
维护者通常 1 天内回复
-
Fix duplicated word in speculative decoding docs可能已有人在做 @ddlw 今天认领。 未关闭community-request
难度 1/5 1 小时以内 新手友好度 89/100
NVIDIA/Megatron-LM#9118 ·
维护者通常 2 天内回复