Skip to content

Incorrect syntax for single-line entries in setup.cfg -> [options.extras_require] generates invalid METADATA #2553

Closed
@pwoolvett

Description

@pwoolvett

I'm not clear just by reading the docs what is the correct way of specifying a single, "complex" dependency (eg with markers, example below).

I'm refering to these lines here: the METADATA file being generated contains incorrect information.

NOTE: As a workaround, and by looking at the setuptools code see here for explanation, changing it into multi-line solves the problem with the metadata. In the example, the following line is being split using ;, which generates invalid METADATA:

[options.extras_require]
gstreamer = kivy_deps.gstreamer~=0.3.1; sys_platform == "win32"

On the other hand, this is correctly parsed as the \n overrides the ;, effectively gathering the whole line as a single entry.

[options.extras_require]
gstreamer =
    kivy_deps.gstreamer~=0.3.1; sys_platform == "win32"

The docuemntation contains an example including this:

[options.extras_require]
pdf = ReportLab>=1.2; RXP
rest = docutils>=0.3; pack ==1.1, ==1.3
  • Would in this case a , be the right thing to use between the sependency and the marker instead of ;?

BTW, I'm coming from here:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions