yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #61969
[Bug 1649819] Re: APIVersionManager can't distinguish between 2.4 and 2.40
Reviewed: https://review.openstack.org/410688
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=8377fb9e18f96728b080e36b68582d5023b5225a
Submitter: Jenkins
Branch: master
commit 8377fb9e18f96728b080e36b68582d5023b5225a
Author: Radomir Dopieralski <openstack@xxxxxxxxxxxx>
Date: Wed Dec 14 11:53:57 2016 +0100
Properly compare versions in APIVersionManager
Since the APIVersionManager stored the version numbers as ints and
floats, it was not possible to distinguish between version 1.2 and 1.20,
and also version 1.2 would be considered higher than version 1.13. With
the introduction of microversioning in some services, the version
numbers inflate quickly, making this a problem.
This patch wraps the version numbers in a Version object, that stores
the information as a semantic_version and correctly compares with other
Version objects, as well as ints, floats and strings.
It also removes the check for version being specified as a string, so
that it's possible to specify versions such as 1.20 without having to
explicitly create Version objects.
Change-Id: I0b0d87582d617290f08359ad181216cb99edb768
Closes-Bug: #1649819
** Changed in: horizon
Status: In Progress => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1649819
Title:
APIVersionManager can't distinguish between 2.4 and 2.40
Status in OpenStack Dashboard (Horizon):
Fix Released
Bug description:
Since the APIVersionManager requires the version to be specified
either as an integer or a float, it can't tell the difference between
version numbers "2.4" and "2.40". This is especially unfortunate with
the new microversion support in many services.
To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1649819/+subscriptions
References