diff options
Diffstat (limited to 'heatclient')
-rw-r--r-- | heatclient/common/template_format.py | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/heatclient/common/template_format.py b/heatclient/common/template_format.py index f73339f..fb275f6 100644 --- a/heatclient/common/template_format.py +++ b/heatclient/common/template_format.py @@ -16,14 +16,23 @@ import yaml from heatclient._i18n import _ if hasattr(yaml, 'CSafeLoader'): - yaml_loader = yaml.CSafeLoader + yaml_loader_base = yaml.CSafeLoader else: - yaml_loader = yaml.SafeLoader + yaml_loader_base = yaml.SafeLoader if hasattr(yaml, 'CSafeDumper'): - yaml_dumper = yaml.CSafeDumper + yaml_dumper_base = yaml.CSafeDumper else: - yaml_dumper = yaml.SafeDumper + yaml_dumper_base = yaml.SafeDumper + + +# We create custom class to not overriden the default yaml behavior +class yaml_loader(yaml_loader_base): + pass + + +class yaml_dumper(yaml_dumper_base): + pass def _construct_yaml_str(self, node): |