Skip to content

Naming: VersionSpecifier and VersionRange #8

Description

@Hritik14

Range resonates with the concept of interval which can be said to be

an interval is a group of numbers that includes all numbers between the beginning and the end

In my understanding, a VersionRange object does not contain both the bounds for a range
https://github.com/nexB/univers/blob/63bd5aec16ec95b5b811ede638ac225f3ab1f6c6/src/univers/version_range.py#L25-L28

A VersionSpecifier does come with multiple VersionRanges and might work for upper-lower bounds but that would require to treat the ranges inside a VersionSpecifier with a mathematical intersection, which doesn't make a lot of sense right now.

For eg: An intersection of semver:1.2.3,>=2.0.0 doesn't quite make sense.
Their union, though, is useful but then we are left without any upper-lower bound range.

Please correct me if I am wrong. Also, it would greatly help if you could add documentation for the exposed classes (like VersionSpecifier, VersionRange etc)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions