Add missing __repr__ method to VolumeSnapshot class.
Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/0696e27e Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/0696e27e Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/0696e27e Branch: refs/heads/trunk Commit: 0696e27eb087c30cfb2d403b917407f13c7f3a54 Parents: 7d6d373 Author: Tomaz Muraus <[email protected]> Authored: Wed Jun 18 08:58:49 2014 +0200 Committer: Tomaz Muraus <[email protected]> Committed: Wed Jun 18 08:58:49 2014 +0200 ---------------------------------------------------------------------- libcloud/compute/base.py | 4 ++++ 1 file changed, 4 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/libcloud/blob/0696e27e/libcloud/compute/base.py ---------------------------------------------------------------------- diff --git a/libcloud/compute/base.py b/libcloud/compute/base.py index d971afa..142c2cb 100644 --- a/libcloud/compute/base.py +++ b/libcloud/compute/base.py @@ -560,6 +560,10 @@ class VolumeSnapshot(object): """ return self.driver.destroy_volume_snapshot(snapshot=self) + def __repr__(self): + return ('<VolumeSnapshot id=%s size=%s driver=%s>' % + (self.id, self.size, self.driver.name)) + class KeyPair(object): """
