diff piecrust/themes/base.py @ 1158:5762a0b821ac

core: Remove yaml deprecation warning.
author Ludovic Chabant <ludovic@chabant.com>
date Tue, 11 Jun 2019 16:40:11 -0700
parents 40a40305c4e1
children
line wrap: on
line diff
--- a/piecrust/themes/base.py	Tue Jun 11 15:14:20 2019 -0700
+++ b/piecrust/themes/base.py	Tue Jun 11 16:40:11 2019 -0700
@@ -25,7 +25,7 @@
         # TODO: make configs and themes load together to speed this up.
         config_path = os.path.join(self.root_dir, CONFIG_PATH)
         with open(config_path, 'r', encoding='utf8') as fp:
-            config = yaml.load(fp.read())
+            config = yaml.load(fp.read(), Loader=yaml.SafeLoader)
         if not config:
             return None
         site_config = config.get('site', {})