From 5f9788d1118b02069b2978aedf9000c9a294ac66 Mon Sep 17 00:00:00 2001 From: dfguerrerom Date: Thu, 5 Oct 2023 12:15:03 +0200 Subject: [PATCH] refactor(version_card): use tomli instead of toml to be inline with #888 --- sepal_ui/scripts/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sepal_ui/scripts/utils.py b/sepal_ui/scripts/utils.py index 9409d762..de2f128b 100644 --- a/sepal_ui/scripts/utils.py +++ b/sepal_ui/scripts/utils.py @@ -15,7 +15,7 @@ import httplib2 import ipyvuetify as v import requests -import toml +import tomli from anyascii import anyascii from deprecated.sphinx import deprecated, versionadded from matplotlib import colors as c @@ -388,8 +388,8 @@ def get_app_version(repo_folder: Pathlike = Path.cwd()) -> str: # check if the file exist if pyproject_path.exists(): - # read the file using toml - pyproject = toml.loads(pyproject_path.read_text()) + # read the file using tomli + pyproject = tomli.loads(pyproject_path.read_text()) # get the version return pyproject.get("project", {}).get("version", None)