From 2d5d03083cde6b52a6c6fa02b23dee716d5c6846 Mon Sep 17 00:00:00 2001 From: Deepak Sihag Date: Tue, 14 Nov 2023 12:15:39 +0530 Subject: [PATCH] replacing use of deprecated ruamel.yaml.safe_load (#380) --- boa/core/test.py | 5 +++-- setup.py | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/boa/core/test.py b/boa/core/test.py index 9cdebfe6..afd391cd 100644 --- a/boa/core/test.py +++ b/boa/core/test.py @@ -8,7 +8,7 @@ import subprocess import sys from conda.core.package_cache_data import PackageCacheData -import ruamel +from ruamel.yaml import YAML import tempfile from pathlib import Path from os.path import isdir, join @@ -64,7 +64,8 @@ def get_metadata(yml, config, is_pyproject_recipe=False): d = toml.load(fi)["tool"]["boa"] else: - d = ruamel.yaml.safe_load(fi) + loader = YAML(typ="safe", pure=True) + d = loader.load(fi) o = Output(d, config) return MetaData(os.path.dirname(yml), o) diff --git a/setup.py b/setup.py index d3d741e6..28c6dd47 100644 --- a/setup.py +++ b/setup.py @@ -14,7 +14,7 @@ "jinja2", "setuptools", "rich", - "ruamel.yaml", + "ruamel.yaml >=0.18.0", "json5", "watchgod", "prompt-toolkit",