-
-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
InvalidDistribution error for whl from pyo3/maturin 0.23.3 #310
Comments
Right. @woodruffw mentioned that it might not be. It'd be useful to get the steps for making a wheel for the reproducer documented. Then, I could think of running that in CI. |
Minimal reproducer: Dockerfile: # syntax=docker/dockerfile:1
FROM rust:1.83 AS build
RUN wget https://github.com/PyO3/maturin/releases/download/v1.7.6/maturin-x86_64-unknown-linux-musl.tar.gz \
&& tar xf maturin-*.tar.gz && mv maturin /usr/local/bin/
WORKDIR /workdir
RUN cargo init
RUN echo 'pyo3 = { version = "0.23.3", features = ["extension-module"] }' >> Cargo.toml
RUN maturin build --release --out wheel/
FROM ghcr.io/pypa/gh-action-pypi-publish:unstable-v1
COPY --from=build /workdir/wheel ./wheel
RUN twine check ./wheel/*.whl run: $ docker build -t asd .
...
=> ERROR [stage-1 3/3] RUN twine check ./wheel/*.whl 0.9s
------
> [stage-1 3/3] RUN twine check ./wheel/*.whl:
0.852 Checking ./wheel/workdir-0.1.0-cp311-cp311-manylinux_2_34_x86_64.whl: ERROR InvalidDistribution: Metadata is missing required fields: Name,
0.856 Version.
0.856 Make sure the distribution includes the files where those fields are
0.856 specified, and is using a supported Metadata-Version: 1.0, 1.1, 1.2,
0.856 2.0, 2.1, 2.2, 2.3.
------
Dockerfile:13
--------------------
11 | FROM ghcr.io/pypa/gh-action-pypi-publish:unstable-v1
12 | COPY --from=build /workdir/wheel ./wheel
13 | >>> RUN twine check ./wheel/*.whl
14 |
--------------------
ERROR: failed to solve: process "/bin/sh -c twine check ./wheel/*.whl" did not complete successfully: exit code: 1 |
Ah yeah, I see what happened here -- we also need to explicitly bump pkginfo since pip/pip-compile didn't do it for us. I can send a PR for that in a bit. |
@woodruffw perhaps Twine should bump the lower requirement if v6 promises support for newer metadata? Or mention it in the changelog that the supported metadata versions depend on |
Another one of the I think the plan with future releases is to drop |
ack, thanks! |
Looks like twine upgrade in #309 is not enough, pkginfo upgrade required
unstable-v1 image hash = 83623c34c365
The text was updated successfully, but these errors were encountered: