Skip to content

python_distribution should infer interpreter_constraints from [project].requires-python field in pyproject.toml #23417

@ndellosa95

Description

@ndellosa95

Is your feature request related to a problem? Please describe.
It is confusing/less than stellar user experience to have to populate the interpreter_constraints field in the target separately.

Describe the solution you'd like
Infer from pyproject.toml

Describe alternatives you've considered
Do we even need this field on the python_distribution target? Feels like maybe we could get rid of it and just rely on Python's packaging logic maybe?

Additional context
I thought this was an issue with [python].default_to_resolve_interpreter_constraints originally but then I realized it was the python_distribution target that had repo default interpreter constraints.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions