From f9e3c5ee3028eb75def1c77ec2d855bda61c88e7 Mon Sep 17 00:00:00 2001 From: Kleis Auke Wolthuizen Date: Fri, 22 Mar 2024 15:48:47 +0100 Subject: [PATCH] Avoid libvips import during "preparing metadata"-phase of pip --- pyproject.toml | 2 +- pyvips/__init__.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 4f3480c..c10eaed 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,7 +63,7 @@ zip-safe = false include-package-data = false [tool.setuptools.dynamic] -version = {attr = "pyvips.__version__"} +version = {attr = "pyvips.version.__version__"} [tool.setuptools.packages.find] exclude = [ diff --git a/pyvips/__init__.py b/pyvips/__init__.py index 6d783d1..323992b 100644 --- a/pyvips/__init__.py +++ b/pyvips/__init__.py @@ -10,7 +10,7 @@ # user code can override this null handler logger.addHandler(logging.NullHandler()) -# pull in our module version number, see also pyproject.toml +# pull in our module version number from .version import __version__ # try to import our binary interface ... if that works, we are in API mode