From 98f17a2097df0bae4d90380aef200b45b1620334 Mon Sep 17 00:00:00 2001 From: Rok Mandeljc Date: Mon, 16 Sep 2024 14:22:36 +0200 Subject: [PATCH] hooks: exclude setuptools_scm from gbulb and travertino `gbulb` and `travertino` (dependencies of `toga`) attempt to query their version via `setuptools_scm` before reading their metadata (which, in their case, is automatically collected because `version` is called with constant argument). So exclude `setuptools_scm` to avoid unnecessarily colleceting it. --- _pyinstaller_hooks_contrib/stdhooks/hook-gbulb.py | 14 ++++++++++++++ .../stdhooks/hook-travertino.py | 14 ++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 _pyinstaller_hooks_contrib/stdhooks/hook-gbulb.py create mode 100644 _pyinstaller_hooks_contrib/stdhooks/hook-travertino.py diff --git a/_pyinstaller_hooks_contrib/stdhooks/hook-gbulb.py b/_pyinstaller_hooks_contrib/stdhooks/hook-gbulb.py new file mode 100644 index 000000000..68116a157 --- /dev/null +++ b/_pyinstaller_hooks_contrib/stdhooks/hook-gbulb.py @@ -0,0 +1,14 @@ +# ------------------------------------------------------------------ +# Copyright (c) 2024 PyInstaller Development Team. +# +# This file is distributed under the terms of the GNU General Public +# License (version 2.0 or later). +# +# The full license is available in LICENSE, distributed with +# this software. +# +# SPDX-License-Identifier: GPL-2.0-or-later +# ------------------------------------------------------------------ + +# Prevent this package from pulling `setuptools_scm` into frozen application, as it makes no sense in that context. +excludedimports = ["setuptools_scm"] diff --git a/_pyinstaller_hooks_contrib/stdhooks/hook-travertino.py b/_pyinstaller_hooks_contrib/stdhooks/hook-travertino.py new file mode 100644 index 000000000..68116a157 --- /dev/null +++ b/_pyinstaller_hooks_contrib/stdhooks/hook-travertino.py @@ -0,0 +1,14 @@ +# ------------------------------------------------------------------ +# Copyright (c) 2024 PyInstaller Development Team. +# +# This file is distributed under the terms of the GNU General Public +# License (version 2.0 or later). +# +# The full license is available in LICENSE, distributed with +# this software. +# +# SPDX-License-Identifier: GPL-2.0-or-later +# ------------------------------------------------------------------ + +# Prevent this package from pulling `setuptools_scm` into frozen application, as it makes no sense in that context. +excludedimports = ["setuptools_scm"]