diff options
-rw-r--r-- | linaro-ami/aws_controller.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/linaro-ami/aws_controller.py b/linaro-ami/aws_controller.py index 29c77dc..d5037ee 100644 --- a/linaro-ami/aws_controller.py +++ b/linaro-ami/aws_controller.py @@ -104,7 +104,8 @@ class AwsController: # There doesn't seem to be timestamp associated with AMI, so iterate # over its associated snapshots, and find oldest. snapshot_ids = [bdm.snapshot_id - for bdm in image.block_device_mapping.values()] + for bdm in image.block_device_mapping.values() + if bdm.snapshot_id] snapshots = self._connection.get_all_snapshots(snapshot_ids) oldest = "Z" for s in snapshots: |