From ee2685a8796a4f3944a42b767da9a0e68625562d Mon Sep 17 00:00:00 2001 From: pulumi-bot Date: Thu, 8 Feb 2024 22:07:12 +0000 Subject: [PATCH] make build_sdks --- sdk/python/pulumi_vsphere/_utilities.py | 8 ++------ sdk/python/pyproject.toml | 4 ++-- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/sdk/python/pulumi_vsphere/_utilities.py b/sdk/python/pulumi_vsphere/_utilities.py index 8219769c..e3b8564d 100644 --- a/sdk/python/pulumi_vsphere/_utilities.py +++ b/sdk/python/pulumi_vsphere/_utilities.py @@ -4,6 +4,7 @@ import asyncio +import importlib.metadata import importlib.util import inspect import json @@ -18,11 +19,6 @@ from semver import VersionInfo as SemverVersion from parver import Version as PEP440Version -if sys.version_info >= (3, 8): - from importlib import metadata -else: - import importlib_metadata as metadata - def get_env(*args): for v in args: @@ -76,7 +72,7 @@ def _get_semver_version(): # to receive a valid semver string when receiving requests from the language host, so it's our # responsibility as the library to convert our own PEP440 version into a valid semver string. - pep440_version_string = metadata.version(root_package) + pep440_version_string = importlib.metadata.version(root_package) pep440_version = PEP440Version.parse(pep440_version_string) (major, minor, patch) = pep440_version.release prerelease = None diff --git a/sdk/python/pyproject.toml b/sdk/python/pyproject.toml index ec2d51b7..67a2b5d3 100644 --- a/sdk/python/pyproject.toml +++ b/sdk/python/pyproject.toml @@ -1,10 +1,10 @@ [project] name = "pulumi_vsphere" description = "A Pulumi package for creating vsphere resources" - dependencies = ["importlib-metadata>=6.0.0,<7.0.0; python_version < \"3.8\"", "parver>=0.2.1", "pulumi>=3.0.0,<4.0.0", "semver>=2.8.1"] + dependencies = ["parver>=0.2.1", "pulumi>=3.0.0,<4.0.0", "semver>=2.8.1"] keywords = ["pulumi", "vsphere"] readme = "README.md" - requires-python = ">=3.7" + requires-python = ">=3.8" version = "0.0.0" [project.license] text = "Apache-2.0"