Cinder quotas validation can be broken with skip_validation=False
Bug #1544774 reported by
Ryan McNair
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Fix Released
|
Undecided
|
Ryan McNair |
Bug Description
The key and value that we're validating are one iteration out of sync when doing quota validation, see https:/
The only reason we don't get a runtime error the first time we try to access "value" is because it was previously defined as part of the loop variable.
https:/
Changed in cinder: | |
assignee: | nobody → Surya Ghatty (ghatty) |
Changed in cinder: | |
status: | New → In Progress |
Changed in cinder: | |
assignee: | Surya Ghatty (ghatty) → Ryan McNair (rdmcnair) |
To post a comment you must log in.
This can be reproduced by changing this line (https:/ /github. com/openstack/ cinder/ blob/master/ cinder/ tests/unit/ api/contrib/ test_quotas. py#L478) to:
body = {'quota_set': {'gigabytes': 1, 'volumes': 10},
The test should still pass, because if everything was working, gigabytes: 1 would still get validated and the update would correctly fail. However, adding "volumes" to the update will cause the test to now fail