Novaclient flavors.create needs cleanup

Bug #1080891 reported by Gabriel Hurley on 2012-11-19
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

The conversion from integer-only required flavor ids in novaclient to allowing string ids and autogenerated ids needs some cleanup. REferring to the code here:

  1. The docstring still refers to the id as a required integer.

  2. The flavor id argument, given it's position, could have been converted into a kwarg with a value of None with no alteration to the method signature. This would have eliminated the need for the "auto" special-cased name.

  3. The current implementation means that you can't create a flavor named "auto". While this isn't a huge issue, it is still an unnecessary artificial restriction on the possible set.

Gabriel Hurley (gabriel-hurley) wrote :

There's also a typo in that code; the variable "ephemeral" is misspelled and thus never properly used.

affects: nova → python-novaclient

Submitter: Jenkins
Branch: master

commit e9b015c7e14843784debc0d68cfe070c9778f80d
Author: Gabriel Hurley <email address hidden>
Date: Sat Nov 17 18:18:48 2012 -0800

    Cleans up the flavor creation code. Fixes bug 1080891.

    Change-Id: Idc76cd01d1537ab87723a05ab8dd81015284e3c8

Changed in python-novaclient:
status: New → Fix Committed
Changed in python-novaclient:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers