Skip to content
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

WheelBuilder copies from first folder named "lib.*" - which may not be the correct one #8390

Closed
4 tasks done
robbotorigami opened this issue Aug 30, 2023 · 2 comments · Fixed by python-poetry/poetry-core#634
Labels
area/build-system Related to PEP 517 packaging (see poetry-core) kind/bug Something isn't working as expected

Comments

@robbotorigami
Copy link

  • Poetry version: poetry-core==1.7.0
  • I am on the latest stable Poetry version, installed using a recommended method.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • I have consulted the FAQ and blog for any relevant entries or release notes.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option) and have included the output below.

Issue

in the WheelBuilder._build method the built library folder is detected by looking for the first folder matching lib.*:

libs: list[Path] = list(build_dir.glob("lib.*"))
...
lib = libs[0]

This works on a clean build, but may cause issues for a project with multiple build targets. E.g. on a project I have, the build directory looks like:

build
    > lib.linux-x86_64-cpython-39
    > lib.linux-x86_64-cpython-311

When a wheel is built targeting 3.11, poetry-core will incorrectly include the 3.9 libraries.

This probably isn't a high-priority issue since there's an easy work-around of just ensuring your build directory is cleaned prior to building the wheel.

If I have time later this week I can probably make a fix/PR for this issue.

@robbotorigami robbotorigami added kind/bug Something isn't working as expected status/triage This issue needs to be triaged labels Aug 30, 2023
@dimbleby
Copy link
Contributor

related #6197 in which generated files are put in plain lib and consequently omitted from the package - if you intend to tackle this then it would be good to kill two birds with one stone

@radoering radoering added area/build-system Related to PEP 517 packaging (see poetry-core) and removed status/triage This issue needs to be triaged labels Sep 10, 2023
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 29, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area/build-system Related to PEP 517 packaging (see poetry-core) kind/bug Something isn't working as expected
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants