diff options
| author | Matthew Sherborne <msherborne@gmail.com> | 2013-03-12 11:24:20 +1000 |
|---|---|---|
| committer | Matthew Sherborne <msherborne@gmail.com> | 2013-03-12 13:25:31 +1000 |
| commit | e4e0d37f8a487d562d95a1ab37b4a90d861eb1d5 (patch) | |
| tree | e3811a529df061c1d13ba8d12adb8d1ab97e482a /nova/compute | |
| parent | 782dd69de4c6661eeb889b4e5b3b1b8df9d228b6 (diff) | |
Fix behaviour of split_cell_and_item
If you try to split a cell and item, with no path!to!cell@ in it, it'll
now return None for the cell, instead causing a ValueError when trying
to split the result.
Change-Id: I228b9f3b0f63f8c7a6004b3206f5312ed2a878bc
Fixes: bug #1153841
Diffstat (limited to 'nova/compute')
| -rw-r--r-- | nova/compute/cells_api.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/nova/compute/cells_api.py b/nova/compute/cells_api.py index d5a07490b..6f974f9c5 100644 --- a/nova/compute/cells_api.py +++ b/nova/compute/cells_api.py @@ -615,10 +615,7 @@ class HostAPI(compute_api.HostAPI): this call to cells, as we have instance information here in the API cell. """ - try: - cell_name, host_name = cells_utils.split_cell_and_item(host_name) - except ValueError: - cell_name = None + cell_name, host_name = cells_utils.split_cell_and_item(host_name) instances = super(HostAPI, self).instance_get_all_by_host(context, host_name) if cell_name: |
