Hi @gi0baro ,
I have an error with python 3.13
2.990 Γ Preparing metadata (pyproject.toml) did not run successfully.
2.990 β exit code: 1
2.990 β°β> [13 lines of output]
2.990 error: failed to run `rustc` to learn about target-specific information
2.990
2.990 Caused by:
2.990 process didn't exit successfully: `/root/.rustup/toolchains/nightly-aarch64-unknown-linux-gnu/bin/rustc - --crate-name ___ --print=file-names -C --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=split-debuginfo --print=crate-name --print=cfg` (exit status: 1)
2.990 --- stderr
2.990 error: unknown codegen option: `--crate-type`
2.990
2.990 π₯ maturin failed
2.990 Caused by: Cargo metadata failed. Does your crate compile with `cargo build`?
2.990 Caused by: `cargo metadata` exited with an error:
2.990 Error running maturin: Command '['maturin', 'pep517', 'write-dist-info', '--metadata-directory', '/tmp/pip-modern-metadata-9kfw5xiz', '--interpreter', '/usr/local/bin/python3.13']' returned non-zero exit status 1.
2.990 Checking for Rust toolchain....
2.990 Running `maturin pep517 write-dist-info --metadata-directory /tmp/pip-modern-metadata-9kfw5xiz --interpreter /usr/local/bin/python3.13`
2.990 [end of output]
2.990
2.990 note: This error originates from a subprocess, and is likely not a problem with pip.
3.193 error: metadata-generation-failed
3.193
3.193 Γ Encountered error while generating package metadata.
3.193 β°β> See above for output.
3.193
3.193 note: This is an issue with the package mentioned above, not pip.
3.193 hint: See above for details.
I use the following dockerfile
FROM python:3.13-slim
WORKDIR /usr/src/app
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get -y update
RUN apt-get -y install libffi-dev
RUN apt-get -y install libssl-dev
RUN apt-get -y install curl
COPY server.py server.py
COPY pyproject.toml pyproject.toml
RUN curl https://sh.rustup.rs > init.sh
RUN sh init.sh -y
RUN find $HOME/.cargo/bin -type f -exec install {} /usr/local/bin \;
RUN rustup default nightly
ENV RUSTFLAGS=-C target-feature=-crt-static
RUN pip install .
CMD emmett serve --host 0.0.0.0 --port 3000 --workers $(nproc)
The codebase is https://github.com/the-benchmarker/web-frameworks/blob/master/python/emmett/server.py
this is working fine with 3.12
any idea ?
Regards,
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too