uv/crates/uv-build-backend/src
konsti fb1b3232e8
Support modules with different casing in build backend (#12240)
Match the module name to its module directory with potentially different
casing.

For example, a package may have the dist-info-normalized package name
`pil_util`, but the importable module is named `PIL_util`.

We get the module name either as dist-info-normalized package name, or
explicitly from the user. For dist-info-normalizing a package name, the
rules are lowercasing, replacing `.` with `_` and replace `-` with `_`.
Since `.` and `-` are not allowed in module names, we can check whether
a directory name matches our expected module name by lowercasing it.

Fixes #12187

---------

Co-authored-by: Charlie Marsh <charlie.r.marsh@gmail.com>
2025-03-23 13:29:21 +00:00
..
lib.rs Support modules with different casing in build backend (#12240) 2025-03-23 13:29:21 +00:00
metadata.rs Allow overriding module name for uv build backend (#11884) 2025-03-07 15:20:00 +01:00
serde_verbatim.rs A minimal build backend for uv: uv_build (#11446) 2025-03-06 13:27:20 -06:00
source_dist.rs Allow overriding module name for uv build backend (#11884) 2025-03-07 15:20:00 +01:00
wheel.rs Support modules with different casing in build backend (#12240) 2025-03-23 13:29:21 +00:00