You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
1.1 KiB
33 lines
1.1 KiB
From 2f13d7d8a9a5787b3e5d8615ae98db067ed77780 Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
|
|
Date: Sun, 16 Jul 2023 13:39:14 +0200
|
|
Subject: [PATCH] Use configparser.ConfigParser instead of SafeConfigParser
|
|
|
|
The latter is a compat alias (since python 3.2) that was finally
|
|
removed in python 3.12.
|
|
|
|
https://bugs.python.org/issue45173
|
|
---
|
|
versioneer.py | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/versioneer.py b/versioneer.py
|
|
index 13901fcd1b..1e461ba029 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):
|
|
--
|
|
2.41.0
|
|
|