Skip to content

ApiVersion Does Not Compare Correctly with Status #108

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

Closed
commonsensesoftware opened this issue Apr 5, 2017 · 0 comments
Closed

ApiVersion Does Not Compare Correctly with Status #108

commonsensesoftware opened this issue Apr 5, 2017 · 0 comments
Assignees
Labels

Comments

@commonsensesoftware
Copy link
Collaborator

Symptoms

When multiple ApiVersion instances with a status are compared, the correct result is returned. Consider sorting a set of ApiVersions:

  • 1.0-RC
  • 1.0-Alpha
  • 1.0-Beta

Will be correctly sorted as:

  • 1.0-Alpha
  • 1.0-Beta
  • 1.0-RC

However, if an ApiVersion is included without a status, that instance is evaluated lower than other instances. For example, if "1.0" is added, the list should be:

  • 1.0-Alpha
  • 1.0-Beta
  • 1.0-RC
  • 1.0

But is instead:

  • 1.0
  • 1.0-Alpha
  • 1.0-Beta
  • 1.0-RC

Resolution

An ApiVersion with the same group version and/or major and minor version should always be greater than an equivalent ApiVersion that includes a status.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant