pypa / pypa/packaging.python.org

Is "AnotherProject (3.4)" a valid version requirement?

Open
#719 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
1.7k
Forks
1.7k
Avg merge
3d 12h
Merged PRs (30d)
4

Description

One of the examples given in https://packaging.python.org/specifications/core-metadata/#provides-dist-multiple-use is "AnotherProject (3.4)".
packaging currently throws an InvalidRequirement error with 'Parse error at "'(3.4)'": Expected stringEnd'
PEP 345 allows it (and there are similar examples within the PEP).
PEP 440 and PEP 508 would appear to allow it (given it is the simplest case with parentheses?).
Does the grammar for PEP 440 and PEP 508 need to be tightened up to handle this case (and hence reflected in packaging), or does the example need fixing to bring it into line with PEP 440/PEP 508?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the core metadata “Provides-Dist (Multiple Use)” section linked in the issue, then compare its example with the cited PEP 345, PEP 440, and PEP 508 rules and the reported packaging parser error. Done means the documentation example and the applicable grammar or implementation are brought into agreement, with the chosen correction reflected in the relevant project source.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation
Issue type
Documentation
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.