Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pep440: support post/local for semver allows #158

Merged
merged 1 commit into from
Apr 8, 2021

Conversation

abn
Copy link
Member

@abn abn commented Apr 3, 2021

This change ensures that post and local releases are taken into
consideration when checking if semver version instance allows
post and local build releases.

The following conditions now hold poetry.core.semver.Version.allows.

  • 3.0.0 allows 3.0.0+local.1, 3.0.0-1
  • 3.0.0+local.1 disallows 3.0.0+local.2, allows 3.0.0-1
  • 3.0.0-1 disallows 3.0.0, 3.0.0+local.1, allows 3.0.0-1+local.1

This is a follow up from #157 .

Note this does not change equality check behaviour.

@abn abn requested a review from a team April 3, 2021 00:52
tests/semver/test_version.py Outdated Show resolved Hide resolved
tests/semver/test_version.py Outdated Show resolved Hide resolved
poetry/core/semver/version.py Outdated Show resolved Hide resolved
This change ensures that post and local releases are taken into
consideration when checking if semver version instance allows
post and local build releases.

The following conditions now hold `poetry.core.semver.Version.allows`.

- `3.0.0` allows `3.0.0+local.1`, `3.0.0-1`
- `3.0.0+local.1` disallows `3.0.0+local.2`, allows `3.0.0-1`
- `3.0.0-1` disallows ``3.0.0`, `3.0.0+local.1`, allows `3.0.0-1+local.1`
@sdispater sdispater merged commit 716375e into python-poetry:master Apr 8, 2021
@sdispater sdispater mentioned this pull request Apr 8, 2021
@abn abn deleted the fix/semver-allows branch April 8, 2021 14:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants