Skip to content

parse_wheel_name and parse_sdist_filename now raises InvalidVersion #660

@uranusjr

Description

@uranusjr

Since LegacyVersion is dropped, the dist filename parsing functions can now raise InvalidVersion. This is however not mentioned in the docs. I can see two solutions:

  • Mention this in the docs.
  • Catch InvalidVersion and raise InvalidWheelFilename or InvalidSdistFilename instead. Having an invalid version in the filename arguably qualifies as having an invalid filename? (Considering the functions don’t raise e.g. InvalidProjectName when the project part is not a valid name.)

cc @zooba, xref uranusjr/simpleindex#10

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions