From 340d5936f89c34e9beb7e2ce920437cbc8686a0e Mon Sep 17 00:00:00 2001 From: blakemertz <44912632+blakemertz@users.noreply.github.com> Date: Tue, 9 Jul 2024 11:11:40 -0500 Subject: [PATCH] Update versioneer.py Needed to update configparser.SafeConfigParser() to configparser.ConfigParser() and parser.readfp() to parser.read_file() to stay consistent with python >= 3.12. --- versioneer.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/versioneer.py b/versioneer.py index 64fea1c..3aa5da3 100644 --- a/versioneer.py +++ b/versioneer.py @@ -339,9 +339,9 @@ def get_config_from_root(root): # configparser.NoOptionError (if it lacks "VCS="). See the docstring at # the top of versioneer.py for instructions on writing your setup.cfg . setup_cfg = os.path.join(root, "setup.cfg") - parser = configparser.SafeConfigParser() + parser = configparser.ConfigParser() with open(setup_cfg, "r") as f: - parser.readfp(f) + parser.read_file(f) VCS = parser.get("versioneer", "VCS") # mandatory def get(parser, name):