freshcrate
Home > Developer Tools > pyinstaller-hooks-contrib

pyinstaller-hooks-contrib

Community maintained hooks for PyInstaller

Description

# `pyinstaller-hooks-contrib`: The PyInstaller community hooks repository What happens when (your?) package doesn't work with PyInstaller? Say you have data files that you need at runtime? PyInstaller doesn't bundle those. Your package requires others which PyInstaller can't see? How do you fix that? In summary, a "hook" file extends PyInstaller to adapt it to the special needs and methods used by a Python package. The word "hook" is used for two kinds of files. A runtime hook helps the bootloader to launch an app, setting up the environment. A package hook (there are several types of those) tells PyInstaller what to include in the final app - such as the data files and (hidden) imports mentioned above. This repository is a collection of hooks for many packages, and allows PyInstaller to work with these packages seamlessly. ## Installation `pyinstaller-hooks-contrib` is automatically installed when you install PyInstaller, or can be installed with pip: ```commandline pip install -U pyinstaller-hooks-contrib ``` ## I can't see a hook for `a-package` Either `a-package` works fine without a hook, or no-one has contributed hooks. If you'd like to add a hook, or view information about hooks, please see below. ## Hook configuration (options) Hooks that support configuration (options) and their options are documented in [Supported hooks and options](hooks-config.rst). ## I want to help! If you've got a hook you want to share then great! The rest of this page will walk you through the process of contributing a hook. If you've been here before then you may want to skip to the [summary checklist](#summary) **Unless you are very comfortable with `git rebase -i`, please provide one hook per pull request!** **If you have more than one then submit them in separate pull requests.** ### Setup [Fork this repo](https://github.com/pyinstaller/pyinstaller-hooks-contrib/fork) if you haven't already done so. (If you have a fork already but its old, click the **Fetch upstream** button on your fork's homepage.) Clone and `cd` inside your fork by running the following (replacing `bob-the-barnacle` with your github username): ``` git clone https://github.com/bob-the-barnacle/pyinstaller-hoooks-contrib.git cd pyinstaller-hooks-contrib ``` Create a new branch for you changes (replacing `foo` with the name of the package): You can name this branch whatever you like. ``` git checkout -b hook-for-foo ``` If you wish to create a virtual environment then do it now before proceeding to the next step. Install this repo in editable mode. This will overwrite your current installation. (Note that you can reverse this with `pip install --force-reinstall pyinstaller-hooks-contrib`). ``` pip install -e . pip install -r requirements-test.txt pip install flake8 pyinstaller ``` Note that on macOS and Linux, `pip` may by called `pip3`. If you normally use `pip3` and `python3` then use `pip3` here too. You may skip the 2<sup>nd</sup> line if you have no intention of providing tests (but please do provide tests!). ### Add the hook Standard hooks live in the [_pyinstaller_hooks_contrib/stdhooks/](../master/_pyinstaller_hooks_contrib/stdhooks/) directory. Runtime hooks live in the [_pyinstaller_hooks_contrib/rthooks/](../master/_pyinstaller_hooks_contrib/rthooks/) directory. Simply copy your hook into there. If you're unsure if your hook is a runtime hook then it almost certainly is a standard hook. Please annotate (with comments) anything unusual in the hook. *Unusual* here is defined as any of the following: * Long lists of `hiddenimport` submodules. If you need lots of hidden imports then use [`collect_submodules('foo')`](https://pyinstaller.readthedocs.io/en/latest/hooks.html#PyInstaller.utils.hooks.collect_submodules). For bonus points, track down why so many submodules are hidden. Typical causes are: * Lazily loaded submodules (`importlib.importmodule()` inside a module `__getattr__()`). * Dynamically loaded *backends*. * Usage of `Cython` or Python extension modules containing `import` statements. * Use of [`collect_all()`](https://pyinstaller.readthedocs.io/en/latest/hooks.html#PyInstaller.utils.hooks.collect_all). This function's performance is abismal and [it is broken by design](https://github.com/pyinstaller/pyinstaller/issues/6458#issuecomment-1000481631) because it confuses packages with distributions. Check that you really do need to collect all of submodules, data files, binaries, metadata and dependencies. If you do then add a comment to say so (and if you know it - why). Do not simply use `collect_all()` just to *future proof* the hook. * Any complicated `os.path` arithmetic (by which I simply mean overly complex filename manipulations). #### Add the copyright header All source files must contain the copyright header to be covered by our terms and conditions. If you are **adding** a new hook (or any new python file), copy/paste the appropriate cop

Release History

VersionChangesUrgencyDate
2026.4Imported from PyPI (2026.4)Low4/21/2026
v2026.4Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2026.4/CHANGELOG.rst) for more detailsMedium3/31/2026
v2026.3Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2026.3/CHANGELOG.rst) for more detailsLow3/9/2026
v2026.2Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2026.2/CHANGELOG.rst) for more detailsLow3/2/2026
v2026.1Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2026.1/CHANGELOG.rst) for more detailsLow2/18/2026
v2026.0Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2026.0/CHANGELOG.rst) for more detailsLow1/20/2026
v2025.11Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.11/CHANGELOG.rst) for more detailsLow12/23/2025
v2025.10Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.10/CHANGELOG.rst) for more detailsLow11/22/2025
v2025.9Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.9/CHANGELOG.rst) for more detailsLow9/24/2025
v2025.8Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.8/CHANGELOG.rst) for more detailsLow7/27/2025
v2025.7Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.7/CHANGELOG.rst) for more detailsLow7/22/2025
v2025.6Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.6/CHANGELOG.rst) for more detailsLow7/14/2025
v2025.5Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.5/CHANGELOG.rst) for more detailsLow6/8/2025
v2025.4Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.4/CHANGELOG.rst) for more detailsLow5/3/2025
v2025.3Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.3/CHANGELOG.rst) for more detailsLow4/16/2025
v2025.2Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.2/CHANGELOG.rst) for more detailsLow3/23/2025
v2025.1Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.1/CHANGELOG.rst) for more detailsLow1/31/2025
v2025.0Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2025.0/CHANGELOG.rst) for more detailsLow1/16/2025
v2024.11Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2024.11/CHANGELOG.rst) for more detailsLow12/23/2024
v2024.10Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2024.10/CHANGELOG.rst) for more detailsLow11/10/2024
v2024.9Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2024.9/CHANGELOG.rst) for more detailsLow10/15/2024
v2024.8Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/v2024.8/CHANGELOG.rst) for more detailsLow8/9/2024
2024.6Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow5/10/2024
2024.5Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow4/23/2024
2024.4Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow4/13/2024
2024.3Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow3/9/2024
2024.2Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow2/29/2024
2024.1Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow2/10/2024
2024.0Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow1/18/2024
2023.12Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow1/3/2024
2023.11Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow12/20/2023
2023.10Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow10/13/2023
2023.9Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow9/26/2023
2023.8Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow8/29/2023
2023.7Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow8/18/2023
2023.6Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow7/20/2023
2023.5Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow7/4/2023
2023.4Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow6/27/2023
2023.3Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow5/11/2023
2023.2Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow4/7/2023
2023.1Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow3/16/2023
2023.0Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow2/13/2023
2022.15Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow1/15/2023
2022.14Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow12/4/2022
2022.13Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow11/8/2022
2022.12Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow11/5/2022
2022.11Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow10/27/2022
2022.10Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow8/31/2022
2022.9Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow8/26/2022
2022.8Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow7/8/2022
2022.7Please see the [changelog](https://www.github.com/pyinstaller/pyinstaller-hooks-contrib/tree/master/CHANGELOG.rst) for more detailsLow6/7/2022

Dependencies & License Audit

Loading dependencies...

Similar Packages

firebase-adminFirebase Admin Python SDK7.4.0
azure-coreMicrosoft Azure Core Library for Pythonazure-template_0.1.0b6187637
azure-mgmt-coreMicrosoft Azure Management Core Library for Pythonazure-template_0.1.0b6187637
azure-monitor-opentelemetry-exporterMicrosoft Azure Monitor Opentelemetry Exporter Client Library for Pythonazure-template_0.1.0b6187637
azure-servicebusMicrosoft Azure Service Bus Client Library for Pythonazure-template_0.1.0b6187637