From 28ea091448efaeb26839845e4655f5fdd6ff8833 Mon Sep 17 00:00:00 2001 From: Zane Bitter Date: Thu, 6 Dec 2012 20:15:27 +0100 Subject: [PATCH] Pass string to template_format.parse() Since template_format.parse() attempts to guess the type of the input instead of using yaml.parse for everything, the input must be a string and not a stream, even though yaml.parse() can handle either. Change-Id: I07dc13a54492f3f6db17bfca3cc9e129c765eed5 Signed-off-by: Zane Bitter --- heat/engine/resources/stack.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/heat/engine/resources/stack.py b/heat/engine/resources/stack.py index 02c130f9..4f5d8499 100644 --- a/heat/engine/resources/stack.py +++ b/heat/engine/resources/stack.py @@ -76,7 +76,7 @@ class Stack(resource.Resource): def handle_create(self): response = urllib2.urlopen(self.properties[PROP_TEMPLATE_URL]) - template = template_format.parse(response) + template = template_format.parse(response.read()) self.create_with_template(template) -- 2.45.2