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

Support build system requirements #2794

Closed
wants to merge 4 commits into from

Conversation

abn
Copy link
Member

@abn abn commented Aug 10, 2020

This change adds support of build requirements. This is implemented such that build requirements are always installed on poetry install and poetry install --no-dev since the package installation will require build-system.requires packages. When poetry build is executed, existing behaviour is retained for cases where additional build requirements are not required. If additional, dependencies are required (eg: cython) these and only these are installed before build and environment executable is configured for use when build script is executed.

Resolves: #2789

Requires: #2732 python-poetry/poetry-core#58

  • Added tests for changed code.
  • Updated documentation for changed code.

Prior to this change, when checking solver results the tests cases
relied on the weaker equality check of the `Package` class. With
python-poetry/poetry-core#53, the check has been made stricter.

This change, while having no functional impact, ensures that once
poetry-core is updated, tests do not fail unexpectedly.
@abn abn added the status/waiting-on-core Requires changes to poetry-core first label Aug 10, 2020
@mdgoldberg
Copy link

Any updates here @abn ? Is this still being developed?

@schneiderfelipe
Copy link

Any updates on this?

@abn
Copy link
Member Author

abn commented Oct 30, 2021

@mdgoldberg @schneiderfelipe I am guessing there is still interest in this? I have had some push backs from core about this. But happy to push it forward.

@abn abn self-assigned this Oct 30, 2021
@schneiderfelipe
Copy link

@mdgoldberg @schneiderfelipe I am guessing there is still interest in this? I have had some push backs from core about this. But happy to push it forward.

Very much interested. Out of curiosity, what's holding this back?

@espdev
Copy link

espdev commented Oct 31, 2021

@abn,
Support of build dependencies is very much needed. Please see my last comment:
#2789 (comment)

@GuillaumeDesforges
Copy link

@abn are you still on this? Would be very helpful 🙂

@abn
Copy link
Member Author

abn commented Mar 16, 2022

@GuillaumeDesforges guess now I am :D unfortunately python-poetry/poetry-core#58 got a bit stuck. Let me have a rethink with the new groups changes. The appraoch I took there will no longer really work. Since "dev" is not necesarily a group that is always going to be present.

That said, in the interim I would recommend you redefine the dependency like so.

poetry add --group build 'cpython@*'

Or use the TOML.

[tool.poetry.group.build.dependencies]
cpython = "*"

Personally, I do not like that I'd have to re-specify the dependency, but that is where it is at present.

@abn
Copy link
Member Author

abn commented May 2, 2022

Closing this in favour of #5401 for now as the core issue was stuck without concensus.

@abn abn closed this May 2, 2022
Copy link

This pull request 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
status/waiting-on-core Requires changes to poetry-core first
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Poetry build does not install build dependencies (affects both install and build)
5 participants