diff options
| author | Vishvananda Ishaya <vishvananda@yahoo.com> | 2010-09-08 02:00:07 -0700 |
|---|---|---|
| committer | Vishvananda Ishaya <vishvananda@yahoo.com> | 2010-09-08 02:00:07 -0700 |
| commit | 59e1bae9547da170669fc2cca68c404b41387aa5 (patch) | |
| tree | 5b25314c901f763c45b1997d772d804f8d647ec3 /nova | |
| parent | 1ddc8cde319a70479bb22b4d3e7176d69e206bb2 (diff) | |
| parent | fbe2007deb9618e497097082f2c1af1be9c07c1c (diff) | |
| download | nova-59e1bae9547da170669fc2cca68c404b41387aa5.tar.gz nova-59e1bae9547da170669fc2cca68c404b41387aa5.tar.xz nova-59e1bae9547da170669fc2cca68c404b41387aa5.zip | |
merged orm
Diffstat (limited to 'nova')
| -rw-r--r-- | nova/db/sqlalchemy/models.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/nova/db/sqlalchemy/models.py b/nova/db/sqlalchemy/models.py index 960b7089b..846fe362f 100644 --- a/nova/db/sqlalchemy/models.py +++ b/nova/db/sqlalchemy/models.py @@ -174,7 +174,7 @@ class Service(BASE, NovaBase): ).filter_by(host=host ).filter_by(binary=binary ).filter_by(deleted=False - .one() + ).one() except exc.NoResultFound: new_exc = exception.NotFound("No model for %s, %s" % (host, binary)) @@ -338,7 +338,7 @@ class FixedIp(BASE, NovaBase): return session.query(cls ).filter_by(address=str_id ).filter_by(deleted=False - .one() + ).one() except exc.NoResultFound: new_exc = exception.NotFound("No model for address %s" % str_id) raise new_exc.__class__, new_exc, sys.exc_info()[2] @@ -367,7 +367,7 @@ class FloatingIp(BASE, NovaBase): return session.query(cls ).filter_by(address=str_id ).filter_by(deleted=False - .one() + ).one() except exc.NoResultFound: session.rollback() new_exc = exception.NotFound("No model for address %s" % str_id) |
