Description: Fix Python 3.12 incompatibility in bundled versioneer.py
 SafeConfigParser was removed in Python 3.12; use ConfigParser with
 read_file() instead of readfp() (removed as well). Fixes the build
 failure in the clean stage.
Author: tangxiaofeng <tangxiaofeng@kylinos.cn>
Origin: upstream, https://github.com/python-versioneer/python-versioneer
Forwarded: not-needed
Last-Update: 2026-09-04

--- pytest-salt-2019.6.13.orig/versioneer.py
+++ pytest-salt-2019.6.13/versioneer.py
@@ -341,9 +341,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):

