From 899002399a26348198612503ce6ca2fc298551a6 Mon Sep 17 00:00:00 2001 From: Victorien <65306057+Viicos@users.noreply.github.com> Date: Mon, 26 Feb 2024 16:49:39 +0100 Subject: [PATCH] Remove usage of `pkg_resources` in `docs/conf.py` (#4251) --- docs/conf.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 52a849d06a4..c352f98da82 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -15,10 +15,9 @@ import os import string +from importlib.metadata import version from pathlib import Path -from pkg_resources import get_distribution - CURRENT_DIR = Path(__file__).parent @@ -43,7 +42,7 @@ def make_pypi_svg(version: str) -> None: # Autopopulate version # The version, including alpha/beta/rc tags, but not commit hash and datestamps -release = get_distribution("black").version.split("+")[0] +release = version("black").split("+")[0] # The short X.Y version. version = release for sp in "abcfr":