Skip to content

Commit

Permalink
added error handling for missing volumes
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickbcullen committed Jan 9, 2017
1 parent 8584241 commit 0744248
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

setup(
name='aws-tagger',
version='0.2.0',
version='0.2.1',
packages=find_packages(),
include_package_data=True,
install_requires=[
Expand All @@ -28,7 +28,7 @@
author="Patrick Cullen and the WaPo platform tools team",
author_email="[email protected]",
url="https://github.com/washingtonpost/aws-tagger",
download_url = "https://github.com/washingtonpost/aws-tagger/tarball/v0.2.0",
download_url = "https://github.com/washingtonpost/aws-tagger/tarball/v0.2.1",
keywords = ['tag', 'tagger', 'tagging', 'aws'],
classifiers = []
)
2 changes: 1 addition & 1 deletion tagger/tagger.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ def tag(self, instance_id, tags):
try:
self._ec2_create_tags(Resources=resource_ids, Tags=aws_tags)
except botocore.exceptions.ClientError as exception:
if exception.response["Error"]["Code"] in ['InvalidInstanceID.NotFound']:
if exception.response["Error"]["Code"] in ['InvalidVolume.NotFound', 'InvalidInstanceID.NotFound']:
print "Resource not found: %s" % instance_id
else:
raise exception
Expand Down

0 comments on commit 0744248

Please sign in to comment.