We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b065799 + 3c0fe47 commit 9c3f6f6Copy full SHA for 9c3f6f6
1 file changed
sqlalchemy_seed/__init__.py
@@ -14,6 +14,10 @@
14
import os
15
16
import yaml
17
+try:
18
+ from yaml import CLoader as Loader
19
+except ImportError:
20
+ from yaml import Loader
21
22
__version__ = '0.1.1'
23
@@ -59,7 +63,7 @@ def load_fixture_files(paths, files):
59
63
60
64
with open(fixture_path, 'r') as f:
61
65
if file.endswith('.yaml') or file.endswith('.yml'):
62
- data = yaml.load(f)
66
+ data = yaml.load(f, Loader=Loader)
67
elif file.endswith('.json'):
68
data = json.loads(f)
69
else:
0 commit comments