From 6bbe906db0385bcd11e0532b8b180272feb76042 Mon Sep 17 00:00:00 2001 From: Dan Smith Date: Mon, 17 Jun 2013 16:01:09 -0700 Subject: Remove straggling use of all-kwarg object methods This removes one remaining vestige of the days of yore when nova developers were forced to always use kwargs on object methods out of fear, lest it be used over RPC. Related to blueprint unified-object-model Change-Id: Ieba76efc2f5daed08e4bde9096c0e178f1f44466 --- nova/objects/instance.py | 2 +- nova/tests/objects/test_instance.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/nova/objects/instance.py b/nova/objects/instance.py index c1b765f29..de47f648f 100644 --- a/nova/objects/instance.py +++ b/nova/objects/instance.py @@ -191,7 +191,7 @@ class Instance(base.NovaObject): return instance @base.remotable_classmethod - def get_by_uuid(cls, context, uuid=None, expected_attrs=None): + def get_by_uuid(cls, context, uuid, expected_attrs=None): if expected_attrs is None: expected_attrs = [] diff --git a/nova/tests/objects/test_instance.py b/nova/tests/objects/test_instance.py index a55c5d502..09ce70355 100644 --- a/nova/tests/objects/test_instance.py +++ b/nova/tests/objects/test_instance.py @@ -90,7 +90,7 @@ class _TestInstanceObject(object): self.mox.StubOutWithMock(db, 'instance_get_by_uuid') db.instance_get_by_uuid(ctxt, 'uuid', []).AndReturn(self.fake_instance) self.mox.ReplayAll() - inst = instance.Instance.get_by_uuid(ctxt, uuid='uuid') + inst = instance.Instance.get_by_uuid(ctxt, 'uuid') # Make sure these weren't loaded for attr in instance.INSTANCE_OPTIONAL_FIELDS: attrname = base.get_attrname(attr) -- cgit