From 79e3be8d6a9e3164885293ae5bbabac7fcc02b0c Mon Sep 17 00:00:00 2001 From: ByteOtter Date: Tue, 1 Aug 2023 22:50:45 +0200 Subject: [PATCH] remove call to native tomllib because of missing features --- setup.cfg | 2 +- src/nester/core/opinionated/opinionated_creation.py | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/setup.cfg b/setup.cfg index 8e78711..16265ff 100644 --- a/setup.cfg +++ b/setup.cfg @@ -27,7 +27,7 @@ install_requires = click>=8.1.3 questionary>=1.10.0 pyyaml - toml; python_version<"3.11" + toml [options.extras_require] dev = diff --git a/src/nester/core/opinionated/opinionated_creation.py b/src/nester/core/opinionated/opinionated_creation.py index e9a3851..eb18ce1 100644 --- a/src/nester/core/opinionated/opinionated_creation.py +++ b/src/nester/core/opinionated/opinionated_creation.py @@ -6,13 +6,10 @@ import subprocess from typing import Any +# If a version of the dump method comes available in python 3.11's native tomllib, add a import try except here. +import toml import yaml -try: - import tomllib as toml -except ImportError: - import toml - from . import exceptions, supported_linters