Skip to content

Commit cb60d30

Browse files
committed
template_generator: use Python3 exception args
1 parent 918cfd4 commit cb60d30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

troposphere/template_generator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ def _create_instance(self, cls, args, ref=None):
277277
return cls(args)
278278

279279
except TypeError as ex:
280-
if "__init__() takes exactly" not in ex.message:
280+
if "__init__() takes exactly" not in ex.args[0]:
281281
raise
282282
# special AWSHelperFn typically take lowercased parameters,
283283
# but templates use uppercase. for this reason we cannot

0 commit comments

Comments
 (0)